|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectkrati.core.array.basic.MemoryShortArray
public class MemoryShortArray
Field Summary | |
---|---|
protected boolean |
_autoExpand
|
protected int |
_subArrayBits
|
protected int |
_subArrayMask
|
protected short[][] |
_subArrays
|
protected int |
_subArraySize
|
Constructor Summary | |
---|---|
MemoryShortArray()
|
|
MemoryShortArray(int subArrayBits)
|
|
MemoryShortArray(int subArrayBits,
boolean autoExpand)
|
Method Summary | |
---|---|
void |
clear()
Clears this Array. |
void |
expandCapacity(int index)
Expands the capacity of array to accommodate a given index. |
short |
get(int index)
Gets data at a specified index. |
protected ArrayExpandListener |
getArrayExpandListener()
|
short[] |
getInternalArray()
Gets the internal primitive array. |
boolean |
hasIndex(int index)
|
int |
length()
|
void |
set(int index,
short value)
|
void |
set(int index,
short value,
long scn)
Sets data at a specified index. |
protected void |
setArrayExpandListener(ArrayExpandListener listener)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected short[][] _subArrays
protected final int _subArrayBits
protected final int _subArraySize
protected final int _subArrayMask
protected final boolean _autoExpand
Constructor Detail |
---|
public MemoryShortArray() throws Exception
Exception
public MemoryShortArray(int subArrayBits) throws Exception
Exception
public MemoryShortArray(int subArrayBits, boolean autoExpand) throws Exception
Exception
Method Detail |
---|
public void clear()
Array
clear
in interface Array
public int length()
length
in interface Array
public boolean hasIndex(int index)
hasIndex
in interface Array
public short get(int index)
ShortArray
get
in interface ShortArray
public void set(int index, short value)
public void set(int index, short value, long scn)
ShortArray
set
in interface ShortArray
public void expandCapacity(int index)
DynamicArray
expandCapacity
in interface DynamicArray
index
- an index in the arraypublic short[] getInternalArray()
ShortArray
getInternalArray
in interface ShortArray
protected void setArrayExpandListener(ArrayExpandListener listener)
protected ArrayExpandListener getArrayExpandListener()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |