Inherited by XMLIODelegate.
Inheritance diagram for IFileIODelegate:
Public Member Functions | |
MXA_SHARED_POINTERS (IFileIODelegate) | |
MXA_TYPE_MACRO (IFileIODelegate) | |
virtual | ~IFileIODelegate () |
virtual int32 | writeModelToFile (const std::string &fileName, IDataModel::Pointer model, bool closeWhenFinished, bool deleteExisting)=0 |
Writes the Model to a data file. If the file does NOT exist, a new file will be created. If the data file does exist and does NOT have a model in the file, then the model will be written. If the data file DOES exist and DOES have an existing model then the model information from the passed in model will overwrite the model in the file. | |
virtual int32 | readModelFromFile (const std::string &fileName, IDataModel::Pointer model, bool closeWhenFinished, bool openReadOnly)=0 |
Deserializes a Datamodel from a file on disk. | |
virtual bool | supportedMXAFileVersion (float version)=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 | isMXAFile (const std::string &fileName)=0 |
Is the file describe by an absolute path an MXA based data file. | |
virtual int32 | openMXAFile (std::string filename, bool readOnly=false)=0 |
Opens an existing MXA Data File. IE an HDF5 file with the proper data model encoded. | |
virtual void | closeMXAFile ()=0 |
Closes the currently open file. | |
virtual int32 | getOpenFileId ()=0 |
Returns the HDF file id of the currently open file. | |
virtual std::string | getOpenFileName ()=0 |
Returns the currently open filename as an absolute path. | |
Protected Member Functions | |
IFileIODelegate () | |
Private Member Functions | |
IFileIODelegate (const IFileIODelegate &) | |
void | operator= (const IFileIODelegate &) |
virtual IFileIODelegate::~IFileIODelegate | ( | ) | [inline, virtual] |
IFileIODelegate::IFileIODelegate | ( | ) | [inline, protected] |
IFileIODelegate::IFileIODelegate | ( | const IFileIODelegate & | ) | [private] |
IFileIODelegate::MXA_SHARED_POINTERS | ( | IFileIODelegate | ) |
IFileIODelegate::MXA_TYPE_MACRO | ( | IFileIODelegate | ) |
virtual int32 IFileIODelegate::writeModelToFile | ( | const std::string & | fileName, | |
IDataModel::Pointer | model, | |||
bool | closeWhenFinished, | |||
bool | deleteExisting | |||
) | [pure virtual] |
Writes the Model to a data file. If the file does NOT exist, a new file will be created. If the data file does exist and does NOT have a model in the file, then the model will be written. If the data file DOES exist and DOES have an existing model then the model information from the passed in model will overwrite the model in the file.
fileName | The name of the file (and path if needed) to write the model to | |
model | The Model to serialize | |
closeWhenFinished | Close the file when this operation is complete | |
deleteExisting | Delete existing file of the same name and create a new file |
Implemented in XMLIODelegate.
virtual int32 IFileIODelegate::readModelFromFile | ( | const std::string & | fileName, | |
IDataModel::Pointer | model, | |||
bool | closeWhenFinished, | |||
bool | openReadOnly | |||
) | [pure virtual] |
Deserializes a Datamodel from a file on disk.
fileName | The name of the file (including path) to deserialize from | |
model | The model to read the information into | |
closeWhenFinished | Close the file when this operation is complete | |
openReadOnly | Opens the file in a read only mode. Nothing can be written to the file |
Implemented in XMLIODelegate.
virtual bool IFileIODelegate::supportedMXAFileVersion | ( | float | version | ) | [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.
version | The version to check. |
Implemented in XMLIODelegate.
virtual bool IFileIODelegate::isMXAFile | ( | const std::string & | fileName | ) | [pure virtual] |
Is the file describe by an absolute path an MXA based data file.
fileName | The data file to check |
Implemented in XMLIODelegate.
virtual int32 IFileIODelegate::openMXAFile | ( | std::string | filename, | |
bool | readOnly = false | |||
) | [pure virtual] |
Opens an existing MXA Data File. IE an HDF5 file with the proper data model encoded.
filename | The absolute path of the file to open | |
readOnly | True if you want the file opened as read only. False if you need to write something to the file |
Implemented in XMLIODelegate.
virtual void IFileIODelegate::closeMXAFile | ( | ) | [pure virtual] |
virtual int32 IFileIODelegate::getOpenFileId | ( | ) | [pure virtual] |
virtual std::string IFileIODelegate::getOpenFileName | ( | ) | [pure virtual] |
void IFileIODelegate::operator= | ( | const IFileIODelegate & | ) | [private] |