casa::BaseTable Class Reference
[Tables_internal_classes]

#include <BaseTable.h>

Inheritance diagram for casa::BaseTable:

Inheritance graph
[legend]
Collaboration diagram for casa::BaseTable:

Collaboration graph
[legend]
List of all members.

Detailed Description

Abstract base class for tables.

Intended use:

Internal

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Prerequisite

Etymology

BaseTable is the (abstract) base class for different kind of tables.

Synopsis

BaseTables defines many virtual functions, which are actually implemented in the underlying table classes like PlainTable and RefTable. Other functions like sort and select are implemented in BaseTable itself.

The functions in BaseTable and its derived classes can only be used by the table system classes. All user access is via the envelope class Table, which references (counted) BaseTable.

To Do

Definition at line 97 of file BaseTable.h.

Public Member Functions

 BaseTable (const String &tableName, int tableOption, uInt nrrow)
 Initialize the object.
virtual ~BaseTable ()
void link ()
 Link to this BaseTable object (i.e.
virtual Bool isNull () const
 Is the table a null table? By default it is not.
virtual void reopenRW ()=0
 Reopen the table for read/write.
virtual Bool asBigEndian () const=0
 Is the table stored in big or little endian format?
virtual Bool isMultiUsed (Bool checkSubTables) const =0
 Is the table in use (i.e.
virtual const TableLocklockOptions () const=0
 Get the locking info.
virtual void mergeLock (const TableLock &lockOptions)=0
 Merge the given lock info with the existing one.
virtual Bool hasLock (FileLocker::LockType) const =0
 Has this process the read or write lock, thus can the table be read or written safely?
virtual Bool lock (FileLocker::LockType, uInt nattempts)=0
 Try to lock the table for read or write access.
virtual void unlock ()=0
 Unlock the table.
virtual void flush (Bool fsync, Bool recursive)=0
 Flush the table, i.e.
virtual void resync ()=0
 Resync the Table object with the table file.
virtual uInt getModifyCounter () const=0
 Get the modify counter.
virtual void setTableChanged ()
 Set the table to being changed.
void doNotWrite ()
 Do not write the table (used in in case of exceptions).
virtual Bool isWritable () const=0
 Test if this table is writable.
const StringtableName () const
 Get the table name.
virtual void rename (const String &newName, int tableOption)
 Rename the table.
virtual int tableType () const
 Get the table type.
int tableOption () const
 Get the table option.
void markForDelete (Bool callback, const String &oldName)
 Mark the table for delete.
void unmarkForDelete (Bool callback, const String &oldName)
 Unmark the table for delete.
Bool isMarkedForDelete () const
 Test if the table is marked for delete.
const TableDesctableDesc () const
 Get the table description.
virtual TableDesc actualTableDesc () const=0
 Get the actual table description.
virtual Record dataManagerInfo () const=0
 Get the data manager info.
virtual TableRecordkeywordSet ()=0
 Get readonly access to the table keyword set.
virtual TableRecordrwKeywordSet ()=0
 Get read/write access to the table keyword set.
TableInfotableInfo ()
 Get access to the TableInfo object.
virtual void flushTableInfo ()
 Write the TableInfo object.
uInt nrow () const
 Get number of rows.
virtual BaseColumngetColumn (uInt columnIndex) const =0
 Get a column object using its index.
virtual BaseColumngetColumn (const String &columnName) const =0
 Get a column object using its name.
virtual Bool canAddRow () const
 Test if it is possible to add a row to this table.
virtual void addRow (uInt nrrow=1, Bool initialize=True)
 Add one or more rows and possibly initialize them.
virtual Bool canRemoveRow () const
 Test if it is possible to remove a row from this table.
virtual DataManagerfindDataManager (const String &dataManagerName) const =0
 Find the data manager with the given name.
BaseTableselect (const TableExprNode &, uInt maxRow)
 Select rows using the given expression.
BaseTableselect (const Vector< uInt > &rownrs)
 Select rows using a vector of row numbers.
BaseTableselect (const Block< Bool > &mask)
 Select rows using a mask block.
BaseTableproject (const Block< String > &columnNames)
 Project the given columns (i.e.
BaseTablesort (const Block< String > &columnNames, const PtrBlock< ObjCompareFunc * > &compareFunctionPointers, const Block< Int > &sortOrder, int sortOption)
 Sort a table on one or more columns of scalars.
BaseTableIteratormakeIterator (const Block< String > &columnNames, const PtrBlock< ObjCompareFunc * > &, const Block< Int > &orders, int option)
 Create an iterator.
void addColumns (const TableDesc &tableDesc, const Record &dmInfo)
 Add one or more columns to the table.
virtual Bool canRemoveColumn (const Vector< String > &columnNames) const =0
 Test if columns can be removed.
virtual void removeColumn (const Vector< String > &columnNames)=0
 Remove columns.
Bool checkRemoveColumn (const Vector< String > &columnNames, Bool throwException) const
 Check if the set of columns can be removed.
virtual Bool canRenameColumn (const String &columnName) const =0
 Test if a column can be renamed.
virtual void renameColumn (const String &newName, const String &oldName)=0
 Rename a column.
virtual Vector< uIntrowNumbers () const
 Get a vector of row numbers.
virtual BaseTableroot ()
 Get pointer to root table (i.e.
virtual Bool rowOrder () const
 Tell if the table is in row order.
virtual Vector< uInt > * rowStorage ()
 By the default the table cannot return the storage of rownrs.
virtual Bool adjustRownrs (uInt nrrow, Vector< uInt > &rownrs, Bool determineOrder) const
 Adjust the row numbers to be the actual row numbers in the root table.
virtual BaseTabledoSort (PtrBlock< BaseColumn * > &, const PtrBlock< ObjCompareFunc * > &, const Block< Int > &sortOrder, int sortOption)
 Do the actual sort.
RefTablemakeRefTable (Bool rowOrder, uInt initialNrrow)
 Create a RefTable object.
void checkRowNumber (uInt rownr) const
 Check if the row number is valid.
Bool isColumnWritable (const String &columnName) const
 Test if the given column is writable.
Bool isColumnWritable (uInt columnIndex) const
Bool isColumnStored (const String &columnName) const
 Test if the given column is stored (otherwise it is virtual).
Bool isColumnStored (uInt columnIndex) const
virtual void copy (const String &newName, int tableOption) const
 Copy the table and all its subtables.
virtual void deepCopy (const String &newName, const Record &dataManagerInfo, int tableOption, Bool valueCopy, int endianFormat, Bool noRows) const
virtual void removeRow (uInt rownr)
 Remove rows.
void removeRow (const Vector< uInt > &rownrs)
BaseTabletabAnd (BaseTable *)
 intersection with another table
BaseTabletabOr (BaseTable *)
 union with another table
BaseTabletabSub (BaseTable *)
 subtract another table
BaseTabletabXor (BaseTable *)
 xor with another table
BaseTabletabNot ()
 take complement
virtual void addColumn (const ColumnDesc &columnDesc)
 Add one or more columns to the table.
virtual void addColumn (const ColumnDesc &columnDesc, const String &dataManager, Bool byName)
virtual void addColumn (const ColumnDesc &columnDesc, const DataManager &dataManager)
virtual void addColumn (const TableDesc &tableDesc, const DataManager &dataManager)

Static Public Member Functions

static void unlink (BaseTable *)
 Unlink from a BaseTable.
static TableInfo tableInfo (const String &tableName)
 Get the table info of the table with the given name.

Protected Member Functions

void scratchCallback (Bool isScratch, const String &oldName) const
 Do the callback for scratch tables (if callback is set).
Bool makeTableDir ()
 Create the table directory when needed (and possible).
void trueDeepCopy (const String &newName, const Record &dataManagerInfo, int tableOption, int endianFormat, Bool noRows) const
 Make a true deep copy of the table.
void prepareCopyRename (const String &newName, int tableOption) const
 Prepare for copying or renaming a table.
virtual void renameSubTables (const String &newName, const String &oldName)
 Rename the subtables (used by rename function).
void throwIfTableExists ()
 Check if the table already exists.
Bool openedForWrite () const
 Test if the table is opened for write.
void writeStart (AipsIO &, Bool bigEndian)
 Start writing a table.
void writeEnd (AipsIO &)
 End writing a table.
Bool shouldNotWrite () const
 Should the table be written.
void getTableInfo ()
 Read the TableInfo object.

Protected Attributes

uInt nrlink_p
uInt nrrow_p
uInt nrrowToAdd_p
TableDesctdescPtr_p
String name_p
int option_p
Bool noWrite_p
Bool delete_p
TableInfo info_p
Bool madeDir_p

Private Member Functions

 BaseTable (const BaseTable &)
 Copy constructor is forbidden, because copying a table requires some more knowledge (like table name of result).
BaseTableoperator= (const BaseTable &)
 Assignment is forbidden, because copying a table requires some more knowledge (like table name of result).
void checkRowNumberThrow (uInt rownr) const
 Throw an exception for checkRowNumber.
void logicCheck (BaseTable *that)
 Check if the tables combined in a logical operation have the same root.
uInt logicRows (uInt *&rownrs, Bool &allocated)
 Get the rownrs of the table in ascending order to be used in the logical operation on the table.
const TableDescmakeTableDesc () const
 Make an empty table description.


Constructor & Destructor Documentation

casa::BaseTable::BaseTable ( const String tableName,
int  tableOption,
uInt  nrrow 
)

Initialize the object.

virtual casa::BaseTable::~BaseTable (  )  [virtual]

casa::BaseTable::BaseTable ( const BaseTable  )  [private]

Copy constructor is forbidden, because copying a table requires some more knowledge (like table name of result).

Declaring it private, makes it unusable.


Member Function Documentation

void casa::BaseTable::link (  ) 

Link to this BaseTable object (i.e.

increase reference count).

static void casa::BaseTable::unlink ( BaseTable  )  [static]

Unlink from a BaseTable.

Delete it if no more references.

virtual Bool casa::BaseTable::isNull (  )  const [virtual]

Is the table a null table? By default it is not.

Referenced by casa::Table::isNull().

virtual void casa::BaseTable::reopenRW (  )  [pure virtual]

Reopen the table for read/write.

Referenced by casa::Table::reopenRW().

virtual Bool casa::BaseTable::asBigEndian (  )  const [pure virtual]

Is the table stored in big or little endian format?

virtual Bool casa::BaseTable::isMultiUsed ( Bool  checkSubTables  )  const [pure virtual]

Is the table in use (i.e.

open) in another process? If checkSubTables is set, it is also checked if a subtable is used in another process.

Referenced by casa::Table::isMultiUsed().

virtual const TableLock& casa::BaseTable::lockOptions (  )  const [pure virtual]

Get the locking info.

Referenced by casa::Table::lockOptions().

virtual void casa::BaseTable::mergeLock ( const TableLock lockOptions  )  [pure virtual]

Merge the given lock info with the existing one.

virtual Bool casa::BaseTable::hasLock ( FileLocker::LockType   )  const [pure virtual]

Has this process the read or write lock, thus can the table be read or written safely?

Referenced by casa::Table::hasLock().

virtual Bool casa::BaseTable::lock ( FileLocker::LockType  ,
uInt  nattempts 
) [pure virtual]

Try to lock the table for read or write access.

Referenced by casa::Table::lock().

virtual void casa::BaseTable::unlock (  )  [pure virtual]

Unlock the table.

This will also synchronize the table data, thus force the data to be written to disk.

Referenced by casa::Table::unlock().

virtual void casa::BaseTable::flush ( Bool  fsync,
Bool  recursive 
) [pure virtual]

Flush the table, i.e.

write it to disk.

Referenced by casa::Table::flush().

virtual void casa::BaseTable::resync (  )  [pure virtual]

Resync the Table object with the table file.

Referenced by casa::Table::resync().

virtual uInt casa::BaseTable::getModifyCounter (  )  const [pure virtual]

Get the modify counter.

virtual void casa::BaseTable::setTableChanged (  )  [virtual]

Set the table to being changed.

By default it does nothing.

Referenced by casa::ColumnSet::setTableChanged().

void casa::BaseTable::doNotWrite (  )  [inline]

Do not write the table (used in in case of exceptions).

Definition at line 158 of file BaseTable.h.

References noWrite_p, and casa::True.

virtual Bool casa::BaseTable::isWritable (  )  const [pure virtual]

Test if this table is writable.

This tells if values can be put into a column.

Referenced by casa::Table::isWritable().

Bool casa::BaseTable::isColumnWritable ( const String columnName  )  const

Test if the given column is writable.

Referenced by casa::Table::isColumnWritable().

Bool casa::BaseTable::isColumnWritable ( uInt  columnIndex  )  const

Bool casa::BaseTable::isColumnStored ( const String columnName  )  const

Test if the given column is stored (otherwise it is virtual).

Referenced by casa::Table::isColumnStored().

Bool casa::BaseTable::isColumnStored ( uInt  columnIndex  )  const

const String& casa::BaseTable::tableName (  )  const [inline]

Get the table name.

Definition at line 178 of file BaseTable.h.

References name_p.

Referenced by casa::Table::tableName().

virtual void casa::BaseTable::rename ( const String newName,
int  tableOption 
) [virtual]

Rename the table.

The following options can be given:

Table::Update
A table with this name must already exists, which will be overwritten. When succesfully renamed, the table is unmarked for delete (if necessary).
Table::New
When a table with this name exists, it will be overwritten. When succesfully renamed, the table is unmarked for delete (if necessary).
Table::NewNoReplace
When a table with this name already exists, an exception is thrown. When succesfully renamed, the table is unmarked for delete (if necessary).
Table::Scratch
Same as Table::New, but followed by markForDelete().
The rename function in this base class renames the table file. In a derived class (e.g. PlainTable) the function should also be implemented to rename subtables in its keywords.

Referenced by casa::Table::rename().

virtual void casa::BaseTable::copy ( const String newName,
int  tableOption 
) const [virtual]

Copy the table and all its subtables.

The default implementation of deepCopy is to call copy. The following options can be given:

Table::New
When a table with this name exists, it will be overwritten.
Table::NewNoReplace
When a table with this name already exists, an exception is thrown.
Table::Scratch
Same as Table::New, but followed by markForDelete().

virtual void casa::BaseTable::deepCopy ( const String newName,
const Record dataManagerInfo,
int  tableOption,
Bool  valueCopy,
int  endianFormat,
Bool  noRows 
) const [virtual]

Referenced by casa::Table::deepCopy().

virtual int casa::BaseTable::tableType (  )  const [virtual]

Get the table type.

By default it returns Table::Plain.

Referenced by casa::Table::tableType().

int casa::BaseTable::tableOption (  )  const [inline]

Get the table option.

Definition at line 231 of file BaseTable.h.

References option_p.

Referenced by casa::Table::tableOption().

void casa::BaseTable::markForDelete ( Bool  callback,
const String oldName 
)

Mark the table for delete.

This means that the underlying table gets deleted when it is actually destructed. The scratchCallback function is called when needed.

Referenced by casa::Table::markForDelete().

void casa::BaseTable::unmarkForDelete ( Bool  callback,
const String oldName 
)

Unmark the table for delete.

This means the underlying table does not get deleted when destructed. The scratchCallback function is called when needed.

Referenced by casa::Table::unmarkForDelete().

Bool casa::BaseTable::isMarkedForDelete (  )  const [inline]

Test if the table is marked for delete.

Definition at line 246 of file BaseTable.h.

References delete_p.

Referenced by casa::Table::isMarkedForDelete().

const TableDesc& casa::BaseTable::tableDesc (  )  const [inline]

Get the table description.

Definition at line 250 of file BaseTable.h.

References makeTableDesc(), and tdescPtr_p.

Referenced by casa::Table::tableDesc().

virtual TableDesc casa::BaseTable::actualTableDesc (  )  const [pure virtual]

Get the actual table description.

virtual Record casa::BaseTable::dataManagerInfo (  )  const [pure virtual]

Get the data manager info.

virtual TableRecord& casa::BaseTable::keywordSet (  )  [pure virtual]

Get readonly access to the table keyword set.

Referenced by casa::Table::keywordSet().

virtual TableRecord& casa::BaseTable::rwKeywordSet (  )  [pure virtual]

Get read/write access to the table keyword set.

This requires that the table is locked (or it gets locked when using AutoLocking mode).

TableInfo& casa::BaseTable::tableInfo (  )  [inline]

Get access to the TableInfo object.

Definition at line 268 of file BaseTable.h.

References info_p.

Referenced by casa::Table::tableInfo().

static TableInfo casa::BaseTable::tableInfo ( const String tableName  )  [static]

Get the table info of the table with the given name.

An empty object is returned when the table is unknown.

virtual void casa::BaseTable::flushTableInfo (  )  [virtual]

Write the TableInfo object.

Referenced by casa::Table::flushTableInfo().

uInt casa::BaseTable::nrow (  )  const [inline]

Get number of rows.

Definition at line 279 of file BaseTable.h.

References nrrow_p.

Referenced by casa::Table::nrow().

virtual BaseColumn* casa::BaseTable::getColumn ( uInt  columnIndex  )  const [pure virtual]

Get a column object using its index.

virtual BaseColumn* casa::BaseTable::getColumn ( const String columnName  )  const [pure virtual]

Get a column object using its name.

virtual Bool casa::BaseTable::canAddRow (  )  const [virtual]

Test if it is possible to add a row to this table.

Referenced by casa::Table::canAddRow().

virtual void casa::BaseTable::addRow ( uInt  nrrow = 1,
Bool  initialize = True 
) [virtual]

Add one or more rows and possibly initialize them.

This will fail for tables not supporting addition of rows.

Referenced by casa::Table::addRow().

virtual Bool casa::BaseTable::canRemoveRow (  )  const [virtual]

Test if it is possible to remove a row from this table.

Referenced by casa::Table::canRemoveRow().

virtual void casa::BaseTable::removeRow ( uInt  rownr  )  [virtual]

Remove rows.

This will fail for tables not supporting removal of rows. Tip: The following code fragments do NOT have the same result:

           tab.removeRow (10);      // remove row 10
           tab.removeRow (20);      // remove row 20, which was 21
       
           Vector<uInt> vec(2);
           vec(0) = 10;
           vec(1) = 20;
           tab.removeRow (vec);     // remove row 10 and 20
because in the first fragment removing row 10 turns the former row 21 into row 20.

Referenced by casa::Table::removeRow().

void casa::BaseTable::removeRow ( const Vector< uInt > &  rownrs  ) 

virtual DataManager* casa::BaseTable::findDataManager ( const String dataManagerName  )  const [pure virtual]

Find the data manager with the given name.

Referenced by casa::Table::findDataManager().

BaseTable* casa::BaseTable::select ( const TableExprNode ,
uInt  maxRow 
)

Select rows using the given expression.

BaseTable* casa::BaseTable::select ( const Vector< uInt > &  rownrs  ) 

Select rows using a vector of row numbers.

BaseTable* casa::BaseTable::select ( const Block< Bool > &  mask  ) 

Select rows using a mask block.

The length of the block must match the number of rows in the table. If True, the corresponding row will be selected.

BaseTable* casa::BaseTable::project ( const Block< String > &  columnNames  ) 

Project the given columns (i.e.

select the columns).

BaseTable* casa::BaseTable::tabAnd ( BaseTable  ) 

intersection with another table

BaseTable* casa::BaseTable::tabOr ( BaseTable  ) 

union with another table

BaseTable* casa::BaseTable::tabSub ( BaseTable  ) 

subtract another table

BaseTable* casa::BaseTable::tabXor ( BaseTable  ) 

xor with another table

BaseTable* casa::BaseTable::tabNot (  ) 

take complement

BaseTable* casa::BaseTable::sort ( const Block< String > &  columnNames,
const PtrBlock< ObjCompareFunc * > &  compareFunctionPointers,
const Block< Int > &  sortOrder,
int  sortOption 
)

Sort a table on one or more columns of scalars.

BaseTableIterator* casa::BaseTable::makeIterator ( const Block< String > &  columnNames,
const PtrBlock< ObjCompareFunc * > &  ,
const Block< Int > &  orders,
int  option 
)

Create an iterator.

virtual void casa::BaseTable::addColumn ( const ColumnDesc columnDesc  )  [virtual]

Add one or more columns to the table.

The default implementation throws an "invalid operation" exception.

Referenced by casa::Table::addColumn().

virtual void casa::BaseTable::addColumn ( const ColumnDesc columnDesc,
const String dataManager,
Bool  byName 
) [virtual]

virtual void casa::BaseTable::addColumn ( const ColumnDesc columnDesc,
const DataManager dataManager 
) [virtual]

virtual void casa::BaseTable::addColumn ( const TableDesc tableDesc,
const DataManager dataManager 
) [virtual]

void casa::BaseTable::addColumns ( const TableDesc tableDesc,
const Record dmInfo 
)

Add one or more columns to the table.

The data manager to use is described in the record.

Referenced by casa::Table::addColumn().

virtual Bool casa::BaseTable::canRemoveColumn ( const Vector< String > &  columnNames  )  const [pure virtual]

Test if columns can be removed.

Referenced by casa::Table::canRemoveColumn().

virtual void casa::BaseTable::removeColumn ( const Vector< String > &  columnNames  )  [pure virtual]

Remove columns.

Referenced by casa::Table::removeColumn().

Bool casa::BaseTable::checkRemoveColumn ( const Vector< String > &  columnNames,
Bool  throwException 
) const

Check if the set of columns can be removed.

It checks if columns have not been specified twice and it checks if they exist. If the flag is set an exception is thrown if errors are found.

virtual Bool casa::BaseTable::canRenameColumn ( const String columnName  )  const [pure virtual]

Test if a column can be renamed.

Referenced by casa::Table::canRenameColumn().

virtual void casa::BaseTable::renameColumn ( const String newName,
const String oldName 
) [pure virtual]

Rename a column.

Referenced by casa::Table::renameColumn().

virtual Vector<uInt> casa::BaseTable::rowNumbers (  )  const [virtual]

Get a vector of row numbers.

By default it returns the row numbers 0.\.nrrow()-1. It needs to be implemented for RefTable only.

virtual BaseTable* casa::BaseTable::root (  )  [virtual]

Get pointer to root table (i.e.

parent of a RefTable). Default it is this table. It is meant for the reference tables after a select or sort which can then still name their parent as the root.

Referenced by casa::Table::isRootTable(), and casa::Table::isSameRoot().

virtual Bool casa::BaseTable::rowOrder (  )  const [virtual]

Tell if the table is in row order.

By default it is, since normally a table is always in row order. It is meant for RefTable-s, where the rows can be in another (sorted) order.

virtual Vector<uInt>* casa::BaseTable::rowStorage (  )  [virtual]

By the default the table cannot return the storage of rownrs.

That can only be done by a RefTable, where it is implemented.

virtual Bool casa::BaseTable::adjustRownrs ( uInt  nrrow,
Vector< uInt > &  rownrs,
Bool  determineOrder 
) const [virtual]

Adjust the row numbers to be the actual row numbers in the root table.

This is, for instance, used when a RefTable is sorted. Optionally it also determines if the resulting rows are in order.

virtual BaseTable* casa::BaseTable::doSort ( PtrBlock< BaseColumn * > &  ,
const PtrBlock< ObjCompareFunc * > &  ,
const Block< Int > &  sortOrder,
int  sortOption 
) [virtual]

Do the actual sort.

The default implementation is suitable for almost all cases. Only in RefTable a smarter implementation is provided.

RefTable* casa::BaseTable::makeRefTable ( Bool  rowOrder,
uInt  initialNrrow 
)

Create a RefTable object.

void casa::BaseTable::checkRowNumber ( uInt  rownr  )  const [inline]

Check if the row number is valid.

It throws an exception if out of range.

Definition at line 441 of file BaseTable.h.

References checkRowNumberThrow(), nrrow_p, and nrrowToAdd_p.

Referenced by casa::ROTableColumn::checkRowNumber().

void casa::BaseTable::scratchCallback ( Bool  isScratch,
const String oldName 
) const [protected]

Do the callback for scratch tables (if callback is set).

Bool casa::BaseTable::makeTableDir (  )  [protected]

Create the table directory when needed (and possible).

When the file already exists, check if it is a directory. It returns True when it actually created the directory.

void casa::BaseTable::trueDeepCopy ( const String newName,
const Record dataManagerInfo,
int  tableOption,
int  endianFormat,
Bool  noRows 
) const [protected]

Make a true deep copy of the table.

void casa::BaseTable::prepareCopyRename ( const String newName,
int  tableOption 
) const [protected]

Prepare for copying or renaming a table.

It checks if the target table already exists and removes it when necessary.

virtual void casa::BaseTable::renameSubTables ( const String newName,
const String oldName 
) [protected, virtual]

Rename the subtables (used by rename function).

void casa::BaseTable::throwIfTableExists (  )  [protected]

Check if the table already exists.

Throw an exception if so.

Bool casa::BaseTable::openedForWrite (  )  const [protected]

Test if the table is opened for write.

void casa::BaseTable::writeStart ( AipsIO ,
Bool  bigEndian 
) [protected]

Start writing a table.

It does a putstart and writes nrrow_p. It should be ended by calling writeEnd.

void casa::BaseTable::writeEnd ( AipsIO  )  [protected]

End writing a table.

Bool casa::BaseTable::shouldNotWrite (  )  const [inline, protected]

Should the table be written.

This flag is False if an exception was thrown.

Definition at line 498 of file BaseTable.h.

References noWrite_p.

void casa::BaseTable::getTableInfo (  )  [protected]

Read the TableInfo object.

BaseTable& casa::BaseTable::operator= ( const BaseTable  )  [private]

Assignment is forbidden, because copying a table requires some more knowledge (like table name of result).

Declaring it private, makes it unusable.

void casa::BaseTable::checkRowNumberThrow ( uInt  rownr  )  const [private]

Throw an exception for checkRowNumber.

Referenced by checkRowNumber().

void casa::BaseTable::logicCheck ( BaseTable that  )  [private]

Check if the tables combined in a logical operation have the same root.

uInt casa::BaseTable::logicRows ( uInt *&  rownrs,
Bool allocated 
) [private]

Get the rownrs of the table in ascending order to be used in the logical operation on the table.

const TableDesc& casa::BaseTable::makeTableDesc (  )  const [private]

Make an empty table description.

This is used if one asks for the description of a NullTable. Creating an empty TableDesc in the NullTable takes too much time. Furthermore it causes static initialization order problems.

Referenced by tableDesc().


Member Data Documentation

uInt casa::BaseTable::nrlink_p [protected]

Definition at line 446 of file BaseTable.h.

uInt casa::BaseTable::nrrow_p [protected]

Definition at line 447 of file BaseTable.h.

Referenced by checkRowNumber(), and nrow().

uInt casa::BaseTable::nrrowToAdd_p [protected]

Definition at line 448 of file BaseTable.h.

Referenced by checkRowNumber().

TableDesc* casa::BaseTable::tdescPtr_p [protected]

Definition at line 449 of file BaseTable.h.

Referenced by tableDesc().

String casa::BaseTable::name_p [protected]

Definition at line 450 of file BaseTable.h.

Referenced by tableName().

int casa::BaseTable::option_p [protected]

Definition at line 451 of file BaseTable.h.

Referenced by tableOption().

Bool casa::BaseTable::noWrite_p [protected]

Definition at line 452 of file BaseTable.h.

Referenced by doNotWrite(), and shouldNotWrite().

Bool casa::BaseTable::delete_p [protected]

Definition at line 453 of file BaseTable.h.

Referenced by isMarkedForDelete().

TableInfo casa::BaseTable::info_p [protected]

Definition at line 454 of file BaseTable.h.

Referenced by tableInfo().

Bool casa::BaseTable::madeDir_p [protected]

Definition at line 455 of file BaseTable.h.


The documentation for this class was generated from the following file:
Generated on Mon Sep 1 22:45:17 2008 for NRAOCASA by  doxygen 1.5.1