SaX::SaXStorage Class Reference

SaX2 - Storage class. More...

#include <storage.h>

Inheritance diagram for SaX::SaXStorage:

Inheritance graph
[legend]
List of all members.

Public Member Functions

void setItem (const QString &, const QString &)
void addItem (const QString &, const QString &)
void removeItem (const QString &, const QString &)
void removeEntry (const QString &)
void setDenomination (const QString &, const QString &, const QString &)
void setRawItem (const QString &, const QString &, const QString &)
void addRawItem (const QString &, const QString &, const QString &)
void removeRawItem (const QString &, const QString &)
QString getItem (const QString &)
bool setID (int)
bool addID (int)
bool delID (int)
int getCurrentID (void)
QDict< QString > getTable (int)
QDict< QString > getCurrentTable (void)
QDict< QString > * getTablePointer (int)
QDict< QString > * getCurrentTablePointer (void)
void merge (QList< QDict< QString > >)
int getCount (bool=false)
void addGroup (const QString &, const QString &, const QString &)
QDict< QDict< QString > > getTablePointerCDB (void)
QList< QDict< QString > > getTablePointerCDB_DATA (const QString &)
QList< QDict< QString > > getTablePointerDATA (void)
QDict< QString > operator[] (int id)
QString operator[] (const QString &key)
 SaXStorage (void)

Protected Attributes

QList< QDict< QString > > mData
QDict< QDict< QString > > mCDB
int mCurrentID

Detailed Description

SaX2 - Storage class.

The SaXStorage class provides all the structures and member functions to store, delete/retrieve and change configuration related information. The internal data structure is based on a list of hashes or a an hash of hashes. The standard data is stored in a dictionary list whereas the special CDB data is stored in a dictionary of dictionaries

 #include <sax/sax.h>

 SaXStorage container;
 container.setItem ("Identifier","Monitor[0]");
 container.setDenomination ("01","Belinea","102030");
 container.setRawItem ("RawOption","opt1","val1");
 container.addRawItem ("RawOption","opt2","val2");
 container.removeRawItem ("RawOption","opt1");

 //QDict<QString> section = container.getCurrentTable();
 QDict<QString> section = container[0];

 QString* data = section.take ("RawOption");
 printf ("%s\n",data->ascii());

 printf ("%s\n",container["RawOption"].ascii());

Definition at line 129 of file storage.h.


Constructor & Destructor Documentation

SaX::SaXStorage::SaXStorage ( void   ) 

Definition at line 27 of file storage.cpp.

References mCurrentID, and mData.


Member Function Documentation

