Library for MQL5 (MetaTrader) with support for Spark
|
ArrayList from Java.
Public Member Functions | |
CArrayList (int _reserve=0) | |
int | getReserve () |
void | setReserve (int _reserve) |
bool | add (const Type element) |
Appends the specified element to the end of this list. More... | |
bool | add (int index, const Type element) |
Inserts the specified element at the specified position in this list. More... | |
bool | addAll (const Type &list[]) |
Appends all of the elements in the specified collection to the end of this list. More... | |
bool | addAll (const CArrayList< Type > &list) |
Appends all of the elements in the specified collection to the end of this list. More... | |
bool | addAll (int index, const Type &list[]) |
Inserts all of the elements in the specified collection into this list, starting at the specified position. More... | |
bool | addAll (int index, const CArrayList< Type > &list) |
Inserts all of the elements in the specified collection into this list, starting at the specified position. More... | |
void | clear () |
Removes all of the elements from this list. More... | |
bool | contains (const Type o) |
Returns true if this list contains the specified element. More... | |
Type | get (int index) |
Returns the element at the specified position in this list. More... | |
Type | operator[] (int index) |
Returns the element at the specified position in this list. More... | |
Type | set (int index, const Type element) |
Replaces the element at the specified position in this list with the specified element. More... | |
int | indexOf (const Type o) |
Returns the index of the first occurrence of the specified element in this list, or -1 if this list does not contain the element. More... | |
int | lastIndexOf (const Type o) |
Returns the index of the last occurrence of the specified element in this list, or -1 if this list does not contain the element. More... | |
bool | isEmpty () |
Returns true if this list contains no elements. More... | |
Type | remove (int index) |
Removes the element at the specified position in this list. More... | |
bool | removeFirst (const Type o) |
Removes the first occurrence of the specified element from this list, if it is present. More... | |
bool | removeAll (const Type &list[]) |
Removes from this list all of its elements that are contained in the specified collection. More... | |
bool | retainAll (const Type &list[]) |
Retains only the elements in this list that are contained in the specified collection. More... | |
int | size () |
Returns the number of elements in this list. More... | |
int | subList (Type &dst_array[], int dst_start=0, int src_start=0, int count=WHOLE_ARRAY) |
void | toArray (Type &dst_array[]) |
Returns an array containing all of the elements in this list in proper sequence (from first to last element). More... | |
Protected Member Functions | |
bool | removeList (const Type &list[], bool saveOnlyList=false) |
Protected Attributes | |
Type | elements [] |
int | reserve |
CArrayList< Type >::CArrayList | ( | int | _reserve = 0 | ) |
bool CArrayList< Type >::add | ( | const Type | element | ) |
Appends the specified element to the end of this list.
bool CArrayList< Type >::add | ( | int | index, |
const Type | element | ||
) |
Inserts the specified element at the specified position in this list.
bool CArrayList< Type >::addAll | ( | const Type & | list[] | ) |
Appends all of the elements in the specified collection to the end of this list.
bool CArrayList< Type >::addAll | ( | const CArrayList< Type > & | list | ) |
Appends all of the elements in the specified collection to the end of this list.
bool CArrayList< Type >::addAll | ( | int | index, |
const Type & | list[] | ||
) |
Inserts all of the elements in the specified collection into this list, starting at the specified position.
bool CArrayList< Type >::addAll | ( | int | index, |
const CArrayList< Type > & | list | ||
) |
Inserts all of the elements in the specified collection into this list, starting at the specified position.
void CArrayList< Type >::clear | ( | ) |
Removes all of the elements from this list.
bool CArrayList< Type >::contains | ( | const Type | o | ) |
Returns true if this list contains the specified element.
Type CArrayList< Type >::get | ( | int | index | ) |
Returns the element at the specified position in this list.
int CArrayList< Type >::getReserve | ( | ) |
int CArrayList< Type >::indexOf | ( | const Type | o | ) |
Returns the index of the first occurrence of the specified element in this list, or -1 if this list does not contain the element.
bool CArrayList< Type >::isEmpty | ( | ) |
Returns true if this list contains no elements.
int CArrayList< Type >::lastIndexOf | ( | const Type | o | ) |
Returns the index of the last occurrence of the specified element in this list, or -1 if this list does not contain the element.
Type CArrayList< Type >::operator[] | ( | int | index | ) |
Returns the element at the specified position in this list.
Type CArrayList< Type >::remove | ( | int | index | ) |
Removes the element at the specified position in this list.
bool CArrayList< Type >::removeAll | ( | const Type & | list[] | ) |
Removes from this list all of its elements that are contained in the specified collection.
bool CArrayList< Type >::removeFirst | ( | const Type | o | ) |
Removes the first occurrence of the specified element from this list, if it is present.
|
protected |
bool CArrayList< Type >::retainAll | ( | const Type & | list[] | ) |
Retains only the elements in this list that are contained in the specified collection.
Type CArrayList< Type >::set | ( | int | index, |
const Type | element | ||
) |
Replaces the element at the specified position in this list with the specified element.
void CArrayList< Type >::setReserve | ( | int | _reserve | ) |
int CArrayList< Type >::size | ( | ) |
Returns the number of elements in this list.
int CArrayList< Type >::subList | ( | Type & | dst_array[], |
int | dst_start = 0 , |
||
int | src_start = 0 , |
||
int | count = WHOLE_ARRAY |
||
) |
void CArrayList< Type >::toArray | ( | Type & | dst_array[] | ) |
Returns an array containing all of the elements in this list in proper sequence (from first to last element).
|
protected |
|
protected |