|
PCJ API Version 1.2 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This interface defines collections of short values.
Collection
Method Summary | |
boolean |
add(short v)
Adds an element to this collection. |
boolean |
addAll(ShortCollection c)
Adds all the elements of a specified collection to this collection. |
void |
clear()
Clears this collection. |
boolean |
contains(short v)
Indicates whether this collection contains a specified element. |
boolean |
containsAll(ShortCollection c)
Indicates whether all elements of a specified collection is contained in this collection. |
boolean |
equals(Object obj)
Indicates whether this collection is equal to some object. |
int |
hashCode()
Returns a hash code value for this collection. |
boolean |
isEmpty()
Indicates whether this collection is empty. |
ShortIterator |
iterator()
Returns an iterator over this collection. |
boolean |
remove(short v)
Removes a specified element from this collection. |
boolean |
removeAll(ShortCollection c)
Removes all the elements of a specified collection from this collection. |
boolean |
retainAll(ShortCollection c)
Retains only the elements of a specified collection in this collection. |
int |
size()
Returns the number of elements in this collection. |
short[] |
toArray()
Returns the elements of this collection as an array. |
short[] |
toArray(short[] a)
Returns the elements of this collection as an array. |
void |
trimToSize()
Minimizes the memory used by this collection. |
Method Detail |
public boolean add(short v)
v
- the element to add to this collection.
UnsupportedOperationException
- if the operation is not supported by this
collection.addAll(ShortCollection)
public boolean addAll(ShortCollection c)
c
- the collection whose elements to add to this
collection.
UnsupportedOperationException
- if the operation is not supported by this
collection.
NullPointerException
- if c is null.add(short)
public void clear()
UnsupportedOperationException
- if the operation is not supported by this
collection.public boolean contains(short v)
v
- the element to test for containment.
containsAll(ShortCollection)
public boolean containsAll(ShortCollection c)
c
- the collection whose elements to test for
containment.
NullPointerException
- if c is null.contains(short)
public boolean equals(Object obj)
obj
- the object with which to compare this collection.
public int hashCode()
public boolean isEmpty()
public ShortIterator iterator()
public boolean remove(short v)
v
- the short value to remove from this collection.
UnsupportedOperationException
- if the operation is not supported by this
collection.public boolean removeAll(ShortCollection c)
c
- the collection whose elements to remove from this
collection.
UnsupportedOperationException
- if the operation is not supported by this
collection.
NullPointerException
- if c is null.public boolean retainAll(ShortCollection c)
c
- the collection whose elements to retain in this
collection.
UnsupportedOperationException
- if the operation is not supported by this
collection.
NullPointerException
- if c is null.public int size()
public short[] toArray()
public short[] toArray(short[] a)
a
- an array to fill with the elements of this
collection; if a is null or not
big enough to contain all the elements of this
collection, an new array is allocated,
and a is not changed.
public void trimToSize()
|
PCJ API Version 1.2 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |