public class FloatObjGapList extends GapList<java.lang.Float>
Note that this implementation is not synchronized.
GapList,
FloatGapList,
Serialized Form| Constructor and Description |
|---|
FloatObjGapList() |
FloatObjGapList(java.util.Collection<? extends java.lang.Float> elems) |
FloatObjGapList(java.lang.Float... elems) |
FloatObjGapList(int capacity) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addAll(java.util.Collection<? extends java.lang.Float> coll)
Adds all of the elements in the specified collection into this list.
|
boolean |
addAll(java.lang.Float... elems)
Adds all specified elements into this list.
|
boolean |
addAll(GapList<? extends java.lang.Float> list2)
Adds all of the elements in the specified list into this list.
|
boolean |
addAll(int index,
java.util.Collection<? extends java.lang.Float> coll)
Inserts all of the elements in the specified collection into this
list, starting at the specified position.
|
boolean |
addAll(int index,
java.lang.Float... elems)
Inserts the specified elements into this list,
starting at the specified position.
|
boolean |
addAll(int index,
GapList<? extends java.lang.Float> list2)
Inserts all of the elements in the specified list into this
list, starting at the specified position.
|
<K> int |
binarySearch(int index,
int len,
K key,
java.util.Comparator<? super K> comparator)
Searches the specified range for an object using the binary
search algorithm.
|
int |
capacity()
Returns capacity of this GapList.
|
java.lang.Object |
clone()
Returns a shallow copy of this GapList instance
(The elements themselves are not copied).
|
boolean |
contains(java.lang.Object elem) |
boolean |
containsAll(java.util.Collection<?> coll) |
boolean |
containsAny(java.util.Collection<?> coll)
Returns true if any of the elements of the specified collection is contained in the list.
|
FloatObjGapList |
copy()
Returns a shallow copy of this GapList instance
(the new list will contain the same elements as the source list, i.e. the elements themselves are not copied).
|
static FloatObjGapList |
create() |
static FloatObjGapList |
create(java.util.Collection<? extends java.lang.Float> elems) |
static FloatObjGapList |
create(java.lang.Float... elems) |
static FloatObjGapList |
create(int capacity) |
boolean |
doAdd(int index,
java.lang.Float elem)
Helper method for adding an element to the GapList.
|
boolean |
doAddAll(int index,
java.lang.Float[] elem)
Helper method for adding multiple elements to the GapList.
|
java.lang.Float |
doGet(int index)
Helper method for getting an element from the GapList.
|
void |
doGetAll(java.lang.Object[] elems,
int index,
int len)
Helper method to fill the specified elements in an array.
|
java.lang.Float |
doRemove(int index)
Helper method to remove an element.
|
void |
doRemoveAll(int index,
int len)
Remove specified range of elements from list.
|
java.lang.Float |
doReSet(int index,
java.lang.Float elem)
Sets an element at specified position.
|
java.lang.Float |
doSet(int index,
java.lang.Float elem)
Helper method for setting an element in the GapList.
|
void |
doSetAll(int index,
java.lang.Float[] elem)
Replaces the specified elements.
|
void |
ensureCapacity(int minCapacity)
Increases the capacity of this GapList instance, if
necessary, to ensure that it can hold at least the number of elements
specified by the minimum capacity argument.
|
boolean |
equals(java.lang.Object obj) |
java.lang.Float |
get(int index) |
GapList<java.lang.Float> |
getAll(int index,
int len)
Returns specified range of elements from list.
|
java.lang.Float[] |
getArray(int index,
int len)
Returns specified range of elements from list.
|
int |
hashCode() |
int |
indexOf(java.lang.Object elem) |
void |
init()
Initialize the list to be empty.
|
void |
init(java.util.Collection<? extends java.lang.Float> elems)
Initialize the list to contain the specified elements only.
|
void |
init(java.lang.Float... elems)
Initialize the list to contain the specified elements only.
|
void |
init(int capacity)
Initialize the list to be empty with specified initial capacity.
|
boolean |
isEmpty() |
int |
lastIndexOf(java.lang.Object elem) |
void |
move(int srcIndex,
int dstIndex,
int len)
Move specified elements.
|
boolean |
remove(java.lang.Object elem) |
boolean |
removeAll(java.util.Collection<?> coll) |
boolean |
removeAll(GapList<?> coll) |
boolean |
removeFirstOccurrence(java.lang.Object elem) |
boolean |
removeLastOccurrence(java.lang.Object elem) |
boolean |
retainAll(java.util.Collection<?> coll) |
boolean |
retainAll(GapList<?> coll) |
void |
setAll(int index,
java.util.Collection<? extends java.lang.Float> coll)
Replaces the specified elements.
|
void |
setAll(int index,
java.lang.Float... elems)
Replaces the specified elements.
|
void |
setAll(int index,
GapList<? extends java.lang.Float> list2)
Replaces the specified elements.
|
int |
size() |
void |
sort(int index,
int len,
java.util.Comparator comparator)
Sort specified elements in the list using the specified comparator.
|
java.lang.Object[] |
toArray() |
java.lang.Object[] |
toArray(int index,
int len)
Returns an array containing the specified elements in this list.
|
<T> T[] |
toArray(T[] array) |
java.lang.String |
toString() |
void |
trimToSize()
Trims the capacity of this GapList instance to be the
list's current size.
|
GapList<java.lang.Float> |
unmodifiableList()
Returns an unmodifiable view of this list.
|
add, add, addFirst, addLast, binarySearch, clear, copy, copy, create, create, descendingIterator, element, EMPTY, fill, fill, getFirst, getLast, init, iterator, listIterator, listIterator, move, offer, offerFirst, offerLast, peek, peekFirst, peekLast, poll, pollFirst, pollLast, pop, push, remove, remove, remove, removeFirst, removeLast, resize, reverse, reverse, rotate, rotate, set, sort, swap, swappublic FloatObjGapList()
public FloatObjGapList(int capacity)
public FloatObjGapList(java.lang.Float... elems)
public FloatObjGapList(java.util.Collection<? extends java.lang.Float> elems)
public static FloatObjGapList create()
public static FloatObjGapList create(int capacity)
public static FloatObjGapList create(java.lang.Float... elems)
public static FloatObjGapList create(java.util.Collection<? extends java.lang.Float> elems)
public void init()
GapListpublic void init(int capacity)
GapListpublic void init(java.lang.Float... elems)
GapListpublic void init(java.util.Collection<? extends java.lang.Float> elems)
GapListpublic java.lang.Object clone()
GapListpublic FloatObjGapList copy()
GapListcopy in class GapList<java.lang.Float>GapList.clone()public int size()
public int capacity()
GapListpublic java.lang.Float get(int index)
public java.lang.Float doGet(int index)
GapListindex - index of element to returnpublic void doGetAll(java.lang.Object[] elems,
int index,
int len)
GapListelems - array to store the list elementsindex - index of first element to copylen - number of elements to copypublic boolean doAdd(int index,
java.lang.Float elem)
GapListindex - index where element should be added
(-1 means it is up to the implementation to choose the index)elem - element to addpublic boolean doAddAll(int index,
java.lang.Float[] elem)
GapListindex - index where element should be added
(-1 is valid for adding at the end)elem - array with elements to addpublic java.lang.Float doSet(int index,
java.lang.Float elem)
GapListindex - index where element will be placedelem - element to setpublic void doSetAll(int index,
java.lang.Float[] elem)
GapListindex - index of first element to setelem - elements to setpublic java.lang.Float doRemove(int index)
GapListindex - index of element to removepublic void doRemoveAll(int index,
int len)
GapListindex - index of first element to removelen - number of elements to removepublic java.lang.Float doReSet(int index,
java.lang.Float elem)
GapListindex - index where element will be placedelem - element to setpublic void move(int srcIndex,
int dstIndex,
int len)
GapListpublic void ensureCapacity(int minCapacity)
GapListensureCapacity in class GapList<java.lang.Float>minCapacity - the desired minimum capacitypublic void trimToSize()
GapListtrimToSize in class GapList<java.lang.Float>public boolean equals(java.lang.Object obj)
public int hashCode()
public boolean isEmpty()
public int indexOf(java.lang.Object elem)
public int lastIndexOf(java.lang.Object elem)
lastIndexOf in interface java.util.List<java.lang.Float>lastIndexOf in class GapList<java.lang.Float>public boolean remove(java.lang.Object elem)
public boolean contains(java.lang.Object elem)
public boolean containsAny(java.util.Collection<?> coll)
GapListcontainsAny in class GapList<java.lang.Float>coll - collection with elements to be containedpublic boolean containsAll(java.util.Collection<?> coll)
containsAll in interface java.util.Collection<java.lang.Float>containsAll in interface java.util.List<java.lang.Float>containsAll in class GapList<java.lang.Float>public boolean removeAll(java.util.Collection<?> coll)
public boolean removeAll(GapList<?> coll)
removeAll in class GapList<java.lang.Float>GapList.removeAll(Collection)public boolean retainAll(java.util.Collection<?> coll)
public boolean retainAll(GapList<?> coll)
retainAll in class GapList<java.lang.Float>GapList.retainAll(Collection)public java.lang.Object[] toArray()
public java.lang.Object[] toArray(int index,
int len)
GapListpublic <T> T[] toArray(T[] array)
public boolean addAll(java.util.Collection<? extends java.lang.Float> coll)
GapListaddAll in interface java.util.Collection<java.lang.Float>addAll in interface java.util.List<java.lang.Float>addAll in class GapList<java.lang.Float>coll - collection containing elements to be added to this listpublic boolean addAll(int index,
java.util.Collection<? extends java.lang.Float> coll)
GapListaddAll in interface java.util.List<java.lang.Float>addAll in class GapList<java.lang.Float>index - index at which to insert the first element from the
specified collectioncoll - collection containing elements to be inserted into this listpublic boolean addAll(java.lang.Float... elems)
GapListpublic boolean addAll(int index,
java.lang.Float... elems)
GapListpublic boolean addAll(GapList<? extends java.lang.Float> list2)
GapListpublic boolean addAll(int index,
GapList<? extends java.lang.Float> list2)
GapListpublic boolean removeFirstOccurrence(java.lang.Object elem)
removeFirstOccurrence in interface java.util.Deque<java.lang.Float>removeFirstOccurrence in class GapList<java.lang.Float>public boolean removeLastOccurrence(java.lang.Object elem)
removeLastOccurrence in interface java.util.Deque<java.lang.Float>removeLastOccurrence in class GapList<java.lang.Float>public GapList<java.lang.Float> getAll(int index, int len)
GapListpublic java.lang.Float[] getArray(int index,
int len)
GapListpublic void setAll(int index,
GapList<? extends java.lang.Float> list2)
GapListpublic void setAll(int index,
java.util.Collection<? extends java.lang.Float> coll)
GapListpublic void setAll(int index,
java.lang.Float... elems)
GapListpublic void sort(int index,
int len,
java.util.Comparator comparator)
GapListpublic <K> int binarySearch(int index,
int len,
K key,
java.util.Comparator<? super K> comparator)
GapListbinarySearch in class GapList<java.lang.Float>index - index of first element to searchlen - number of elements to searchkey - the value to be searched forcomparator - the comparator by which the list is ordered.
A null value indicates that the elements'
natural ordering should be used.Arrays.binarySearch(long[], long)public GapList<java.lang.Float> unmodifiableList()
GapListunmodifiableList in class GapList<java.lang.Float>