casacore
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members

More...

#include <SSMBase.h>

Public Member Functions

 SSMBase (Int aBucketSize=0, uInt aCacheSize=1)
 Create a Standard storage manager with default name SSM. More...
 
 SSMBase (const String &aDataManName, Int aBucketSize=0, uInt aCacheSize=1)
 Create a Standard storage manager with the given name. More...
 
 SSMBase (const String &aDataManName, const Record &spec)
 Create a Standard storage manager with the given name. More...
 
 ~SSMBase ()
 
virtual DataManagerclone () const
 Clone this object. More...
 
virtual String dataManagerType () const
 Get the type name of the data manager (i.e. More...
 
virtual String dataManagerName () const
 Get the name given to the storage manager (in the constructor). More...
 
virtual Record dataManagerSpec () const
 Record a record containing data manager specifications. More...
 
virtual Record getProperties () const
 Get data manager properties that can be modified. More...
 
virtual void setProperties (const Record &spec)
 Modify data manager properties. More...
 
uInt getVersion () const
 Get the version of the class. More...
 
void setCacheSize (uInt aCacheSize, Bool canExceedNrBuckets=True)
 Set the cache size (in buckets). More...
 
uInt getCacheSize () const
 Get the current cache size (in buckets). More...
 
void clearCache ()
 Clear the cache used by this storage manager. More...
 
virtual void showCacheStatistics (ostream &anOs) const
 Show the statistics of all caches used. More...
 
void showIndexStatistics (ostream &anOs) const
 Show statistics of all indices used. More...
 
void showBaseStatistics (ostream &anOs) const
 Show statistics of the Base offsets/index etc. More...
 
uInt getBucketSize () const
 Get the bucket size. More...
 
rownr_t getNRow () const
 Get the number of rows in this storage manager. More...
 
virtual Bool canAddRow () const
 The storage manager can add rows. More...
 
virtual Bool canRemoveRow () const
 The storage manager can delete rows. More...
 
virtual Bool canAddColumn () const
 The storage manager can add columns. More...
 
virtual Bool canRemoveColumn () const
 The storage manager can delete columns. More...
 
SSMColumngetColumn (uInt aColNr)
 Get access to the given column. More...
 
SSMIndexgetIndex (uInt anIdxNr)
 Get access to the given Index. More...
 
void setBucketDirty ()
 Make the current bucket in the cache dirty (i.e. More...
 
StManArrayFileopenArrayFile (ByteIO::OpenOption anOpt)
 Open (if needed) the file for indirect arrays with the given mode. More...
 
char * find (rownr_t aRowNr, uInt aColNr, rownr_t &aStartRow, rownr_t &anEndRow, const String &colName)
 Find the bucket containing the column and row and return the pointer to the beginning of the column data in that bucket. More...
 
uInt getNewBucket ()
 Add a new bucket and get its bucket number. More...
 
char * getBucket (uInt aBucketNr)
 Read the bucket (if needed) and return the pointer to it. More...
 
void removeBucket (uInt aBucketNr)
 Remove a bucket from the bucket cache. More...
 
uInt getRowsPerBucket (uInt aColumn) const
 Get rows per bucket for the given column. More...
 
SSMStringHandlergetStringHandler ()
 Return a pointer to the (one and only) StringHandler object. More...
 
- Public Member Functions inherited from casacore::DataManager
 DataManager ()
 Default constructor. More...
 
virtual ~DataManager ()
 
void dataManagerInfo (Record &info) const
 Add SEQNR and SPEC (the DataManagerSpec subrecord) to the info. More...
 
virtual Bool isStorageManager () const
 Is the data manager a storage manager? The default is yes. More...
 
virtual Bool canReallocateColumns () const
 Tell if the data manager wants to reallocate the data manager column objects. More...
 
virtual DataManagerColumnreallocateColumn (DataManagerColumn *column)
 Reallocate the column object if it is part of this data manager. More...
 
uInt sequenceNr () const
 Get the (unique) sequence nr of this data manager. More...
 
uInt ncolumn () const
 Get the nr of columns in this data manager (can be zero). More...
 
Bool asBigEndian () const
 Have the data to be stored in big or little endian canonical format? More...
 
const TSMOptiontsmOption () const
 Get the TSM option. More...
 
MultiFileBasemultiFile ()
 Get the MultiFile pointer (can be 0). More...
 
String keywordName (const String &keyword) const
 Compose a keyword name from the given keyword appended with the sequence number (e.g. More...
 
String fileName () const
 Compose a unique filename from the table name and sequence number. More...
 
ByteIO::OpenOption fileOption () const
 Get the AipsIO option of the underlying file. More...
 
virtual Bool isRegular () const
 Is this a regular storage manager? It is regular if it allows addition of rows and writing data in them. More...
 
Tabletable () const
 Get the table this object is associated with. More...
 
virtual Bool canRenameColumn () const
 Does the data manager allow to rename columns? (default yes) More...
 
virtual void setMaximumCacheSize (uInt nMiB)
 Set the maximum cache size (in bytes) to be used by a storage manager. More...
 
virtual void showCacheStatistics (std::ostream &) const
 Show the data manager's IO statistics. More...
 
DataManagerColumncreateScalarColumn (const String &columnName, int dataType, const String &dataTypeId)
 Create a column in the data manager on behalf of a table column. More...
 
DataManagerColumncreateDirArrColumn (const String &columnName, int dataType, const String &dataTypeId)
 Create a direct array column. More...
 
DataManagerColumncreateIndArrColumn (const String &columnName, int dataType, const String &dataTypeId)
 Create an indirect array column. More...
 
DataManagergetClone () const
 Has the object already been cloned? More...
 
void setClone (DataManager *clone) const
 Set the pointer to the clone. More...
 

Static Public Member Functions

static DataManagermakeObject (const String &aDataManType, const Record &spec)
 Make the object from the type name string. More...
 
static char * readCallBack (void *anOwner, const char *aBucketStorage)
 Callbacks for BucketCache access. More...
 
static void writeCallBack (void *anOwner, char *aBucketStorage, const char *aBucket)
 
static void deleteCallBack (void *, char *aBucket)
 
static char * initCallBack (void *anOwner)
 
- Static Public Member Functions inherited from casacore::DataManager
static void registerCtor (const String &type, DataManagerCtor func)
 Register a mapping of a data manager type to its static construction function. More...
 
static DataManagerCtor getCtor (const String &dataManagerType)
 Get the "constructor" of a data manager (thread-safe). More...
 
static Bool isRegistered (const String &dataManagerType)
 Test if a data manager is registered (thread-safe). More...
 
static DataManagerunknownDataManager (const String &dataManagerType, const Record &spec)
 Serve as default function for theirRegisterMap, which catches all unknown data manager types. More...
 

Private Member Functions

 SSMBase (const SSMBase &that)
 Copy constructor (only meant for clone function). More...
 
SSMBaseoperator= (const SSMBase &that)
 Assignment cannot be used. More...
 
void recreate ()
 (Re)create the index, file, and cache object. More...
 
virtual Bool hasMultiFileSupport () const
 The data manager supports use of MultiFile. More...
 
virtual Bool flush (AipsIO &, Bool doFsync)
 Flush and optionally fsync the data. More...
 
virtual void create64 (rownr_t aNrRows)
 Let the storage manager create files as needed for a new table. More...
 
virtual rownr_t open64 (rownr_t aRowNr, AipsIO &)
 Open the storage manager file for an existing table, read in the data, and let the SSMColumn objects read their data. More...
 
virtual rownr_t resync64 (rownr_t aRowNr)
 Resync the storage manager with the new file contents. More...
 
virtual void reopenRW ()
 Reopen the storage manager files for read/write. More...
 
virtual void deleteManager ()
 The data manager will be deleted (because all its columns are requested to be deleted). More...
 
void init ()
 Let the storage manager initialize itself (upon creation). More...
 
uInt setBucketSize ()
 Determine and set the bucket size. More...
 
uInt getNrIndices () const
 Get the number of indices in use. More...
 
virtual void addRow64 (rownr_t aNrRows)
 Add rows to the storage manager. More...
 
virtual void removeRow64 (rownr_t aRowNr)
 Delete a row from all columns. More...
 
virtual void addColumn (DataManagerColumn *)
 Do the final addition of a column. More...
 
virtual void removeColumn (DataManagerColumn *)
 Remove a column from the data file. More...
 
virtual DataManagerColumnmakeScalarColumn (const String &aName, int aDataType, const String &aDataTypeID)
 Create a column in the storage manager on behalf of a table column. More...
 
virtual DataManagerColumnmakeDirArrColumn (const String &aName, int aDataType, const String &aDataTypeID)
 Create a direct array column. More...
 
virtual DataManagerColumnmakeIndArrColumn (const String &aName, int aDataType, const String &aDataTypeID)
 Create an indirect array column. More...
 
BucketCachegetCache ()
 Get the cache object. More...
 
void makeCache ()
 Construct the cache object (if not constructed yet). More...
 
void readHeader ()
 Read the header. More...
 
void readIndexBuckets ()
 Read the index from its buckets. More...
 
void writeIndex ()
 Write the header and the indices. More...
 

Private Attributes

String itsDataManName
 Name of data manager. More...
 
StManArrayFileitsIosFile
 The file containing the indirect arrays. More...
 
rownr_t itsNrRows
 The number of rows in the columns. More...
 
Block< uIntitsColumnOffset
 Column offset. More...
 
Block< uIntitsColIndexMap
 Row Index ID containing all the columns in a bucket. More...
 
PtrBlock< SSMIndex * > itsPtrIndex
 Will contain all indices. More...
 
BucketCacheitsCache
 The cache with the SSM buckets. More...
 
BucketFileitsFile
 The file containing all data. More...
 
SSMStringHandleritsStringHandler
 String handler class. More...
 
uInt itsPersCacheSize
 The persistent cache size. More...
 
uInt itsCacheSize
 The actual cache size. More...
 
uInt itsNrBuckets
 The initial number of buckets in the cache. More...
 
uInt itsNrIdxBuckets
 Nr of buckets needed for index. More...
 
Int itsFirstIdxBucket
 Number of the first index bucket. More...
 
uInt itsIdxBucketOffset
 Offset of index in first bucket. More...
 
Int itsLastStringBucket
 Number of the first String Bucket. More...
 
uInt itsIndexLength
 length of index memoryblock More...
 
uInt itsFreeBucketsNr
 The nr of free buckets. More...
 
Int itsFirstFreeBucket
 The first free bucket. More...
 
uInt itsBucketSize
 The bucket size. More...
 
uInt itsBucketRows
 
PtrBlock< SSMColumn * > itsPtrColumn
 The assembly of all columns. More...
 
Bool isDataChanged
 Has the data changed since the last flush? More...
 

Additional Inherited Members

- Static Public Attributes inherited from casacore::DataManager
static rownr_t MAXROWNR32
 Define the highest row number that can be represented as signed 32-bit. More...
 
- Protected Member Functions inherited from casacore::DataManager
void decrementNcolumn ()
 Decrement number of columns (in case a column is deleted). More...
 
void setEndian (Bool bigEndian)
 Tell the data manager if big or little endian format is needed. More...
 
void setTsmOption (const TSMOption &tsmOption)
 Tell the data manager which TSM option to use. More...
 
void setMultiFile (MultiFileBase *mfile)
 Tell the data manager that MultiFile can be used. More...
 
void throwDataTypeOther (const String &columnName, int dataType) const
 Throw an exception in case data type is TpOther, because the storage managers (and maybe other data managers) do not support such columns. More...
 

Detailed Description

Base class of the Standard Storage Manager

Intended use:

Internal

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25
Test programs:
tStandardStMan

Prerequisite

Etymology

SSMBase is the base class of the Standard Storage Manager.

Synopsis

The global principles of this class are described in StandardStMan.

The Standard Storage Manager divides the data file in equally sized chunks called buckets. There are 3 types of buckets:

Bucket access is handled by class BucketCache. It also keeps a list of free buckets. A bucket is freed when it is not needed anymore (e.g. all data from it are deleted).

Data buckets form the main part of the SSM. The data can be viewed as a few streams of buckets, where each stream contains the data of a given number of columns. Each stream has an SSMIndex object describing the number of rows stored in each data bucket of the stream. The SSM starts with a single bucket stream (holding all columns), but when columns are added, new bucket streams might be created.

For example, we have an SSM with a bucket size of 100 bytes. There are 5 Int columns (A,B,C,D,E) each taking 4 bytes per row. Column A, B, C, and D are stored in bucket stream 1, while column E is stored in bucket stream 2. So in stream 1 each bucket can hold 6 rows, while in stream 2 each bucket can hold 25 rows. For a 100 row table it will result in 17+4 data buckets.

A few classes collaborate to make it work:

String buckets are used by class SSMStringHandler to store scalar strings and fixed and variable shaped arrays of strings. The bucketnr, offset, and length of such string (arrays) are stored in the data buckets.
Indirect arrays of other data types are also stored indirectly and their offset is stored in the data buckets. Such arrays are handled by class StIndArray which uses an extra file to store the arrays.

Index buckets are used by SSMBase to make the SSMIndex data persistent. It uses alternately 2 sets of index buckets. In that way there is always an index availanle in case the system crashes. If possible 2 halfs of a single bucket are used alternately, otherwise separate buckets are used.

Motivation

The public interface of SSMBase is quite large, because the other internal SSM classes need these functions. To have a class with a minimal interface for the normal user, class StandardStMan is derived from it.
StandardStMan needs an isA- instead of hasA-relation to be able to bind columns to it in class SetupNewTable.

To Do

Definition at line 158 of file SSMBase.h.

Constructor & Destructor Documentation

◆ SSMBase() [1/4]

casacore::SSMBase::SSMBase ( Int  aBucketSize = 0,
uInt  aCacheSize = 1 
)
explicit

Create a Standard storage manager with default name SSM.

◆ SSMBase() [2/4]

casacore::SSMBase::SSMBase ( const String aDataManName,
Int  aBucketSize = 0,
uInt  aCacheSize = 1 
)
explicit

Create a Standard storage manager with the given name.

◆ SSMBase() [3/4]

casacore::SSMBase::SSMBase ( const String aDataManName,
const Record spec 
)

Create a Standard storage manager with the given name.

The specifications are part of the record (as created by dataManagerSpec).

◆ ~SSMBase()

casacore::SSMBase::~SSMBase ( )

◆ SSMBase() [4/4]

casacore::SSMBase::SSMBase ( const SSMBase that)
private

Copy constructor (only meant for clone function).

Member Function Documentation

◆ addColumn()

virtual void casacore::SSMBase::addColumn ( DataManagerColumn )
privatevirtual

Do the final addition of a column.

Reimplemented from casacore::DataManager.

◆ addRow64()

virtual void casacore::SSMBase::addRow64 ( rownr_t  aNrRows)
privatevirtual

Add rows to the storage manager.

Per column it extends number of rows.

Reimplemented from casacore::DataManager.

◆ canAddColumn()

virtual Bool casacore::SSMBase::canAddColumn ( ) const
virtual

The storage manager can add columns.

Reimplemented from casacore::DataManager.

◆ canAddRow()

virtual Bool casacore::SSMBase::canAddRow ( ) const
virtual

The storage manager can add rows.

Reimplemented from casacore::DataManager.

◆ canRemoveColumn()

virtual Bool casacore::SSMBase::canRemoveColumn ( ) const
virtual

The storage manager can delete columns.

Reimplemented from casacore::DataManager.

◆ canRemoveRow()

virtual Bool casacore::SSMBase::canRemoveRow ( ) const
virtual

The storage manager can delete rows.

Reimplemented from casacore::DataManager.

◆ clearCache()

void casacore::SSMBase::clearCache ( )

Clear the cache used by this storage manager.

It will flush the cache as needed and remove all buckets from it.

◆ clone()

virtual DataManager* casacore::SSMBase::clone ( ) const
virtual

Clone this object.

It does not clone SSMColumn objects possibly used. The caller has to delete the newly created object.

Implements casacore::DataManager.

◆ create64()

virtual void casacore::SSMBase::create64 ( rownr_t  aNrRows)
privatevirtual

Let the storage manager create files as needed for a new table.

This allows a column with an indirect array to create its file.

Reimplemented from casacore::DataManager.

◆ dataManagerName()

virtual String casacore::SSMBase::dataManagerName ( ) const
virtual

Get the name given to the storage manager (in the constructor).

Reimplemented from casacore::DataManager.

◆ dataManagerSpec()

virtual Record casacore::SSMBase::dataManagerSpec ( ) const
virtual

Record a record containing data manager specifications.

Reimplemented from casacore::DataManager.

◆ dataManagerType()

virtual String casacore::SSMBase::dataManagerType ( ) const
virtual

Get the type name of the data manager (i.e.

StandardStMan).

Implements casacore::DataManager.

◆ deleteCallBack()

static void casacore::SSMBase::deleteCallBack ( void *  ,
char *  aBucket 
)
static

◆ deleteManager()

virtual void casacore::SSMBase::deleteManager ( )
privatevirtual

The data manager will be deleted (because all its columns are requested to be deleted).

So clean up the things needed (e.g. delete files).

Implements casacore::DataManager.

◆ find()

char* casacore::SSMBase::find ( rownr_t  aRowNr,
uInt  aColNr,
rownr_t aStartRow,
rownr_t anEndRow,
const String colName 
)

Find the bucket containing the column and row and return the pointer to the beginning of the column data in that bucket.

It also fills in the start and end row for the column data.

◆ flush()

virtual Bool casacore::SSMBase::flush ( AipsIO ,
Bool  doFsync 
)
privatevirtual

Flush and optionally fsync the data.

It returns a True status if it had to flush (i.e. if data have changed).

Implements casacore::DataManager.

◆ getBucket()

char* casacore::SSMBase::getBucket ( uInt  aBucketNr)

Read the bucket (if needed) and return the pointer to it.

◆ getBucketSize()

uInt casacore::SSMBase::getBucketSize ( ) const
inline

Get the bucket size.

Definition at line 481 of file SSMBase.h.

References itsBucketSize.

◆ getCache()

BucketCache & casacore::SSMBase::getCache ( )
inlineprivate

Get the cache object.

This will construct the cache object if not present yet. The cache object will be deleted by the destructor.

Definition at line 486 of file SSMBase.h.

References itsCache, and makeCache().

◆ getCacheSize()

uInt casacore::SSMBase::getCacheSize ( ) const
inline

Get the current cache size (in buckets).

Definition at line 471 of file SSMBase.h.

References itsCacheSize.

◆ getColumn()

SSMColumn & casacore::SSMBase::getColumn ( uInt  aColNr)
inline

Get access to the given column.

Definition at line 494 of file SSMBase.h.

References itsPtrColumn.

◆ getIndex()

SSMIndex & casacore::SSMBase::getIndex ( uInt  anIdxNr)
inline

Get access to the given Index.

Definition at line 499 of file SSMBase.h.

References itsPtrIndex.

◆ getNewBucket()

uInt casacore::SSMBase::getNewBucket ( )

Add a new bucket and get its bucket number.

◆ getNrIndices()

uInt casacore::SSMBase::getNrIndices ( ) const
inlineprivate

Get the number of indices in use.

Definition at line 466 of file SSMBase.h.

References itsPtrIndex.

◆ getNRow()

rownr_t casacore::SSMBase::getNRow ( ) const
inline

Get the number of rows in this storage manager.

Definition at line 476 of file SSMBase.h.

References itsNrRows.

◆ getProperties()

virtual Record casacore::SSMBase::getProperties ( ) const
virtual

Get data manager properties that can be modified.

It is only ActualCacheSize (the actual cache size in buckets). It is a subset of the data manager specification.

Reimplemented from casacore::DataManager.

◆ getRowsPerBucket()

uInt casacore::SSMBase::getRowsPerBucket ( uInt  aColumn) const

Get rows per bucket for the given column.

Referenced by casacore::SSMColumn::getDataPtr().

◆ getStringHandler()

SSMStringHandler * casacore::SSMBase::getStringHandler ( )
inline

Return a pointer to the (one and only) StringHandler object.

Definition at line 504 of file SSMBase.h.

References itsStringHandler.

◆ getVersion()

uInt casacore::SSMBase::getVersion ( ) const

Get the version of the class.

◆ hasMultiFileSupport()

virtual Bool casacore::SSMBase::hasMultiFileSupport ( ) const
privatevirtual

The data manager supports use of MultiFile.

Reimplemented from casacore::DataManager.

◆ init()

void casacore::SSMBase::init ( )
private

Let the storage manager initialize itself (upon creation).

It determines the bucket size and fills the index.

◆ initCallBack()

static char* casacore::SSMBase::initCallBack ( void *  anOwner)
static

◆ makeCache()

void casacore::SSMBase::makeCache ( )
private

Construct the cache object (if not constructed yet).

Referenced by getCache().

◆ makeDirArrColumn()

virtual DataManagerColumn* casacore::SSMBase::makeDirArrColumn ( const String aName,
int  aDataType,
const String aDataTypeID 
)
privatevirtual

Create a direct array column.

Implements casacore::DataManager.

◆ makeIndArrColumn()

virtual DataManagerColumn* casacore::SSMBase::makeIndArrColumn ( const String aName,
int  aDataType,
const String aDataTypeID 
)
privatevirtual

Create an indirect array column.

Implements casacore::DataManager.

◆ makeObject()

static DataManager* casacore::SSMBase::makeObject ( const String aDataManType,
const Record spec 
)
static

Make the object from the type name string.

This function gets registered in the DataManager "constructor" map. The caller has to delete the object.

◆ makeScalarColumn()

virtual DataManagerColumn* casacore::SSMBase::makeScalarColumn ( const String aName,
int  aDataType,
const String aDataTypeID 
)
privatevirtual

Create a column in the storage manager on behalf of a table column.

The caller has to delete the newly created object.

Create a scalar column.

Implements casacore::DataManager.

◆ open64()

virtual rownr_t casacore::SSMBase::open64 ( rownr_t  aRowNr,
AipsIO  
)
privatevirtual

Open the storage manager file for an existing table, read in the data, and let the SSMColumn objects read their data.

Reimplemented from casacore::DataManager.

◆ openArrayFile()

StManArrayFile* casacore::SSMBase::openArrayFile ( ByteIO::OpenOption  anOpt)

Open (if needed) the file for indirect arrays with the given mode.

Return a pointer to the object.

◆ operator=()

SSMBase& casacore::SSMBase::operator= ( const SSMBase that)
private

Assignment cannot be used.

◆ readCallBack()

static char* casacore::SSMBase::readCallBack ( void *  anOwner,
const char *  aBucketStorage 
)
static

Callbacks for BucketCache access.

◆ readHeader()

void casacore::SSMBase::readHeader ( )
private

Read the header.

◆ readIndexBuckets()

void casacore::SSMBase::readIndexBuckets ( )
private

Read the index from its buckets.

◆ recreate()

void casacore::SSMBase::recreate ( )
private

(Re)create the index, file, and cache object.

It is used when all rows are deleted from the table.

◆ removeBucket()

void casacore::SSMBase::removeBucket ( uInt  aBucketNr)

Remove a bucket from the bucket cache.

◆ removeColumn()

virtual void casacore::SSMBase::removeColumn ( DataManagerColumn )
privatevirtual

Remove a column from the data file.

Reimplemented from casacore::DataManager.

◆ removeRow64()

virtual void casacore::SSMBase::removeRow64 ( rownr_t  aRowNr)
privatevirtual

Delete a row from all columns.

Reimplemented from casacore::DataManager.

◆ reopenRW()

virtual void casacore::SSMBase::reopenRW ( )
privatevirtual

Reopen the storage manager files for read/write.

Reimplemented from casacore::DataManager.

◆ resync64()

virtual rownr_t casacore::SSMBase::resync64 ( rownr_t  aRowNr)
privatevirtual

Resync the storage manager with the new file contents.

This is done by clearing the cache.

Reimplemented from casacore::DataManager.

◆ setBucketDirty()

void casacore::SSMBase::setBucketDirty ( )

Make the current bucket in the cache dirty (i.e.

something has been changed in it and it needs to be written when removed from the cache). (used by SSMColumn::putValue).

◆ setBucketSize()

uInt casacore::SSMBase::setBucketSize ( )
private

Determine and set the bucket size.

It returns the number of rows per bucket.

◆ setCacheSize()

void casacore::SSMBase::setCacheSize ( uInt  aCacheSize,
Bool  canExceedNrBuckets = True 
)

Set the cache size (in buckets).

If canExceedNrBuckets=True, the given cache size can be larger than the nr of buckets in the file. In this way the cache can be made large enough for a future file extension. Otherwise, it is limited to the actual number of buckets. This is useful if one wants the entire file to be cached.

◆ setProperties()

virtual void casacore::SSMBase::setProperties ( const Record spec)
virtual

Modify data manager properties.

Only MaxCacheSize can be used. It is similar to function setCacheSize with canExceedNrBuckets=False.

Reimplemented from casacore::DataManager.

◆ showBaseStatistics()

void casacore::SSMBase::showBaseStatistics ( ostream &  anOs) const

Show statistics of the Base offsets/index etc.

◆ showCacheStatistics()

virtual void casacore::SSMBase::showCacheStatistics ( ostream &  anOs) const
virtual

Show the statistics of all caches used.

◆ showIndexStatistics()

void casacore::SSMBase::showIndexStatistics ( ostream &  anOs) const

Show statistics of all indices used.

◆ writeCallBack()

static void casacore::SSMBase::writeCallBack ( void *  anOwner,
char *  aBucketStorage,
const char *  aBucket 
)
static

◆ writeIndex()

void casacore::SSMBase::writeIndex ( )
private

Write the header and the indices.

Member Data Documentation

◆ isDataChanged

Bool casacore::SSMBase::isDataChanged
private

Has the data changed since the last flush?

Definition at line 462 of file SSMBase.h.

◆ itsBucketRows

uInt casacore::SSMBase::itsBucketRows
private

Definition at line 456 of file SSMBase.h.

◆ itsBucketSize

uInt casacore::SSMBase::itsBucketSize
private

The bucket size.

Definition at line 455 of file SSMBase.h.

Referenced by getBucketSize().

◆ itsCache

BucketCache* casacore::SSMBase::itsCache
private

The cache with the SSM buckets.

Definition at line 415 of file SSMBase.h.

Referenced by getCache().

◆ itsCacheSize

uInt casacore::SSMBase::itsCacheSize
private

The actual cache size.

Definition at line 427 of file SSMBase.h.

Referenced by getCacheSize().

◆ itsColIndexMap

Block<uInt> casacore::SSMBase::itsColIndexMap
private

Row Index ID containing all the columns in a bucket.

Definition at line 409 of file SSMBase.h.

◆ itsColumnOffset

Block<uInt> casacore::SSMBase::itsColumnOffset
private

Column offset.

Definition at line 406 of file SSMBase.h.

◆ itsDataManName

String casacore::SSMBase::itsDataManName
private

Name of data manager.

Definition at line 397 of file SSMBase.h.

◆ itsFile

BucketFile* casacore::SSMBase::itsFile
private

The file containing all data.

Definition at line 418 of file SSMBase.h.

◆ itsFirstFreeBucket

Int casacore::SSMBase::itsFirstFreeBucket
private

The first free bucket.

Definition at line 452 of file SSMBase.h.

◆ itsFirstIdxBucket

Int casacore::SSMBase::itsFirstIdxBucket
private

Number of the first index bucket.

Definition at line 436 of file SSMBase.h.

◆ itsFreeBucketsNr

uInt casacore::SSMBase::itsFreeBucketsNr
private

The nr of free buckets.

Definition at line 449 of file SSMBase.h.

◆ itsIdxBucketOffset

uInt casacore::SSMBase::itsIdxBucketOffset
private

Offset of index in first bucket.

If >0, the index fits in a single bucket.

Definition at line 440 of file SSMBase.h.

◆ itsIndexLength

uInt casacore::SSMBase::itsIndexLength
private

length of index memoryblock

Definition at line 446 of file SSMBase.h.

◆ itsIosFile

StManArrayFile* casacore::SSMBase::itsIosFile
private

The file containing the indirect arrays.

Definition at line 400 of file SSMBase.h.

◆ itsLastStringBucket

Int casacore::SSMBase::itsLastStringBucket
private

Number of the first String Bucket.

Definition at line 443 of file SSMBase.h.

◆ itsNrBuckets

uInt casacore::SSMBase::itsNrBuckets
private

The initial number of buckets in the cache.

Definition at line 430 of file SSMBase.h.

◆ itsNrIdxBuckets

uInt casacore::SSMBase::itsNrIdxBuckets
private

Nr of buckets needed for index.

Definition at line 433 of file SSMBase.h.

◆ itsNrRows

rownr_t casacore::SSMBase::itsNrRows
private

The number of rows in the columns.

Definition at line 403 of file SSMBase.h.

Referenced by getNRow().

◆ itsPersCacheSize

uInt casacore::SSMBase::itsPersCacheSize
private

The persistent cache size.

Definition at line 424 of file SSMBase.h.

◆ itsPtrColumn

PtrBlock<SSMColumn*> casacore::SSMBase::itsPtrColumn
private

The assembly of all columns.

Definition at line 459 of file SSMBase.h.

Referenced by getColumn().

◆ itsPtrIndex

PtrBlock<SSMIndex*> casacore::SSMBase::itsPtrIndex
private

Will contain all indices.

Definition at line 412 of file SSMBase.h.

Referenced by getIndex(), and getNrIndices().

◆ itsStringHandler

SSMStringHandler* casacore::SSMBase::itsStringHandler
private

String handler class.

Definition at line 421 of file SSMBase.h.

Referenced by getStringHandler().


The documentation for this class was generated from the following file: