|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectsparsebitmap.IntArray
public class IntArray
| Constructor Summary | |
|---|---|
IntArray()
Instantiates a new long array. |
|
IntArray(int capacity)
Instantiates a new long array. |
|
| Method Summary | |
|---|---|
void |
add(int value)
Adds a value at the end of the aarray |
int |
capacity()
Return the capacity of the array, typically larger than the size of the array. |
void |
clear()
Clear. |
IntArray |
clone()
|
void |
deserialize(DataInput in)
Deserialize |
boolean |
equals(Object obj)
Determine whether these two arrays contain the same integers. |
int |
get(int index)
Gets the value at index |
int |
hashCode()
Return a hash value for this object. |
void |
removeLast()
Removes the last value (shrinks the array) |
void |
serialize(DataOutput out)
Serialize |
void |
set(int index,
int value)
Sets the value at index |
int |
size()
Size of the array (typically smaller than the capacity). |
int |
trim()
Trim the array so that the capacity is equal to the size. |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IntArray()
public IntArray(int capacity)
capacity - the capacity| Method Detail |
|---|
public IntArray clone()
throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionpublic void clear()
public int get(int index)
index - the index
public int size()
public void set(int index,
int value)
index - the indexvalue - the valuepublic void add(int value)
value - the valuepublic void removeLast()
public int trim()
public void serialize(DataOutput out)
throws IOException
out - the stream where we write
IOException - Signals that an I/O exception has occurred.
public void deserialize(DataInput in)
throws IOException
in - the stream where we read
IOException - Signals that an I/O exception has occurred.public int capacity()
public int hashCode()
hashCode in class Objectpublic boolean equals(Object obj)
equals in class Objectobj - the other object (must be an IntArray to be equal)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||