28 #ifndef TABLES_COMPRESSFLOAT_H
29 #define TABLES_COMPRESSFLOAT_H
149 const String& storedColumnName,
164 const String& storedColumnName,
165 const String& scaleColumnName,
166 const String& offsetColumnName,
virtual DataManager * clone() const
Clone the engine object.
void putFullPart(uInt rownr, const Slicer &slicer, Array< Float > &fullArray, const Array< Float > &partArray, Float minVal, Float maxVal)
Fill the array part into the full array and put it using the given min/max values.
ScalarColumn< Float > * scaleColumn_p
virtual void getColumnSliceCells(const RefRows &rownrs, const Slicer &slicer, Array< Float > &data)
Get a section of some arrays in the column.
~CompressFloat()
Destructor is mandatory.
TableExprNode array(const TableExprNode &values, const TableExprNodeSet &shape)
Create an array of the given shape and fill it with the values.
virtual void create(uInt initialNrrow)
Initialize the object for a new table.
Templated virtual column engine for a table array of any type.
CompressFloat & operator=(const CompressFloat &)
Assignment is not needed and therefore forbidden (so it is made private and not implemented).
void scaleOnPut(Float scale, Float offset, const Array< Float > &array, Array< Short > &target)
Scale and/or offset array to target.
virtual String dataManagerName() const
Get the name given to the engine (is the virtual column name).
virtual void putArrayColumn(const Array< Float > &array)
Put an entire column.
virtual void putArray(uInt rownr, const Array< Float > &array)
Put an array in the given row.
Virtual column engine to scale a table float array.
virtual void putColumnSlice(const Slicer &slicer, const Array< Float > &array)
Put a section of all arrays in the column.
static void registerClass()
Register the class name and the static makeObject "constructor".
virtual void reopenRW()
Reopen the engine for read/write access.
CompressFloat(const String &virtualColumnName, const String &storedColumnName, Float scale, Float offset=0)
Construct an engine to scale all arrays in a column with the given offset and scale factor...
ABSTRACT CLASSES Deliberately vague to be general enough to allow for many different types of data
void findMinMax(Float &minVal, Float &maxVal, const Array< Float > &array) const
Find minimum and maximum from the array data.
ScalarColumn< Float > * offsetColumn_p
virtual void getArray(uInt rownr, Array< Float > &array)
Get an array in the given row.
virtual String dataManagerType() const
Return the type name of the engine (i.e.
void putPart(uInt rownr, const Slicer &slicer, const Array< Float > &array, Float scale, Float offset)
Put a part of an array in a row using given scale/offset values.
void scaleColumnOnPut(const Array< Float > &array, Array< Short > &target)
Scale and/or offset array to target for the entire column.
virtual void getColumnSlice(const Slicer &slicer, Array< Float > &array)
Get a section of all arrays in the column.
Class holding the row numbers in a RefTable.
virtual void addRowInit(uInt startRow, uInt nrrow)
Add rows to the table.
static DataManager * makeObject(const String &dataManagerType, const Record &spec)
Define the "constructor" to construct this engine when a table is read back.
A hierarchical collection of named fields of various types.
bool Bool
Define the standard types used by Casacore.
virtual void putColumnSliceCells(const RefRows &rownrs, const Slicer &slicer, const Array< Float > &data)
Put into a section of some arrays in the column.
virtual void getArrayColumnCells(const RefRows &rownrs, Array< Float > &data)
Get some array values in the column.
virtual void putSlice(uInt rownr, const Slicer &slicer, const Array< Float > &array)
Put into a section of the array in the given row.
virtual void prepare()
Preparing consists of setting the writable switch and adding the initial number of rows in case of cr...
virtual void putArrayColumnCells(const RefRows &rownrs, const Array< Float > &data)
Put some array values in the column.
Specify which elements to extract from an n-dimensional array.
Float getScale(uInt rownr)
Get the scale value for this row.
virtual void getArrayColumn(Array< Float > &array)
Get an entire column.
virtual Record dataManagerSpec() const
Record a record containing data manager specifications.
void scaleOnGet(Float scale, Float offset, Array< Float > &array, const Array< Short > &target)
Scale and/or offset target to array.
Abstract base class for a data manager.
void makeScaleOffset(Float &scale, Float &offset, Float minVal, Float maxVal) const
Make scale and offset from the minimum and maximum of the array data.
static String className()
Return the name of the class.
String: the storage and methods of handling collections of characters.
virtual void getSlice(uInt rownr, const Slicer &slicer, Array< Float > &array)
Get a section of the array in the given row.
void scaleColumnOnGet(Array< Float > &array, const Array< Short > &target)
Scale and/or offset target to array for the entire column.
Float getOffset(uInt rownr)
Get the offset value for this row.
#define casacore
<X11/Intrinsic.h> #defines true, false, casacore::Bool, and String.