Package uk.ac.starlink.table
Interface ValueStore
- All Known Implementing Classes:
ArrayPrimitiveStore
public interface ValueStore
Interface for storing a vector of values. Depending on implementation,
these values may be objects or primitives.
- Since:
- 2 Nov 2005
- Author:
- Mark Taylor
-
Method Details
-
getType
Class<?> getType()Returns the class of value which this object can store.- Returns:
- primitive class
-
getLength
long getLength()Returns the length of the vector.- Returns:
- vector length
-
put
Stores a vector of values in this object.array
must be an array of values matchinggetType
. Elementioff
ofarray
is stored at indexindex
, elemntioff+1
atindex+1
, etc.- Parameters:
index
- starting offset to write toarray
- array of values to storeioff
- offset into array from which the first value is takencount
- number of values to transfer
-
get
Retrieves a vector of values from this object.array
must be an array of type matchinggetType
. Every element ofarray
will be filled with values; the first retrieved from offsetindex
, the second fromindex+1
, etc.- Parameters:
index
- starting offsetarray
- array to accept dataioff
- offset into array to which the first value is copiedcount
- number of values to transfer
-