#include <LightApp_Driver.h>

Public Types | |
| typedef std::vector< std::string > | ListOfFiles |
Public Member Functions | |
| LightApp_Driver () | |
| virtual | ~LightApp_Driver () |
| virtual bool | SaveDatasInFile (const char *theFileName, bool isMultiFile) |
| virtual bool | ReadDatasFromFile (const char *theFileName, bool isMultiFile) |
| virtual std::string | GetTmpDir (const char *theURL, const bool isMultiFile) |
| ListOfFiles | GetListOfFiles (const char *theModuleName) |
| virtual void | SetListOfFiles (const char *theModuleName, const ListOfFiles theListOfFiles) |
| virtual void | RemoveTemporaryFiles (const char *theModuleName, const bool IsDirDeleted) |
| void | RemoveFiles (const ListOfFiles &theFiles, const bool IsDirDeleted) |
| virtual void | ClearDriverContents () |
Protected Types | |
| typedef std::map< std::string, ListOfFiles > | MapOfListOfFiles |
Protected Member Functions | |
| void | PutFilesToStream (const std::string &theModuleName, unsigned char *&theBuffer, long &theBufferSize, bool theNamesOnly=false) |
| ListOfFiles | PutStreamToFiles (const unsigned char *theBuffer, const long theBufferSize, bool theNamesOnly=false) |
| std::string | GetTmpDir () |
| std::string | GetDirFromPath (const std::string &thePath) |
| void | SetIsTemporary (bool theFlag) |
| bool | IsTemporary () const |
Protected Attributes | |
| MapOfListOfFiles | myMap |
| std::string | myTmpDir |
Private Attributes | |
| bool | myIsTemp |
Description : Driver can save to file and read from file list of files for light modules
| typedef std::vector<std::string> LightApp_Driver.ListOfFiles |
typedef std::map<std::string, ListOfFiles> LightApp_Driver.MapOfListOfFiles [protected] |
| LightApp_Driver::LightApp_Driver | ( | ) |
Constructor.
| LightApp_Driver::~LightApp_Driver | ( | ) | [virtual] |
Destructor.
| bool LightApp_Driver::SaveDatasInFile | ( | const char * | theFileName, |
| bool | isMultiFile | ||
| ) | [virtual] |
Save in file 'theFileName' datas from this driver
Reimplemented in LightApp_HDFDriver.
References test_big_table.aName.
| bool LightApp_Driver::ReadDatasFromFile | ( | const char * | theFileName, |
| bool | isMultiFile | ||
| ) | [virtual] |
Filling current driver from file 'theFileName'
Reimplemented in LightApp_HDFDriver.
| std::string LightApp_Driver::GetTmpDir | ( | const char * | theURL, |
| const bool | isMultiFile | ||
| ) | [virtual] |
| LightApp_Driver::ListOfFiles LightApp_Driver::GetListOfFiles | ( | const char * | theModuleName | ) |
References test_big_table.aName.
| void LightApp_Driver::SetListOfFiles | ( | const char * | theModuleName, |
| const ListOfFiles | theListOfFiles | ||
| ) | [virtual] |
Sets list of files for module with name 'theModuleName'
References test_big_table.aName.
| void LightApp_Driver::RemoveTemporaryFiles | ( | const char * | theModuleName, |
| const bool | IsDirDeleted | ||
| ) | [virtual] |
Removes files which was created from module theModuleName if <IsDirDeleted> is true tmp directory is also deleted if it is empty
| void LightApp_Driver::RemoveFiles | ( | const ListOfFiles & | theFiles, |
| const bool | IsDirDeleted | ||
| ) |
Remove files. First item in <theFiles> is a directory with slash at the end. Other items are names of files. If <IsDirDeleted> is true, then the directory is also deleted.
References TCollection_AsciiString.
| void LightApp_Driver::ClearDriverContents | ( | ) | [virtual] |
Clears map of list files
| void LightApp_Driver::PutFilesToStream | ( | const std::string & | theModuleName, |
| unsigned char *& | theBuffer, | ||
| long & | theBufferSize, | ||
| bool | theNamesOnly = false |
||
| ) | [protected] |
Converts files which was created from module <theModuleName> into a byte sequence unsigned char
References test_big_table.aName, and TCollection_AsciiString.
| LightApp_Driver::ListOfFiles LightApp_Driver::PutStreamToFiles | ( | const unsigned char * | theBuffer, |
| const long | theBufferSize, | ||
| bool | theNamesOnly = false |
||
| ) | [protected] |
Converts a byte sequence <theBuffer> to files and return list of them
References TCollection_AsciiString.
| std::string LightApp_Driver::GetTmpDir | ( | ) | [protected] |
References TCollection_AsciiString.
| std::string LightApp_Driver::GetDirFromPath | ( | const std::string & | thePath | ) | [protected] |
References TCollection_AsciiString.
| void LightApp_Driver.SetIsTemporary | ( | bool | theFlag | ) | [protected] |
| bool LightApp_Driver.IsTemporary | ( | ) | const [protected] |
MapOfListOfFiles LightApp_Driver.myMap [protected] |
std::string LightApp_Driver.myTmpDir [protected] |
bool LightApp_Driver.myIsTemp [private] |