VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | Friends
makVrv::DtDeSettings Class Reference

Settings class for reading and writing settings to/from files. More...

Inheritance diagram for makVrv::DtDeSettings:
Inheritance graph
[legend]

Public Member Functions

virtual ~DtDeSettings ()
 DTOR.
const std::string & name () const
 Get the settings name.
const std::string & extension () const
 Get the extension for this settings type.
template<typename RecordType >
bool readDefaultRecord (RecordType &r)
 Read a record from the default settings.
template<typename RecordType >
bool readBackupRecord (RecordType &r)
 Read a record from the default settings.
template<typename RecordType >
bool readFactoryDefaultRecord (RecordType &r)
template<typename RecordType >
bool writeDefaultRecord (const RecordType &r)
 Write a record as the default settings.
template<typename RecordType >
bool writeBackupRecord (const RecordType &r)
 Write a record as the default settings.
template<typename RecordType >
bool readRecordFrom (RecordType &r, const std::string &importFileName)
 Read a record from a specific location.
template<typename RecordType >
bool readRecordFromBinary (RecordType &r, const std::string &importFileName)
 Read a record from a specific location.
template<typename RecordType >
bool writeRecordTo (const RecordType &r, const std::string &exportFileName) const
 Write a record to a specific location.
template<typename RecordType >
bool writeRecordToBinary (const RecordType &r, const std::string &exportFileName) const
 Write a record to a specific location.
void setAutoSave (bool b)
bool autoSave () const
Default settings file existence & path accessors.
bool defaultFileExists () const
virtual std::string defaultFilePath () const
bool defaultBinaryFileExists () const
virtual std::string defaultBinaryFilePath () const
Factory settings file existence & path accessors.
bool factoryFileExists () const
virtual std::string factoryFilePath () const
Backup settings file existence & path accessors.
bool backupFileExists () const
virtual std::string backupFilePath () const

Static Public Member Functions

static std::string binaryFileExtension (void)

Protected Member Functions

 DtDeSettings (DtDe &de, const std::string &name, const std::string &ext)

Protected Attributes

DtDemyDe
std::string myName
std::string myExtension
bool myAutoSave

Static Protected Attributes

static const std::string myBinaryFileExtension

Friends

class DtDeSettingsManager

Detailed Description

Settings class for reading and writing settings to/from files.

Constructor & Destructor Documentation

virtual makVrv::DtDeSettings::~DtDeSettings ( )
virtual

DTOR.

makVrv::DtDeSettings::DtDeSettings ( DtDe de,
const std::string &  name,
const std::string &  ext 
)
protected

Member Function Documentation

const std::string& makVrv::DtDeSettings::name ( ) const

Get the settings name.

const std::string& makVrv::DtDeSettings::extension ( ) const

Get the extension for this settings type.

template<typename RecordType >
bool makVrv::DtDeSettings::readDefaultRecord ( RecordType &  r)
template<typename RecordType >
bool makVrv::DtDeSettings::readBackupRecord ( RecordType &  r)

Read a record from the default settings.

template<typename RecordType >
bool makVrv::DtDeSettings::readFactoryDefaultRecord ( RecordType &  r)
template<typename RecordType >
bool makVrv::DtDeSettings::writeDefaultRecord ( const RecordType &  r)
template<typename RecordType >
bool makVrv::DtDeSettings::writeBackupRecord ( const RecordType &  r)

Write a record as the default settings.

template<typename RecordType >
bool makVrv::DtDeSettings::readRecordFrom ( RecordType &  r,
const std::string &  importFileName 
)

Read a record from a specific location.

template<typename RecordType >
bool makVrv::DtDeSettings::readRecordFromBinary ( RecordType &  r,
const std::string &  importFileName 
)

Read a record from a specific location.

template<typename RecordType >
bool makVrv::DtDeSettings::writeRecordTo ( const RecordType &  r,
const std::string &  exportFileName 
) const
template<typename RecordType >
bool makVrv::DtDeSettings::writeRecordToBinary ( const RecordType &  r,
const std::string &  exportFileName 
) const

Write a record to a specific location.

void makVrv::DtDeSettings::setAutoSave ( bool  b)
inline
bool makVrv::DtDeSettings::autoSave ( ) const
inline
bool makVrv::DtDeSettings::defaultFileExists ( ) const
virtual std::string makVrv::DtDeSettings::defaultFilePath ( ) const
virtual
bool makVrv::DtDeSettings::defaultBinaryFileExists ( ) const
virtual std::string makVrv::DtDeSettings::defaultBinaryFilePath ( ) const
virtual
bool makVrv::DtDeSettings::factoryFileExists ( ) const
virtual std::string makVrv::DtDeSettings::factoryFilePath ( ) const
virtual
bool makVrv::DtDeSettings::backupFileExists ( ) const
virtual std::string makVrv::DtDeSettings::backupFilePath ( ) const
virtual
static std::string makVrv::DtDeSettings::binaryFileExtension ( void  )
static

Friends And Related Function Documentation

friend class DtDeSettingsManager
friend

Member Data Documentation

DtDe& makVrv::DtDeSettings::myDe
protected
std::string makVrv::DtDeSettings::myName
protected
std::string makVrv::DtDeSettings::myExtension
protected
bool makVrv::DtDeSettings::myAutoSave
protected
const std::string makVrv::DtDeSettings::myBinaryFileExtension
staticprotected

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

Document ID: Generated on Tue Mar 8 22:13:38 EST 2016 from SVN revision 162938
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)