void SaX::SaXStorage::setItem ( const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 40 of file storage.cpp.

References mCurrentID, and mData.

Referenced by addItem(), addRawItem(), merge(), removeItem(), removeRawItem(), SaX::SaXManipulateCard::setCardOption(), setDenomination(), SaX::SaXManipulatePointers::setOption(), and setRawItem().

void SaX::SaXStorage::addItem ( const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 52 of file storage.cpp.

References mCurrentID, mData, and setItem().

Referenced by SaX::SaXManipulateCard::addCardOption(), and SaX::SaXManipulatePointers::addOption().

Here is the call graph for this function:

void SaX::SaXStorage::removeItem ( const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 72 of file storage.cpp.

References mCurrentID, mData, and setItem().

Referenced by SaX::SaXManipulateCard::removeCardOption(), and SaX::SaXManipulatePointers::removeOption().

Here is the call graph for this function:

void SaX::SaXStorage::removeEntry ( const QString &   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 98 of file storage.cpp.

References mCurrentID, and mData.

void SaX::SaXStorage::setDenomination ( const QString &  ,
const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 123 of file storage.cpp.

References setItem().

Here is the call graph for this function:

void SaX::SaXStorage::setRawItem ( const QString &  ,
const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 138 of file storage.cpp.

References setItem().

Referenced by addRawItem(), SaX::SaXManipulateCard::setCardOption(), and SaX::SaXManipulatePointers::setOption().

Here is the call graph for this function:

void SaX::SaXStorage::addRawItem ( const QString &  ,
const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 154 of file storage.cpp.

References mCurrentID, mData, setItem(), and setRawItem().

Referenced by SaX::SaXManipulateCard::addCardOption(), and SaX::SaXManipulatePointers::addOption().

Here is the call graph for this function:

void SaX::SaXStorage::removeRawItem ( const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 178 of file storage.cpp.

References mCurrentID, mData, and setItem().

Referenced by SaX::SaXManipulateCard::removeCardOption(), and SaX::SaXManipulatePointers::removeOption().

Here is the call graph for this function:

QString SaX::SaXStorage::getItem ( const QString &   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 109 of file storage.cpp.

References mCurrentID, mData, and operator[]().

Referenced by SaX::SaXManipulateDesktop::disable3D(), SaX::SaXManipulateDesktop::enable3D(), SaX::SaXManipulateCard::getCardModel(), SaX::SaXManipulateCard::getCardName(), SaX::SaXManipulateCard::getCards(), SaX::SaXManipulateCard::getCardVendor(), SaX::SaXManipulateDesktop::getDualHeadProfile(), SaX::SaXManipulateCard::getHeads(), SaX::SaXManipulateDesktop::is3DCard(), SaX::SaXManipulateDesktop::isDualHeadCard(), operator[](), SaX::SaXManipulateCard::removeCardOption(), SaX::SaXManipulatePointers::removeOption(), and SaX::SaXManipulateTablets::removePen().

Here is the call graph for this function:

bool SaX::SaXStorage::setID ( int   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 351 of file storage.cpp.

References SaX::SaXException::errorString(), SaX::SaXException::excSetStorageIDFailed(), mCurrentID, and mData.

Referenced by merge(), SaX::SaXManipulateDevices::removeInputDevice(), and SaX::SaXManipulateDesktop::selectDesktop().

Here is the call graph for this function:

bool SaX::SaXStorage::addID ( int   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 244 of file storage.cpp.

References mCurrentID, and mData.

Referenced by SaX::SaXManipulateDevices::addDesktopDevice(), and merge().

bool SaX::SaXStorage::delID ( int   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 264 of file storage.cpp.

References mData.

Referenced by SaX::SaXManipulateDevices::removeDesktopDevice(), and SaX::SaXManipulateDevices::removeInputDevice().

int SaX::SaXStorage::getCurrentID ( void   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 369 of file storage.cpp.

References mCurrentID.

Referenced by SaX::SaXManipulateDevices::removeInputDevice().

QDict< QString > SaX::SaXStorage::getTable ( int   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 379 of file storage.cpp.

References mData.

Referenced by operator[]().

QDict< QString > SaX::SaXStorage::getCurrentTable ( void   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 393 of file storage.cpp.

References mCurrentID, and mData.

QDict< QString > * SaX::SaXStorage::getTablePointer ( int   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 403 of file storage.cpp.

References mData.

Referenced by SaX::SaXManipulateDevices::addInputDevice(), SaX::SaXExport::doExport(), and SaX::SaXManipulateDevices::removeInputDevice().

QDict< QString > * SaX::SaXStorage::getCurrentTablePointer ( void   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 413 of file storage.cpp.

References mCurrentID, and mData.

void SaX::SaXStorage::merge ( QList< QDict< QString > >   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 221 of file storage.cpp.

References addID(), setID(), and setItem().

Here is the call graph for this function:

int SaX::SaXStorage::getCount ( bool  = false  )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 423 of file storage.cpp.

References mData.

Referenced by SaX::SaXManipulateDevices::addDesktopDevice(), SaX::SaXManipulateDevices::addInputDevice(), SaX::SaXExport::doExport(), SaX::SaXManipulateCard::getDevices(), SaX::SaXManipulateLayout::getMultiheadMode(), SaX::SaXManipulateDevices::removeDesktopDevice(), and SaX::SaXManipulateDevices::removeInputDevice().

void SaX::SaXStorage::addGroup ( const QString &  ,
const QString &  ,
const QString &   
) [virtual]

Implements SaX::SaXStorageIF.

Definition at line 447 of file storage.cpp.

References mCDB.

QDict< QDict< QString > > SaX::SaXStorage::getTablePointerCDB ( void   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 465 of file storage.cpp.

References mCDB.

Referenced by SaX::SaXManipulateCard::getCardDrivers(), and SaX::SaXManipulateTablets::getTabletDrivers().

QList< QDict< QString > > SaX::SaXStorage::getTablePointerCDB_DATA ( const QString &   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 476 of file storage.cpp.

References mCDB.

QList< QDict< QString > > SaX::SaXStorage::getTablePointerDATA ( void   )  [virtual]

Implements SaX::SaXStorageIF.

Definition at line 495 of file storage.cpp.

References mData.


The documentation for this class was generated from the following files:
Generated on Tue Nov 28 19:09:47 2006 for libsax by  doxygen 1.5.0