|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.AbstractCollection<java.lang.Integer>
it.unimi.dsi.fastutil.ints.AbstractIntCollection
it.unimi.dsi.fastutil.ints.AbstractIntBigList
it.unimi.dsi.fastutil.ints.IntBigLists.ListBigList
public static class IntBigLists.ListBigList
A class exposing a list as a big list.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class it.unimi.dsi.fastutil.ints.AbstractIntBigList |
|---|
AbstractIntBigList.IntSubList |
| Method Summary | ||
|---|---|---|
boolean |
add(int key)
|
|
void |
add(long index,
int key)
|
|
boolean |
addAll(java.util.Collection<? extends java.lang.Integer> c)
Delegates to a more generic method. |
|
boolean |
addAll(IntBigList c)
|
|
boolean |
addAll(IntCollection c)
Adds all elements of the given type-specific collection to this collection. |
|
boolean |
addAll(long index,
java.util.Collection<? extends java.lang.Integer> c)
Inserts all of the elements in the specified collection into this big list at the specified position (optional operation). |
|
boolean |
addAll(long index,
IntBigList c)
Delegates to a more generic method. |
|
boolean |
addAll(long index,
IntCollection c)
Delegates to a more generic method. |
|
void |
clear()
|
|
boolean |
contains(int key)
|
|
boolean |
containsAll(java.util.Collection<?> c)
Checks whether this collection contains all elements from the given collection. |
|
boolean |
containsAll(IntCollection c)
Checks whether this collection contains all elements from the given type-specific collection. |
|
int |
getInt(long index)
|
|
int |
hashCode()
Returns the hash code for this big list, which is identical to List.hashCode(). |
|
long |
indexOf(int k)
|
|
boolean |
isEmpty()
Checks whether the stack is empty. |
|
IntBigListIterator |
iterator()
Returns a type-specific iterator on the elements of this collection. |
|
long |
lastIndexOf(int k)
|
|
IntBigListIterator |
listIterator()
Returns a type-specific big-list iterator on this type-specific big list. |
|
IntBigListIterator |
listIterator(long index)
Returns a type-specific list iterator on this type-specific big list starting at a given index. |
|
boolean |
removeAll(java.util.Collection<?> c)
Remove from this collection all elements in the given collection. |
|
boolean |
removeAll(IntCollection c)
Remove from this collection all elements in the given type-specific collection. |
|
void |
removeElements(long from,
long to)
Removes elements of this type-specific big list one-by-one. |
|
int |
removeInt(long index)
|
|
boolean |
retainAll(java.util.Collection<?> c)
Retains in this collection only elements from the given collection. |
|
boolean |
retainAll(IntCollection c)
Retains in this collection only elements from the given type-specific collection. |
|
int |
set(long index,
int k)
|
|
int |
size()
Deprecated. |
|
void |
size(long size)
Sets the size of this big list. |
|
long |
size64()
Returns the size of this data structure as a long. |
|
IntBigList |
subList(long from,
long to)
Returns a type-specific view of the portion of this type-specific big list from the index from, inclusive, to the index to, exclusive. |
|
|
toArray(T[] a)
Returns an containing the items of this collection; the runtime type of the returned array is that of the specified array. |
|
int[] |
toIntArray()
Returns a primitive type array containing the items of this collection. |
|
int[] |
toIntArray(int[] a)
Returns a primitive type array containing the items of this collection. |
|
| Methods inherited from class it.unimi.dsi.fastutil.ints.AbstractIntBigList |
|---|
add, addAll, addElements, addElements, compareTo, equals, get, getElements, getInt, indexOf, lastIndexOf, listIterator, peek, peekInt, pop, popInt, push, push, rem, remove, remove, removeInt, set, set, size, top, topInt, toString |
| Methods inherited from class it.unimi.dsi.fastutil.ints.AbstractIntCollection |
|---|
add, contains, intIterator, rem, remove, toArray, toArray |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface it.unimi.dsi.fastutil.ints.IntCollection |
|---|
intIterator, toArray |
| Methods inherited from interface java.util.Collection |
|---|
add, contains, remove, toArray |
| Method Detail |
|---|
public long size64()
Size64
size64 in interface Size64@Deprecated public int size()
Size64Integer.MAX_VALUE.
size in interface Size64size in interface java.util.Collection<java.lang.Integer>size in class AbstractIntBigListInteger.MAX_VALUE.Collection.size()public void size(long size)
BigListIf the specified size is smaller than the current size, the last elements are
discarded. Otherwise, they are filled with 0/null/false.
size in interface BigList<java.lang.Integer>size in class AbstractIntBigListsize - the new size.public IntBigListIterator iterator()
IntCollectionNote that this specification strengthens the one given in
Iterable.iterator(), which was already
strengthened in the corresponding type-specific class,
but was weakened by the fact that this interface extends Collection.
iterator in interface IntBigListiterator in interface IntCollectioniterator in interface IntIterableiterator in interface java.lang.Iterable<java.lang.Integer>iterator in interface java.util.Collection<java.lang.Integer>iterator in class AbstractIntBigListList.iterator()public IntBigListIterator listIterator()
IntBigList
listIterator in interface BigList<java.lang.Integer>listIterator in interface IntBigListlistIterator in class AbstractIntBigListList.listIterator()
public boolean addAll(long index,
java.util.Collection<? extends java.lang.Integer> c)
BigList
addAll in interface BigList<java.lang.Integer>addAll in class AbstractIntBigListindex - index at which to insert the first element from the specified collection.c - collection containing elements to be added to this big list.
true if this big list changed as a result of the callList.addAll(int, Collection)public IntBigListIterator listIterator(long index)
IntBigList
listIterator in interface BigList<java.lang.Integer>listIterator in interface IntBigListlistIterator in class AbstractIntBigListindex - index of first element to be returned from the big-list iterator.
BigList.listIterator(long)
public IntBigList subList(long from,
long to)
IntBigListfrom, inclusive, to the index to, exclusive.
Note that this specification strengthens the one given in BigList.subList(long,long).
subList in interface BigList<java.lang.Integer>subList in interface IntBigListsubList in class AbstractIntBigListfrom - the starting element (inclusive).to - the ending element (exclusive).
BigList.subList(long,long)public boolean contains(int key)
contains in interface IntCollectioncontains in class AbstractIntBigListCollection.contains(Object)public int[] toIntArray()
IntCollection
toIntArray in interface IntCollectiontoIntArray in class AbstractIntCollectionCollection.toArray()
public void removeElements(long from,
long to)
AbstractIntBigListThis is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
removeElements in interface IntBigListremoveElements in class AbstractIntBigListfrom - the start index (inclusive).to - the end index (exclusive).public int[] toIntArray(int[] a)
IntCollectionNote that, contrarily to Collection.toArray(Object[]), this
methods just writes all elements of this collection: no special
value will be added after the last one.
toIntArray in interface IntCollectiontoIntArray in class AbstractIntCollectiona - if this array is big enough, it will be used to store this collection.
Collection.toArray(Object[])
public void add(long index,
int key)
add in interface IntBigListadd in class AbstractIntBigListList.add(int,Object)
public boolean addAll(long index,
IntCollection c)
AbstractIntBigList
addAll in interface IntBigListaddAll in class AbstractIntBigListList.addAll(int,java.util.Collection)
public boolean addAll(long index,
IntBigList c)
AbstractIntBigList
addAll in interface IntBigListaddAll in class AbstractIntBigListList.addAll(int,java.util.Collection)public boolean add(int key)
add in interface IntCollectionadd in class AbstractIntBigListCollection.add(Object)public boolean addAll(IntBigList c)
addAll in interface IntBigListaddAll in class AbstractIntBigListList.addAll(int,java.util.Collection)public int getInt(long index)
getInt in interface IntBigListBigList.get(long)public long indexOf(int k)
indexOf in interface IntBigListindexOf in class AbstractIntBigListBigList.indexOf(Object)public long lastIndexOf(int k)
lastIndexOf in interface IntBigListlastIndexOf in class AbstractIntBigListBigList.lastIndexOf(Object)public int removeInt(long index)
removeInt in interface IntBigListremoveInt in class AbstractIntBigListBigList.remove(long)
public int set(long index,
int k)
set in interface IntBigListset in class AbstractIntBigListBigList.set(long,Object)public boolean addAll(IntCollection c)
AbstractIntCollection
addAll in interface IntCollectionaddAll in class AbstractIntBigListc - a type-specific collection.
true if this collection changed as a result of the call.Collection.addAll(Collection)public boolean containsAll(IntCollection c)
AbstractIntCollection
containsAll in interface IntCollectioncontainsAll in class AbstractIntCollectionc - a type-specific collection.
true if this collection contains all elements of the argument.Collection.containsAll(Collection)public boolean removeAll(IntCollection c)
AbstractIntCollection
removeAll in interface IntCollectionremoveAll in class AbstractIntCollectionc - a type-specific collection.
true if this collection changed as a result of the call.Collection.removeAll(Collection)public boolean retainAll(IntCollection c)
AbstractIntCollection
retainAll in interface IntCollectionretainAll in class AbstractIntCollectionc - a type-specific collection.
true if this collection changed as a result of the call.Collection.retainAll(Collection)public boolean isEmpty()
Stack
isEmpty in interface Stack<java.lang.Integer>isEmpty in interface java.util.Collection<java.lang.Integer>isEmpty in class AbstractIntCollectionpublic <T> T[] toArray(T[] a)
IntCollectionWarning: Note that, contrarily to Collection.toArray(Object[]), this
methods just writes all elements of this collection: no special
value will be added after the last one.
toArray in interface IntCollectiontoArray in interface java.util.Collection<java.lang.Integer>toArray in class AbstractIntCollectiona - if this array is big enough, it will be used to store this collection.
Collection.toArray(Object[])public boolean containsAll(java.util.Collection<?> c)
AbstractIntCollection
containsAll in interface java.util.Collection<java.lang.Integer>containsAll in class AbstractIntCollectionc - a collection.
true if this collection contains all elements of the argument.public boolean addAll(java.util.Collection<? extends java.lang.Integer> c)
AbstractIntBigList
addAll in interface java.util.Collection<java.lang.Integer>addAll in class AbstractIntBigListc - a collection.
true if this collection changed as a result of the call.public boolean removeAll(java.util.Collection<?> c)
AbstractIntCollection
removeAll in interface java.util.Collection<java.lang.Integer>removeAll in class AbstractIntCollectionc - a collection.
true if this collection changed as a result of the call.public boolean retainAll(java.util.Collection<?> c)
AbstractIntCollection
retainAll in interface java.util.Collection<java.lang.Integer>retainAll in class AbstractIntCollectionc - a collection.
true if this collection changed as a result of the call.public void clear()
clear in interface java.util.Collection<java.lang.Integer>clear in class java.util.AbstractCollection<java.lang.Integer>public int hashCode()
AbstractIntBigListList.hashCode().
hashCode in interface java.util.Collection<java.lang.Integer>hashCode in class AbstractIntBigList
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||