Collections > Collections Assembly Classes > StringList
The StringList class implements an object that is a dynamic array of strings.
A dynamic array of strings is an analog of the ArrayList dynamic array, each element of which keeps string value. General principles of working with dynamic array of strings are the same as with the ArrayList array. Array capacity is set in the Capacity property. To add elements to the array, use the Add, or AddRange methods. An array may also be obtained by decomposition of a string, using any separator. To do this, use the AsString and Text properties. Sorting and various kinds of search of the elements are available in the array.
Property name | Brief description | |
![]() |
AsString |
The AsString property determines an array as a text string using separator - {Line feed}. |
![]() |
Capacity | The Capacity property determines the size of memory that is allocated for array elements. |
![]() |
Item | The Item property returns the element value of a string array. |
![]() |
ItemLength | The ItemLength property returns array element length. |
![]() |
Text | The Text property determines the array as a text string using a separator passed as an input parameter. |
Property name | Brief description | |
![]() |
Count | The Count property returns the number of array elements. |
Method name | Brief description | |
![]() |
The Add method adds a new element with the specified value to the end of array and returns its index. | |
![]() |
The AddRange method adds the specified collection of elements to the end of array. | |
![]() |
The BinarySearch method executes binary search of elements in array. | |
![]() |
The BinarySearchRange method executes binary search of the element in array range. | |
![]() |
The Clear method clears an array. | |
![]() |
The Clone method creates a copy of the array. | |
![]() |
The Contains method checks if an element exists. | |
![]() |
The CopyFrom method copies data from a source. | |
![]() |
The GetRange method returns array range. | |
![]() |
The IndexOf method directly searches for value. | |
![]() |
The IndexOfPos method directly searches for value starting from the specified value. | |
![]() |
The IndexOfRange method directly searches for the element in array range. | |
![]() |
The Insert method inserts the element into the specified position. | |
![]() |
The InsertRange method inserts collection of elements into target position. | |
![]() |
The LastIndexOf method reversely searches for value. | |
![]() |
The LastIndexOfPos method reversely searches for a value starting from the specified element. | |
![]() |
The LastIndexOfRange method reversely searches for the element in array range. | |
![]() |
The Remove method removes element by the value. | |
![]() |
The RemoveAt method removes element by the index. | |
![]() |
The RemoveRange method removes element range. | |
![]() |
The Reverse method inverts the array. | |
![]() |
The ReverseRange method inverts the array range. | |
![]() |
The Sort method sorts the array in ascending order. | |
![]() |
The SortRange method sorts array range. | |
![]() |
The ToArray method converts into standard string array. | |
![]() |
The TrimToSize method sets memory size, occupied by the array, that is equal to actual number of elements in the array. |
Method name | Brief description | |
![]() |
CopyTo | The CopyTo method copies the collection into an array. |
See also: