public class ChunkDataModifier extends java.lang.Object implements ChunkVisitor
ChunkDataModifier
class is a visitor that modifies
data values in any type of DataChunk
instance. The family of methods
in this class for specifying the source primitive data to use takes the
form setXXXData(xxx[])
where XXX
is one of
either Byte, Short, Int, Long, Float, or Double and xxx
is
byte, short, int, float, or double. If the source primitive data is
integer-valued (byte, short, int, long) and certain values should be marked
as missing in the chunk data, the setMissingData(boolean[])
method should be
used to mark which values are missing. In the case of float and double
primitive data, the values are checked for NaN values and those
values marked as missing in the chunk. No such standard sentinel
values exist for integer-valued data, so missing data must be marked as
missing separately from the data itself.Constructor and Description |
---|
ChunkDataModifier() |
Modifier and Type | Method and Description |
---|---|
void |
setByteData(byte[] byteArray) |
void |
setDoubleData(double[] doubleArray) |
void |
setFloatData(float[] floatArray) |
void |
setIntData(int[] intArray) |
void |
setLongData(long[] longArray) |
void |
setMissingData(boolean[] isMissingArray) |
void |
setShortData(short[] shortArray) |
void |
visitByteChunk(ByteChunk chunk) |
void |
visitDoubleChunk(DoubleChunk chunk) |
void |
visitFloatChunk(FloatChunk chunk) |
void |
visitIntChunk(IntChunk chunk) |
void |
visitLongChunk(LongChunk chunk) |
void |
visitShortChunk(ShortChunk chunk) |
public void setMissingData(boolean[] isMissingArray)
public void setByteData(byte[] byteArray)
public void setShortData(short[] shortArray)
public void setIntData(int[] intArray)
public void setLongData(long[] longArray)
public void setFloatData(float[] floatArray)
public void setDoubleData(double[] doubleArray)
public void visitByteChunk(ByteChunk chunk)
visitByteChunk
in interface ChunkVisitor
public void visitShortChunk(ShortChunk chunk)
visitShortChunk
in interface ChunkVisitor
public void visitIntChunk(IntChunk chunk)
visitIntChunk
in interface ChunkVisitor
public void visitLongChunk(LongChunk chunk)
visitLongChunk
in interface ChunkVisitor
public void visitFloatChunk(FloatChunk chunk)
visitFloatChunk
in interface ChunkVisitor
public void visitDoubleChunk(DoubleChunk chunk)
visitDoubleChunk
in interface ChunkVisitor