Definition at line 43 of file LongArray.java.
Public Member Functions | |
LongArray (int initialCapacity) | |
Constructs an empty list with the specified initial capacity. | |
LongArray () | |
Constructs an empty list. | |
void | ensureCapacity (int minCapacity) |
Increases the capacity of this ArrayList instance, if necessary, to ensure that it can hold at least the number of elements specified by the minimum capacity argument. | |
int | size () |
Returns the number of elements in this list. | |
boolean | contains (long o) |
return true if the array contains the specified long false otherwise. | |
boolean | isEmpty () |
Tests if this list has no elements. | |
long[] | toArray () |
Returns an array containing all of the elements in this list in the correct order. | |
long | get (int index) |
Returns the element at the specified position in this list. | |
boolean | add (long o) |
Appends the specified element to the end of this list. | |
boolean | add (LongArray array) |
Appends the specified LongArray to the end of this list. | |
boolean | add (long[] array) |
Appends the specified LongArray to the end of this list. | |
boolean | replace (int index, long o) |
replace at the specified index the element. | |
boolean | add (int index, long o) |
Appends the specified element to the end of this list. | |
long | remove (int index) |
Removes the element at the specified position in this list. | |
Static Public Member Functions | |
static long[] | diffLongArray (long[] array1, long[] array2) |
return a array containing all element of the second array that is not in the first one. |
org.openmobileis.common.util.collection.LongArray.LongArray | ( | int | initialCapacity | ) |
Constructs an empty list with the specified initial capacity.
initialCapacity | the initial capacity of the list. |
IllegalArgumentException | if the specified initial capacity is negative |
Definition at line 66 of file LongArray.java.
void org.openmobileis.common.util.collection.LongArray.ensureCapacity | ( | int | minCapacity | ) |
Increases the capacity of this ArrayList
instance, if necessary, to ensure that it can hold at least the number of elements specified by the minimum capacity argument.
minCapacity | the desired minimum capacity. |
Definition at line 101 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.size().
Referenced by org.openmobileis.common.util.collection.LongArray.add().
int org.openmobileis.common.util.collection.LongArray.size | ( | ) |
Returns the number of elements in this list.
Definition at line 118 of file LongArray.java.
Referenced by org.openmobileis.common.util.collection.LongArray.add(), org.openmobileis.common.util.collection.LongArray.contains(), org.openmobileis.common.util.collection.LongArray.ensureCapacity(), org.openmobileis.common.util.collection.LongArray.isEmpty(), org.openmobileis.common.util.collection.LongArray.remove(), org.openmobileis.common.util.collection.LongArray.replace(), and org.openmobileis.common.util.collection.LongArray.toArray().
boolean org.openmobileis.common.util.collection.LongArray.contains | ( | long | o | ) |
return true if the array contains the specified long false otherwise.
int | o : the int to be tested. |
true
if the specified int is inside the array. Definition at line 128 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.size().
boolean org.openmobileis.common.util.collection.LongArray.isEmpty | ( | ) |
Tests if this list has no elements.
true
if this list has no elements; false
otherwise. Definition at line 143 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.size().
long [] org.openmobileis.common.util.collection.LongArray.toArray | ( | ) |
Returns an array containing all of the elements in this list in the correct order.
Definition at line 154 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.size().
Referenced by org.openmobileis.common.util.collection.LongArray.diffLongArray(), and org.openmobileis.database.fastobjectdb.db.query.soda.FODBSodaQuery.execute().
long org.openmobileis.common.util.collection.LongArray.get | ( | int | index | ) |
Returns the element at the specified position in this list.
index | index of element to return. |
IndexOutOfBoundsException | if index is out of range (index < 0 || index >= size()) . |
Definition at line 172 of file LongArray.java.
boolean org.openmobileis.common.util.collection.LongArray.add | ( | long | o | ) |
Appends the specified element to the end of this list.
o | element to be appended to this list. |
true
(as per the general contract of Collection.add). Definition at line 185 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.ensureCapacity(), and org.openmobileis.common.util.collection.LongArray.size().
Referenced by org.openmobileis.common.util.collection.LongArray.diffLongArray().
boolean org.openmobileis.common.util.collection.LongArray.add | ( | LongArray | array | ) |
Appends the specified LongArray to the end of this list.
array | long to add. |
true
(as per the general contract of Collection.add). Definition at line 198 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.ensureCapacity(), and org.openmobileis.common.util.collection.LongArray.size().
boolean org.openmobileis.common.util.collection.LongArray.add | ( | long[] | array | ) |
Appends the specified LongArray to the end of this list.
array | long to add. |
true
(as per the general contract of Collection.add). Definition at line 212 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.ensureCapacity(), and org.openmobileis.common.util.collection.LongArray.size().
boolean org.openmobileis.common.util.collection.LongArray.replace | ( | int | index, | |
long | o | |||
) |
replace at the specified index the element.
if there is no element at index add the new one at the end of the array.
index | index in the array where element is replaced. | |
o | element to be replaced to this ArrayList. |
true
. Definition at line 229 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.size().
boolean org.openmobileis.common.util.collection.LongArray.add | ( | int | index, | |
long | o | |||
) |
Appends the specified element to the end of this list.
o | element to be appended to this list. |
true
(as per the general contract of Collection.add). Definition at line 244 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.ensureCapacity(), and org.openmobileis.common.util.collection.LongArray.size().
long org.openmobileis.common.util.collection.LongArray.remove | ( | int | index | ) |
Removes the element at the specified position in this list.
Shifts any subsequent elements to the left (subtracts one from their indices).
index | the index of the element to removed. |
IndexOutOfBoundsException | if index out of range (index < 0 || index >= size()) . |
Definition at line 263 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.size().
static long [] org.openmobileis.common.util.collection.LongArray.diffLongArray | ( | long[] | array1, | |
long[] | array2 | |||
) | [static] |
return a array containing all element of the second array that is not in the first one.
array1 | first array | |
array2 | second array |
Definition at line 419 of file LongArray.java.
References org.openmobileis.common.util.collection.LongArray.add(), org.openmobileis.common.util.collection.LongArray.LongArray(), and org.openmobileis.common.util.collection.LongArray.toArray().