public class ChunkedDataSource extends PhysicalDataSource
Modifier and Type | Field and Description |
---|---|
protected RegularISPartitioning |
chunkingPartitioning |
protected ISBounds |
partitioningBounds |
BIG_ENDIAN, bufferBounds, bufferDimension, bufferSteps, byteBuffers, directMemoryLimit, endian, LITTLE_ENDIAN, maxBufferSize, maxGapSize, readCounter, readLength, url
fdlDescriptor, isActivated, name, wsName
attributeOrder, axisOrdering, axisWeights, bounds, dataOrder, dimensionality, numAttributes, pointOrder, recordDesc
Constructor and Description |
---|
ChunkedDataSource(java.lang.String name,
FDLDescriptor fdl)
Create a ChunkedDataSource from an fdl;
In this case, the partitioning specifications are determined by
the size of each partition, not the size of the partitioning space.
|
ChunkedDataSource(java.lang.String name,
ISBounds partitioningBounds,
ISBounds spaceBounds,
java.lang.String fileName,
AxisOrdering order,
RecordDescriptor recordDesc)
Creates a ChunkedDataSource object from 'fileName',
how many chunks are on each direction are specified by 'partitioningBounds',
the dimensions and placement of the volume given by 'spaceBounds',
axis ordering 'order' and records described by 'recordDesc'.
|
Modifier and Type | Method and Description |
---|---|
void |
activate()
Open the binary data file for this datasource.
|
void |
datum(Datum datum,
IndexSpaceID dataId)
load the data from the data source into the argument datum
|
void |
datum(Datum datum,
IndexSpaceID did,
FieldIDMapper fmap)
Return the Datum corresponding to the given IndexSpaceID.
|
void |
deactivate()
The DataSource will release any resources used during the
readling or processing of data.
|
ISBounds |
getChunkBounds()
Return an ISBounds indicating the dimensions of a chunk.
|
int |
getChunkByteSize()
get the byte size of each chunk
|
IndexSpaceID |
getChunkDimensions()
get the dimensions of each chunk in grid space
|
ISBounds |
getPartitionSpaceBounds()
return the ISBounds of this chunkedDataSource in partitioned Space
|
protected void |
loadChunk(long chunkIndex,
Values data)
Given a chunk index, read the data from the chunk into a Values object
|
static void |
main(java.lang.String[] args) |
int |
numOfChunks()
return number of chunks contained by the datasource
|
void |
setOrder(java.nio.ByteBuffer buffer)
set the byte order for the given buffer
|
void |
subblock(DataBlock dstBlock,
ISBounds dstBounds,
ISBounds srcBounds,
FieldIDMapper mp)
Reads a subblock defined by srcBounds into the region of the Datablock argument
defined by dstBounds.
|
allocateBuffer, allocateBuffer, allocateBuffer, allocateBuffer, allocateBuffer, allocateBuffer, allocateBuffer, allocateBuffer, allocateBuffer, deleteBuffer, deleteBuffer, deleteBuffers, equals, getBuffer, getBuffer, getBufferSize, getBufferSize, getByteOrder, getDataFileString, getMaxBufferSize, getReadCounter, getReadLength, getURL, initializeBuffers, isBigEndian, makeBestBuffer, resetReadCounter, setBufferByteOrder, setByteOrder, setMaxBufferSize, setMaxGapSize, subblock, subblock, toString, toString
checkActivated, clearCache, copyBestID, create, create, create, createRemote, createRemote, createRemoteClient, createRemoteClient, createRemoteDataSource, createRemoteDataSource, createRemoteDataSourceUDP, createRemoteUDP, createRemoteUDP, dumpData, getFDLDescriptor, getMetadataCollection, getName, getStatistics, getValues, isActivated, setMetadataCollection
byteSize, computeOffset, computeOffset, copyBounds, createDataBlock, createDataBlock, createDataBlock, createDatum, createDatum, createDatum, createDatum, createDatum, createDatum, datum, datum, datum, datum, datum, dim, getAttributeNames, getAxisOrdering, getAxisWeight, getAxisWeights, getBounds, getByte, getBytes, getBytes, getBytes, getBytes, getBytes, getBytes, getBytesByAttribute, getBytesByAttribute, getBytesByPoint, getBytesByPoint, getDataOrder, getDimensionsArray, getDouble, getDoubles, getDoubles, getDoubles, getDoubles, getDoubles, getDoubles, getDoublesByAttribute, getDoublesByAttribute, getDoublesByPoint, getDoublesByPoint, getFloat, getFloats, getFloats, getFloats, getFloats, getFloats, getFloats, getFloatsByAttribute, getFloatsByAttribute, getFloatsByPoint, getFloatsByPoint, getInt, getInts, getInts, getInts, getInts, getInts, getInts, getIntsByAttribute, getIntsByAttribute, getIntsByPoint, getIntsByPoint, getLowerBoundsArray, getNumAttributes, getRecordDescriptor, getShort, getShorts, getShorts, getShorts, getShorts, getShorts, getShorts, getShortsByAttribute, getShortsByAttribute, getShortsByPoint, getShortsByPoint, getStorageType, getUpperBoundsArray, getValues, getValuesByAttribute, getValuesByPoint, longVolume, setAxisOrdering, setBounds, setRecordDescriptor, size, subblock, subblock, subblock, subblock, subblock, subblock, subblock, subblock, subblock, useBytesOnly, volume
protected ISBounds partitioningBounds
protected RegularISPartitioning chunkingPartitioning
public ChunkedDataSource(java.lang.String name, FDLDescriptor fdl)
name
- fdl
- public ChunkedDataSource(java.lang.String name, ISBounds partitioningBounds, ISBounds spaceBounds, java.lang.String fileName, AxisOrdering order, RecordDescriptor recordDesc)
public ISBounds getPartitionSpaceBounds()
public void activate()
activate
in class DataSource
public void deactivate()
deactivate
in class PhysicalDataSource
public void setOrder(java.nio.ByteBuffer buffer)
public int getChunkByteSize()
public IndexSpaceID getChunkDimensions()
public ISBounds getChunkBounds()
public void datum(Datum datum, IndexSpaceID dataId)
datum
in interface Indexable
datum
in class DataCollection
public void datum(Datum datum, IndexSpaceID did, FieldIDMapper fmap)
datum
in interface Indexable
datum
in class DataCollection
protected void loadChunk(long chunkIndex, Values data)
public int numOfChunks()
public static void main(java.lang.String[] args)
public void subblock(DataBlock dstBlock, ISBounds dstBounds, ISBounds srcBounds, FieldIDMapper mp)
subblock
in interface Indexable
subblock
in class PhysicalDataSource