28 #ifndef TABLES_TSMDATACOLUMN_H
29 #define TABLES_TSMDATACOLUMN_H
33 #include <casacore/casa/aips.h>
34 #include <casacore/tables/DataMan/TSMColumn.h>
35 #include <casacore/tables/DataMan/TSMCube.h>
36 #include <casacore/casa/BasicSL/Complex.h>
37 #include <casacore/casa/Arrays/IPosition.h>
38 #include <casacore/casa/BasicSL/String.h>
39 #include <casacore/casa/OS/Conversion.h>
249 void readTile (
void* to,
const void* from,
uInt nrPixels);
296 const void* dataPtr,
Bool writeFlag);
300 const void* dataPtr,
Bool writeFlag);
309 const void* dataPtr,
Bool writeFlag);
314 const void* dataPtr,
Bool writeFlag);
320 const void* dataPtr,
Bool writeFlag);
324 char* dataPtr,
Bool writeFlag,
331 char* dataPtr,
Bool writeFlag,
Non-templated base class for templated Array class.
size_t ValueFunction(void *to, const void *from, size_t nvalues)
Define the signature of a function converting nvalues values from internal to external format or vice...
virtual void getDComplex(rownr_t rownr, DComplex *dataPtr)
virtual void putArrayColumnV(const ArrayBase &arr)
Put all array values in the column.
void accessColumnSliceCells(const RefRows &rownrs, const Slicer &ns, const IPosition &shape, const void *dataPtr, Bool writeFlag)
Read or write some cells in a column.
virtual void putColumnSliceV(const Slicer &slicer, const ArrayBase &data)
Put a section into all array values in the column.
TSMDataColumn(const TSMColumn &column)
Create a data column from the given column.
virtual void putuShort(rownr_t rownr, const uShort *dataPtr)
virtual void getdouble(rownr_t rownr, double *dataPtr)
virtual void getuShort(rownr_t rownr, uShort *dataPtr)
TSMDataColumn(const TSMDataColumn &)
Forbid copy constructor.
void accessCell(rownr_t rownr, const void *dataPtr, Bool writeFlag)
Read or write a data cell in the cube.
virtual void putArrayColumnCellsV(const RefRows &rownrs, const ArrayBase &dataPtr)
Put the array values into some cells of the column.
virtual void getArrayColumnCellsV(const RefRows &rownrs, ArrayBase &data)
Get the array values in some cells of the column.
virtual void getColumnSliceV(const Slicer &slicer, ArrayBase &arr)
Get a section of all arrays in the column.
virtual ~TSMDataColumn()
Frees up the storage.
void accessColumnCells(const RefRows &rownrs, const IPosition &shape, const void *dataPtr, Bool writeFlag)
Read or write some cells in a column.
virtual void getBool(rownr_t rownr, Bool *dataPtr)
Get a scalar value in the given row.
IPosition shape(rownr_t rownr)
Get the shape of the item in the given row.
void setColumnNumber(uInt colnr)
Set column sequence number.
void setShape(rownr_t rownr, const IPosition &shape)
Set the shape of the data array in the given row.
void accessSlicedCells(TSMCube *hypercube, char *dataPtr, Bool writeFlag, const IPosition &start, const IPosition &end, const IPosition &incr)
Read or write the sliced cells given by start,end,incr.
Bool isShapeDefined(rownr_t rownr)
Is the value shape defined in the given row?
void writeTile(void *to, const void *from, uInt nrPixels)
Write the data of the column into a tile.
void setShapeTiled(rownr_t rownr, const IPosition &shape, const IPosition &tileShape)
Set the shape and tile shape of the array in the given row.
uInt64 dataLength(uInt64 nrPixels) const
Determine the length to store the given number of pixels.
Bool canChangeShape() const
Changing array shapes for non-FixedShape columns when the parent tiled storage manager can handle it.
virtual void getInt64(rownr_t rownr, Int64 *dataPtr)
virtual void getArrayV(rownr_t rownr, ArrayBase &data)
Get the array value in the given row.
Bool mustConvert_p
Is a conversion necessary?
void accessFullCells(TSMCube *hypercube, char *dataPtr, Bool writeFlag, const IPosition &start, const IPosition &end, const IPosition &incr)
Read or write the full cells given by start,end,incr.
Conversion::ValueFunction * getConvertFunction(Bool writeFlag) const
Get the function to convert from external to local format (or vice-versa if writeFlag=True).
uInt localPixelSize_p
The local size of a pixel.
uInt colnr_p
The column sequence number.
virtual void getColumnSliceCellsV(const RefRows &rownrs, const Slicer &ns, ArrayBase &data)
Get a section from some cells of the column.
void accessColumnSlice(const Slicer &ns, const void *dataPtr, Bool writeFlag)
Read or write a slice from the entire column.
Bool isConversionNeeded() const
Does a conversion (byte swap) needs to be done?
TSMDataColumn & operator=(const TSMDataColumn &)
Forbid assignment.
virtual void getShort(rownr_t rownr, Short *dataPtr)
virtual void putBool(rownr_t rownr, const Bool *dataPtr)
Put a scalar value into the given row.
virtual void getInt(rownr_t rownr, Int *dataPtr)
uInt tilePixelSize_p
The (canonical) size of a pixel in a tile.
void accessCellSlice(rownr_t rownr, const Slicer &ns, const void *dataPtr, Bool writeFlag)
Read or write a slice of a data cell in the cube.
uInt convPixelSize_p
The multiplication factor for a conversion operation.
virtual void putShort(rownr_t rownr, const Short *dataPtr)
virtual void putDComplex(rownr_t rownr, const DComplex *dataPtr)
virtual void getSliceV(rownr_t rownr, const Slicer &slicer, ArrayBase &dataPtr)
Get into a section of the array in the given row.
virtual void putArrayV(rownr_t rownr, const ArrayBase &data)
Put the array value into the given row.
void readTile(void *to, const void *from, uInt nrPixels)
Read the data of the column from a tile.
virtual void putdouble(rownr_t rownr, const double *dataPtr)
virtual void putInt64(rownr_t rownr, const Int64 *dataPtr)
virtual void putColumnSliceCellsV(const RefRows &rownrs, const Slicer &ns, const ArrayBase &data)
Put into a section of some cells of the column.
virtual void getfloat(rownr_t rownr, float *dataPtr)
virtual void putuChar(rownr_t rownr, const uChar *dataPtr)
uInt tilePixelSize() const
Return the size of a pixel in the tile in external format.
IPosition tileShape(rownr_t rownr)
Get the tile shape of the item in the given row.
virtual void getuChar(rownr_t rownr, uChar *dataPtr)
virtual void putuInt(rownr_t rownr, const uInt *dataPtr)
size_t getNrConvert() const
Get nr of elements in a value to convert (usually 1, but 2 for Complex).
Conversion::ValueFunction * readFunc_p
The conversion function needed when reading.
virtual void putComplex(rownr_t rownr, const Complex *dataPtr)
virtual void getuInt(rownr_t rownr, uInt *dataPtr)
Conversion::ValueFunction * writeFunc_p
The conversion function needed when writing.
virtual void getComplex(rownr_t rownr, Complex *dataPtr)
virtual void putInt(rownr_t rownr, const Int *dataPtr)
virtual void getArrayColumnV(ArrayBase &arr)
Get all array values in the column.
virtual void putSliceV(rownr_t rownr, const Slicer &slicer, const ArrayBase &data)
Put into a section of the array in the given row.
virtual void putfloat(rownr_t rownr, const float *dataPtr)
void accessColumn(const void *dataPtr, Bool writeFlag)
Read or write an entire column.
uInt localPixelSize() const
Return the size of a pixel in the tile in local format.
std::complex< Float > Complex
std::complex< Double > DComplex
this file contains all the compiler specific defines
long long Int64
Define the extra non-standard types used by Casacore (like proposed uSize, Size)
bool Bool
Define the standard types used by Casacore.
uInt64 rownr_t
Define the type of a row number in a table.
unsigned long long uInt64