Package uk.ac.starlink.ttools.plot2.data
Class ByteStoreColumnFactory
- java.lang.Object
-
- uk.ac.starlink.ttools.plot2.data.ByteStoreColumnFactory
-
- All Implemented Interfaces:
CachedColumnFactory
public class ByteStoreColumnFactory extends java.lang.Object implements CachedColumnFactory
ColumnFactory that stores column data in ByteStores.- Since:
- 23 Dec 2019
- Author:
- Mark Taylor
-
-
Constructor Summary
Constructors Constructor Description ByteStoreColumnFactory(java.util.function.Supplier<uk.ac.starlink.table.ByteStore> byteStoreSupplier)Constructs a ByteStoreColumnFactory based on a ByteStore supplier.ByteStoreColumnFactory(uk.ac.starlink.table.StoragePolicy storage)Constructs a ByteStoreColumnFactory based on a StoragePolicy.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CachedColumncreateColumn(StorageType type, long nrow)Creates a data storage object capable of storing a vector of a given type.
-
-
-
Constructor Detail
-
ByteStoreColumnFactory
public ByteStoreColumnFactory(uk.ac.starlink.table.StoragePolicy storage)
Constructs a ByteStoreColumnFactory based on a StoragePolicy.- Parameters:
storage- storage policy
-
ByteStoreColumnFactory
public ByteStoreColumnFactory(java.util.function.Supplier<uk.ac.starlink.table.ByteStore> byteStoreSupplier)
Constructs a ByteStoreColumnFactory based on a ByteStore supplier.- Parameters:
byteStoreSupplier- supplier
-
-
Method Detail
-
createColumn
public CachedColumn createColumn(StorageType type, long nrow)
Description copied from interface:CachedColumnFactoryCreates a data storage object capable of storing a vector of a given type. Both fixed and unknown element counts are supported.- Specified by:
createColumnin interfaceCachedColumnFactory- Parameters:
type- data type of elements to be storednrow- maximum number of elements to be stored; if a value <0 is supplied, an indeterminate number is permitted- Returns:
- storage object
-
-