ch.javasoft.util.intcoll
Class AbstractIntCollection
java.lang.Object
ch.javasoft.util.intcoll.AbstractIntCollection
- All Implemented Interfaces:
- IntCollection, IntIterable, Iterable<Integer>, Collection<Integer>
- Direct Known Subclasses:
- AbstractIntList, AbstractSortedIntSet
public abstract class AbstractIntCollection
- extends Object
- implements IntCollection
Abstract pre-implementation of IntCollection.
|
Field Summary |
protected int |
mod
|
mod
protected transient int mod
AbstractIntCollection
public AbstractIntCollection()
AbstractIntCollection
public AbstractIntCollection(IntCollection set)
AbstractIntCollection
public AbstractIntCollection(int[] values)
size
public abstract int size()
- Specified by:
size in interface Collection<Integer>
clear
public abstract void clear()
- Specified by:
clear in interface Collection<Integer>
addInt
public abstract boolean addInt(int value)
- Specified by:
addInt in interface IntCollection
removeInt
public abstract boolean removeInt(int value)
- Specified by:
removeInt in interface IntCollection
intIterator
public abstract IntIterator intIterator()
- Specified by:
intIterator in interface IntCollection- Specified by:
intIterator in interface IntIterable
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty in interface Collection<Integer>
containsInt
public boolean containsInt(int value)
- Specified by:
containsInt in interface IntCollection
contains
public boolean contains(Object o)
- Specified by:
contains in interface Collection<Integer>
iterator
public Iterator<Integer> iterator()
- Specified by:
iterator in interface Iterable<Integer>- Specified by:
iterator in interface Collection<Integer>
toArray
public Integer[] toArray()
- Specified by:
toArray in interface Collection<Integer>
toArray
public <T> T[] toArray(T[] arr)
- Specified by:
toArray in interface Collection<Integer>
toArrayInternal
protected <T> T[] toArrayInternal(T[] arr,
boolean checkSize)
add
public boolean add(Integer o)
- Specified by:
add in interface Collection<Integer>
remove
public boolean remove(Object o)
- Specified by:
remove in interface Collection<Integer>
containsAll
public boolean containsAll(Collection<?> c)
- Specified by:
containsAll in interface Collection<Integer>
addAll
public boolean addAll(Collection<? extends Integer> c)
- Specified by:
addAll in interface Collection<Integer>
retainAll
public boolean retainAll(Collection<?> c)
- Specified by:
retainAll in interface Collection<Integer>
removeAll
public boolean removeAll(Collection<?> c)
- Specified by:
removeAll in interface Collection<Integer>
addAll
public boolean addAll(IntCollection coll)
- Specified by:
addAll in interface IntCollection
addAll
public boolean addAll(int... values)
- Specified by:
addAll in interface IntCollection
toIntArray
public int[] toIntArray()
- Specified by:
toIntArray in interface IntCollection
toIntArray
public int[] toIntArray(int[] arr)
- Specified by:
toIntArray in interface IntCollection
toIntArrayInternal
protected int[] toIntArrayInternal(int[] arr,
boolean checkSize)
firstInt
public int firstInt()
first
public Integer first()
lastInt
public int lastInt()
last
public Integer last()
clone
public AbstractIntCollection clone()
- Overrides:
clone in class Object
equals
public boolean equals(Object obj)
- Specified by:
equals in interface Collection<Integer>- Overrides:
equals in class Object
hashCode
public int hashCode()
- Specified by:
hashCode in interface Collection<Integer>- Overrides:
hashCode in class Object
toString
public String toString()
- Overrides:
toString in class Object