28 #ifndef TABLES_COLUMNDESC_H 29 #define TABLES_COLUMNDESC_H 33 #include <casacore/casa/aips.h> 34 #include <casacore/tables/Tables/BaseColDesc.h> 35 #include <casacore/casa/Containers/SimOrdMap.h> 36 #include <casacore/casa/BasicSL/String.h> 37 #include <casacore/casa/Arrays/IPosition.h> 38 #include <casacore/casa/OS/Mutex.h> 326 void show (ostream& os)
const;
const String & comment() const
Get comment string.
A Vector of integers, for indexing into Array<T> objects.
static void unlockedRegisterCtor(const String &type, ColumnDescCtor *func)
Register a constructor without doing a mutex lock.
void setOptions(int options)
Set the options to the given value.
void setShape(const IPosition &shape)
Set the predefined shape.
Bool operator==(const ColumnDesc &) const
Comparison.
BaseColumnDesc * colPtr_p
const IPosition & shape() const
Get the predefined shape.
DataType trueDataType() const
Get the true data type of the column.
void checkAdd(const ColumnDescSet &cds) const
Check if a column can be handled by ColumnDescSet.
friend AipsIO & operator<<(AipsIO &ios, const ColumnDesc &cd)
Write into AipsIO.
AipsIO is the object persistency mechanism of Casacore.
String & dataManagerType()
Get the type name of the default data manager (allowing it to be changed).
String & comment()
Get comment string (allowing it to be changed).
DataType dataType() const
Get the data type of the column.
void setMaxLength(uInt maxLength)
Set the maximum value length.
An abstract base class for table column descriptions.
void setNdim(uInt ndim)
Set the number of dimensions.
Envelope class for the description of a table column.
void show() const
Show the column on cout.
virtual void checkRename(const ColumnDescSet &cds, const String &newName) const
const String & dataManagerType() const
Get the type name of the default data manager.
void checkRename(const ColumnDescSet &cds, const String &newName) const
Check when a column gets renamed in a table description.
const TableDesc * tableDesc() const
Get table description (in case column contains subtables).
void handleRemove(ColumnDescSet &cds)
RefColumn * makeRefColumn(RefTable *rtp, BaseColumn *bcp) const
Create a RefColumn column object out of this column description.
uInt maxLength() const
Get the maximum value length.
uInt maxLength() const
Get the maximum value length.
Thread-safe initialization of global variables.
Int options() const
Get the options.
int options() const
Get the options.
void setShape(const IPosition &shape, Bool directOption)
Class to manage a set of table columns.
Bool isFixedShape() const
Check if the column is defined with a fixed shape.
const TableRecord & keywordSet() const
static MutexedInit theirMutexedInit
Define a map which maps the name of the various XXColumnDesc classes to a static function constructin...
virtual void handleRename(ColumnDescSet &cds, const String &oldName)
void setName(const String &name)
Set the name of the column (for a rename).
Int ndim() const
Get the number of dimensions.
const String & dataManagerGroup() const
Get the data manager group.
void handleAdd(ColumnDescSet &cds)
Take action after a column has been handled by ColumnDescSet.
const TableDesc * tableDesc() const
Get table description (in case column contains subtables).
DataType dataType() const
Get the data type of the column.
void renameAction(const String &newName, const String &oldName)
This function allows each column to act upon a rename of another column.
const TableRecord & keywordSet() const
void setOptions(Int options)
Set the options to the given value.
virtual PlainColumn * makeColumn(ColumnSet *) const =0
Make a PlainColumn object out of the description.
void putFile(AipsIO &ios, const TableAttr &) const
Store the object in AipsIO.
virtual ConcatColumn * makeConcatColumn(ConcatTable *) const
Make a ConcatColumn object out of the description.
void setNdim(uInt ndim)
Set the number of dimensions.
friend AipsIO & operator>>(AipsIO &ios, ColumnDesc &cd)
Read from AipsIO.
String & dataManagerGroup()
Get the data manager group.
const IPosition & shape() const
Get the predefined shape.
Simple map with keys ordered.
virtual void checkAdd(const ColumnDescSet &cds) const
Check if a column can be handled by ColumnDescSet.
Class for a table as a view of another table.
ColumnDesc & operator=(const ColumnDesc &that)
Assignment (copy semantics).
static void doRegisterMainCtor(void *)
Do the actual (thread-safe) registration of the main data managers.
TableRecord & rwKeywordSet()
Get access to the set of keywords.
BaseColumnDesc * ColumnDescCtor(const String &className)
Define the type of a XXColumnDesc construction function.
ColumnDesc()
Default constructor (needed for ColumnDescSet).
Set of table column descriptions.
static SimpleOrderedMap< String, BaseColumnDesc *(*)(const String &)> theirRegisterMap
TableRecord & rwKeywordSet()
Get access to the set of keywords.
undefined values are possible
void setName(const String &name)
Set the name of the column.
void handleRename(ColumnDescSet &cds, const String &oldName)
bool Bool
Define the standard types used by Casacore.
void setDefaultDataManager(Bool always=True)
If always==True they are always set, otherwise only if empty.
Bool isScalar() const
Test if column is scalar, array or table.
ConcatColumn * makeConcatColumn(ConcatTable *rtp) const
Create a ConcatColumn column object out of this column description.
void setDefaultDataManager(Bool always)
Set the data manager type and group to the default.
void setMaxLength(uInt maxLength)
Set the maximum value length.
static BaseColumnDesc * unknownColumnDesc(const String &name)
Serve as default function for theirRegisterMap (see below), which catches all unknown XXColumnDesc cl...
RefColumn * makeRefColumn(RefTable *, BaseColumn *) const
Make a RefColumn object out of the description.
A hierarchical collection of named fields of various types.
Bool isTable() const
Test if column is a table.
void getFile(AipsIO &, const TableAttr &)
Get the object from AipsIO.
const String & dataManagerType() const
Get the type name of the default data manager.
void setShape(const IPosition &shape)
Set the predefined shape.
const String & dataTypeId() const
Get the type id for non-standard data types (i.e.
static void registerMainCtor()
Register the main data managers (if not done yet).
void exec()
Execute the initialization function if not done yet.
Base class for a column in a plain table.
const String & name() const
Get the name of the column.
Bool operator!=(const ColumnDesc &) const
virtual void handleRemove(ColumnDescSet &cds)
static ColumnDescCtor * getCtor(const String &name)
Get a construction function for a XXColumnDesc object (thread-safe).
Bool isArray() const
Test if column is an array.
virtual void handleAdd(ColumnDescSet &cds)
Take action after a column has been handled by ColumnDescSet.
static void registerCtor(const String &name, ColumnDescCtor *)
Register a "XXColumnDesc" constructor (thread-safe).
Int ndim() const
Get the number of dimensions.
String: the storage and methods of handling collections of characters.
Define the structure of a Casacore table.
virtual void renameAction(const String &newName, const String &oldName)
This function allows each column to act upon a rename of another column.
Class to view a concatenation of tables as a single table.
Some attributes of a table.
const String & dataManagerGroup() const
Get the data manager group.
A column in a concatenated table.
const String & dataTypeId() const
Get the type id for non-standard data types (i.e.
this file contains all the compiler specific defines
PlainColumn * makeColumn(ColumnSet *csp) const
Create a PlainColumn column object out of this column description.
Bool isScalar() const
Test if column is a scalar.
Option
Enumerate the possible column options.
A column in a reference table.
const String & comment() const
Get comment string.
Abstract base class for a table column.