Package org.vast.data
Class DataBlockUInt
java.lang.Object
org.vast.data.AbstractDataBlock
org.vast.data.DataBlockUInt
- All Implemented Interfaces:
Serializable
,DataBlock
Carries an array of int primitives. All data is casted to other types when requested in a way that returns unsigned values even for values > 2^31
- Since:
- Nov 23, 2005
- See Also:
-
Field Summary
FieldsFields inherited from class org.vast.data.AbstractDataBlock
atomCount, startIndex
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()
Full copy of datablock structure and values A new underlying object is created with the same valuescopy()
Shallow copy of datablock structure The underlying object is sharedboolean
boolean
getBooleanValue
(int index) byte
byte
getByteValue
(int index) getDataType
(int index) double
double
getDoubleValue
(int index) float
float
getFloatValue
(int index) int
int
getIntValue
(int index) long
long
getLongValue
(int index) short
short
getShortValue
(int index) getStringValue
(int index) int[]
Allow direct access to underlying object carrying the data (usually a primitive array or composite)renew()
Regenerate an identical datablock of same size with a new underlying objectvoid
resize
(int size) void
setBooleanValue
(boolean value) void
setBooleanValue
(int index, boolean value) void
setByteValue
(byte value) void
setByteValue
(int index, byte value) void
setDoubleValue
(double value) void
setDoubleValue
(int index, double value) void
setFloatValue
(float value) void
setFloatValue
(int index, float value) void
setIntValue
(int value) void
setIntValue
(int index, int value) void
setLongValue
(int index, long value) void
setLongValue
(long value) void
setShortValue
(int index, short value) void
setShortValue
(short value) void
setStringValue
(int index, String value) void
setStringValue
(String value) void
Allows to set the underlying object directlyMethods inherited from class org.vast.data.AbstractDataBlock
getAtomCount, toString, updateAtomCount
-
Field Details
-
primitiveArray
protected int[] primitiveArray
-
-
Constructor Details
-
DataBlockUInt
public DataBlockUInt() -
DataBlockUInt
public DataBlockUInt(int size)
-
-
Method Details
-
copy
Description copied from class:AbstractDataBlock
Shallow copy of datablock structure The underlying object is shared- Specified by:
copy
in interfaceDataBlock
- Specified by:
copy
in classAbstractDataBlock
-
renew
Description copied from class:AbstractDataBlock
Regenerate an identical datablock of same size with a new underlying object- Specified by:
renew
in interfaceDataBlock
- Specified by:
renew
in classAbstractDataBlock
- Returns:
- new data block
-
clone
Description copied from class:AbstractDataBlock
Full copy of datablock structure and values A new underlying object is created with the same values- Specified by:
clone
in interfaceDataBlock
- Specified by:
clone
in classAbstractDataBlock
-
getUnderlyingObject
public int[] getUnderlyingObject()Description copied from class:AbstractDataBlock
Allow direct access to underlying object carrying the data (usually a primitive array or composite)- Specified by:
getUnderlyingObject
in interfaceDataBlock
- Specified by:
getUnderlyingObject
in classAbstractDataBlock
- Returns:
- underlying object
-
setUnderlyingObject
Description copied from class:AbstractDataBlock
Allows to set the underlying object directly- Specified by:
setUnderlyingObject
in interfaceDataBlock
- Specified by:
setUnderlyingObject
in classAbstractDataBlock
-
getDataType
-
getDataType
-
resize
public void resize(int size) -
getBooleanValue
public boolean getBooleanValue(int index) -
getByteValue
public byte getByteValue(int index) -
getShortValue
public short getShortValue(int index) -
getIntValue
public int getIntValue(int index) -
getLongValue
public long getLongValue(int index) -
getFloatValue
public float getFloatValue(int index) -
getDoubleValue
public double getDoubleValue(int index) -
getStringValue
-
getBooleanValue
public boolean getBooleanValue() -
getByteValue
public byte getByteValue() -
getShortValue
public short getShortValue() -
getIntValue
public int getIntValue() -
getLongValue
public long getLongValue() -
getFloatValue
public float getFloatValue() -
getDoubleValue
public double getDoubleValue() -
getStringValue
-
setBooleanValue
public void setBooleanValue(int index, boolean value) -
setByteValue
public void setByteValue(int index, byte value) -
setShortValue
public void setShortValue(int index, short value) -
setIntValue
public void setIntValue(int index, int value) -
setLongValue
public void setLongValue(int index, long value) -
setFloatValue
public void setFloatValue(int index, float value) -
setDoubleValue
public void setDoubleValue(int index, double value) -
setStringValue
-
setBooleanValue
public void setBooleanValue(boolean value) -
setByteValue
public void setByteValue(byte value) -
setShortValue
public void setShortValue(short value) -
setIntValue
public void setIntValue(int value) -
setLongValue
public void setLongValue(long value) -
setFloatValue
public void setFloatValue(float value) -
setDoubleValue
public void setDoubleValue(double value) -
setStringValue
-