IDataFile Class Reference

Represents an MXAData File object and the various operations that can be performed on that file. More...

Inherited by H5MXADataFile.

Inheritance diagram for IDataFile:

Inheritance graph
[legend]
List of all members.

Public Types

typedef boost::shared_ptr<
IDataModel
DataModelType
typedef boost::shared_ptr<
IDataset
DatasetType

Public Member Functions

 MXA_SHARED_POINTERS (IDataFile)
 IDataFile (const std::string &filename)
virtual ~IDataFile ()
virtual std::string getFilename ()=0
 returns the name of the file that is actively being read from or written to.
virtual DataModelType getDataModel ()=0
 returns the DataModel as read from the data file
virtual int32 createFile ()=0
 Creates a new data file, first deleting and existing file with the same name.
virtual int32 openFile (bool readOnly)=0
 Opens an existing data file.
virtual int32 closeFile (bool saveModel)=0
 Closes the data file. Any further access to the file will fail.
virtual float supportedMXAFileVersion ()=0
 Checks if the file version of the data file is with in the bounds of the library to read/parse the data model.
virtual bool isFileOpen ()=0
 Returns if the file is currently in the "open" state. If this file is OPEN then file operations (Read/Write data or model) can be performed on the file.
virtual bool isReadOnly ()=0
 Was the file opened in ReadOnly mode.
virtual int32 getFileId ()=0
 Returns the unique identifier for the open file.
virtual int32 saveDataModel ()=0
 Writes the Data Model into the underlying data file overwriting any existing model. This may have adverse effects on the ability to retrieve data from the data file if the data model differs in structure from the original data model.
virtual int32 writeData (const DatasetType dataset)=0
virtual int32 readData (const DatasetType dataset)=0

Private Member Functions

 IDataFile (const IDataFile &)
void operator= (const IDataFile &)

Detailed Description

Represents an MXAData File object and the various operations that can be performed on that file.

Author:
mjackson
Date:
Dec 14, 2007
Version:
Revision
1.2


Member Typedef Documentation

typedef boost::shared_ptr<IDataModel> IDataFile::DataModelType

typedef boost::shared_ptr<IDataset> IDataFile::DatasetType


Constructor & Destructor Documentation

IDataFile::IDataFile ( const std::string &  filename  )  [inline, explicit]

virtual IDataFile::~IDataFile (  )  [inline, virtual]

IDataFile::IDataFile ( const IDataFile  )  [private]


Member Function Documentation

IDataFile::MXA_SHARED_POINTERS ( IDataFile   ) 

virtual std::string IDataFile::getFilename (  )  [pure virtual]

returns the name of the file that is actively being read from or written to.

Implemented in H5MXADataFile.

virtual DataModelType IDataFile::getDataModel (  )  [pure virtual]

returns the DataModel as read from the data file

Returns:
A DataModelPtr oject. A NULL wrapped pointer is perfectly valid

Implemented in H5MXADataFile.

virtual int32 IDataFile::createFile (  )  [pure virtual]

Creates a new data file, first deleting and existing file with the same name.

Returns:
Error code < 0 is error. 0 or positive is Success

Implemented in H5MXADataFile.

virtual int32 IDataFile::openFile ( bool  readOnly  )  [pure virtual]

Opens an existing data file.

Parameters:
readOnly Open the file in Read-Only Mode
Returns:
Error code < 0 is error. 0 or positive is Success

Implemented in H5MXADataFile.

virtual int32 IDataFile::closeFile ( bool  saveModel  )  [pure virtual]

Closes the data file. Any further access to the file will fail.

Returns:
Error code < 0 is error. 0 or positive is Success

Implemented in H5MXADataFile.

virtual float IDataFile::supportedMXAFileVersion (  )  [pure virtual]

Checks if the file version of the data file is with in the bounds of the library to read/parse the data model.

Implemented in H5MXADataFile.

virtual bool IDataFile::isFileOpen (  )  [pure virtual]

Returns if the file is currently in the "open" state. If this file is OPEN then file operations (Read/Write data or model) can be performed on the file.

Implemented in H5MXADataFile.

virtual bool IDataFile::isReadOnly (  )  [pure virtual]

Was the file opened in ReadOnly mode.

Implemented in H5MXADataFile.

virtual int32 IDataFile::getFileId (  )  [pure virtual]

Returns the unique identifier for the open file.

Returns:

Implemented in H5MXADataFile.

virtual int32 IDataFile::saveDataModel (  )  [pure virtual]

Writes the Data Model into the underlying data file overwriting any existing model. This may have adverse effects on the ability to retrieve data from the data file if the data model differs in structure from the original data model.

Returns:
Error code < 0 is error. 0 or positive is Success

Implemented in H5MXADataFile.

virtual int32 IDataFile::writeData ( const DatasetType  dataset  )  [pure virtual]

virtual int32 IDataFile::readData ( const DatasetType  dataset  )  [pure virtual]

void IDataFile::operator= ( const IDataFile  )  [private]


The documentation for this class was generated from the following file:
Generated on Tue Nov 17 18:43:13 2009 for MXADataModel by  doxygen 1.5.2