The Conroy & Conroy Subroutine Library (2021.3 edition)

TString_Collection
What: class
File: Collect
Layer: 0
Platforms: C++, C#, Javascript, Pascal (All), PHP, Python

This class provides a collection of strings. For languages without strict typing (Javascript, PHP, Python, etc) this class stores collections of any data desired (the class is a descendent of TCollection). The items in the collection are referenced by indexes (0 is the first).

At
string At( int Index )
function At( Index : integer ) : string
Returns the item at the specified index.

AtDelete
void AtDelete( int Item )
procedure AtDelete( Index : integer )
Deletes the item at the specified index.

AtInsert
void AtInsert( int Index, string Item )
procedure AtInsert( Index : integer ; Item : string )
Inserts the specified item at the specified index. The item previously at that index and all items above it are moved up one index.

AtPut
void AtPut( int Index, string Value )
procedure AtPut( Index : integer ; Value : string )
Sets the value at a specific index.

Count
int Count()
function Count : integer
Returns the count of items in the collection.

Delete
void Delete( string Item )
procedure Delete( Item : string )
Deletes the items matching the passed items.

DeleteAll
void DeleteAll()
procedure DeleteAll
Deletes all items in the collection.

IndexOf
int IndexOf( string Item )
function IndexOf( Item : string ) : integer
Returns the index of the first item matching the passed value.

Insert
void Insert( string Item )
procedure Insert( Item : string )
Adds the passed item to the end of the collection.

Limit
int Limit()
function Limit : integer
Returns the current capacity for the collection.

SetLimit
void SetLimit( int ALimit )
procedure SetLimit( ALimit : integer )
Sets the total capacity of the collection to the passed value.