#include <GUIDataPool.h>
|
static void | AddToNotificationQueue (CDataPoolEntry &kEntry) |
|
static void | Clear () |
|
static void | DumpDataPool () |
|
static const eC_TListDoubleLinked< ObjectHandle_t > | GetAutoRegisteredObservers (const DataPoolResource_t eDataID) |
|
static eC_UInt | GetNOFDataPoolResources () |
|
static eC_UInt | GetNumberOfPendingNotifications () |
|
static void | ReadDataPoolFromFile (const eC_String &rkPath) |
|
static void | WriteDataPoolToFile (const eC_String &rkPath) |
|
|
static void | Set (const DataPoolResource_t eDataID, CGUIValue kValue, const eC_UInt uiX=0, const eC_UInt uiY=0) |
|
static void | Get (const DataPoolResource_t eDataID, CGUIValue &kValue, const eC_UInt uiX=0, const eC_UInt uiY=0) |
|
static void | SetDataPoolEntry (const DataPoolResource_t eDataID, CDataPoolEntry *pkEntry) |
|
static void | SetQuantity (const DataPoolResource_t eDataID, const eC_UInt uiX, const eC_UInt uiY, const eC_Bool &bPreserve=false) |
|
static void | GetQuantity (const DataPoolResource_t eDataID, eC_UInt &uiX, eC_UInt &uiY) |
|
static void | Get (const DataPoolResource_t eDataID, CDataPoolEntry **ppkEntry) |
|
static void | GetUpdate (CDataPoolConnector *pkObserver) |
|
|
static eC_Bool | Lock () |
|
static eC_Bool | Unlock () |
|
|
static void | Register (const DataPoolResource_t eDataID, CGUIObject *pkObserver) |
|
static void | Register (const DataPoolResource_t eDataID, CDataPoolConnector *pkObserver) |
|
static void | Register (const DataPoolResource_t eDataID, DataPoolCallback pCallback) |
|
static void | UnregisterCallback (const DataPoolResource_t eDataID) |
|
static void | Unregister (const DataPoolResource_t eDataID, CGUIObject *pkObserver) |
|
static void | Unregister (const DataPoolResource_t eDataID, CDataPoolConnector *pkObserver) |
|
static void | Unregister (CGUIObject *pkObserver) |
|
static void | Unregister (CDataPoolConnector *pkObserver) |
|
static void | AutoRegister (const DataPoolResource_t eDataID, const ObjectHandle_t eObjectID) |
|
static void | RemoveAutoRegister (const DataPoolResource_t eDataID, const ObjectHandle_t eObjectID) |
|
static DataPoolResource_t | RegisterDynamicDataPoolResource () |
|
|
class | CGUI |
|
class | CGUIObject |
|
DataPool implementation for Guiliani applications.
- See also
- DataPool
◆ AddToNotificationQueue()
static void CGUIDataPool::AddToNotificationQueue |
( |
CDataPoolEntry & |
kEntry | ) |
|
|
static |
Adds the datapool entry to the list of pending notifications. Note that each DataPoolEntry gets notified only ONCE per GUI-cycle! This is required to avoid circular dependencies.
- Parameters
-
kEntry | DataPoolEntry for which a notification shall be triggered. |
◆ AutoRegister()
Automatically registers an object ID to an entry within the DataPool. Whenever an object with this ID gets constructed, it will automatically be registered to the given DataPool entry.
- Note
- This will automatically perform a GETGUI.GetObjectByID(eObjectID) and thus register the first found object with this ID to eDataID.
- Parameters
-
eDataID | ID of entry within DataPool to which this ObjectID shall be automatically registered |
eObjectID | ID of object, which shall automatically be registered to eDataID upon construction. |
◆ Clear()
static void CGUIDataPool::Clear |
( |
| ) |
|
|
static |
Removes all registered DataPool observers and all entries within the list of auto-registered observers.
◆ DumpDataPool()
static void CGUIDataPool::DumpDataPool |
( |
| ) |
|
|
static |
Dumps debugging information about the DataPool to the registered trace sinks. This is only available within debug builds.
◆ Get() [1/2]
Gets the DataPoolEntry for the given DataID,
- Parameters
-
eDataID | ID of entry within the DataPool, which shall be returned |
ppkEntry | Address of a pointer to a DataPoolEntry, which will be set to the found entry or to NULL if not found |
◆ Get() [2/2]
Gets the current value of the given DataPool entry. This API is threadsafe.
- Parameters
-
eDataID | ID of entry within the DataPool, which shall be returned |
kValue | Reference to GUIValue, which will receive the current value of eDataID |
uiX | X-Index of value to get within eDataID (if it is a multidimensional DataPoolEntry) |
uiY | Y-Index of value to get within eDataID (if it is a multidimensional DataPoolEntry) |
◆ GetAutoRegisteredObservers()
- Returns
- A list of all Object IDs, which will be automatically registered to the given DataPool-entry upon their construction.
- Parameters
-
eDataID | The DataPool ID to query |
◆ GetNOFDataPoolResources()
static eC_UInt CGUIDataPool::GetNOFDataPoolResources |
( |
| ) |
|
|
inlinestatic |
- Returns
- Total number of DataPoolResources
◆ GetNumberOfPendingNotifications()
static eC_UInt CGUIDataPool::GetNumberOfPendingNotifications |
( |
| ) |
|
|
inlinestatic |
- Returns
- The number of currently pending notifications, which will be processed during the next frame
◆ GetQuantity()
static void CGUIDataPool::GetQuantity |
( |
const DataPoolResource_t |
eDataID, |
|
|
eC_UInt & |
uiX, |
|
|
eC_UInt & |
uiY |
|
) |
| |
|
static |
Returns the Quantity of the given DataPoolEntry. The quantity is the number of values, which is stored in the entry. It is stored as a two-dimensional array.
- Parameters
-
eDataID | ID of entry whose quantity shall be returned |
uiX | X Quantity |
uiY | Y Quantity |
◆ GetUpdate()
Requests an immediate update for the given DataPoolConnector. All DataPoolEntries to which the DataPoolConnector is registered will trigger an OnNotification(CDataPoolEntry&) on pkObserver.
- Parameters
-
pkObserver | DataPoolConnectorwhich shall receive an update with the current values within the DataPool. |
◆ Lock()
static eC_Bool CGUIDataPool::Lock |
( |
| ) |
|
|
inlinestatic |
Locks the DataPool for thread-critical operations.
- Returns
- True if the DataPool was locked successfully, False otherwise.
◆ ReadDataPoolFromFile()
static void CGUIDataPool::ReadDataPoolFromFile |
( |
const eC_String & |
rkPath | ) |
|
|
static |
Reads the DataPool from a file. The DataPool file stores Object handles, which will be autoregistered to a given DataPool entry.
- Parameters
-
rkPath | Full filename (including path) of the file containing the data pool |
◆ Register() [1/3]
Registers a DataPoolConnector to the data entry with the given ID. The CDataPoolConnector's OnNotification() method will be called if the data entry changes.
- Parameters
-
eDataID | ID of entry within the DataPool to which the given DataPoolConnector shall be registered. |
pkObserver | Pointer to DataPoolConnector, which shall be registered to eDataID |
◆ Register() [2/3]
Registers an object to the data entry with the given ID. The object's SetValue() method will then automatically be called by the object's CGUIDataPoolConnector if the data entry changes.
- Parameters
-
eDataID | ID of entry within the DataPool to which the given object shall be registered. |
pkObserver | Pointer to GUIObject, which shall be registered to eDataID |
◆ Register() [3/3]
static void CGUIDataPool::Register |
( |
const DataPoolResource_t |
eDataID, |
|
|
DataPoolCallback |
pCallback |
|
) |
| |
|
static |
Registers a Callback function within the DataPoolEntry for the given ID Note that only ONE callback function can be registered to any DataPool ID. Registering another callback will replace the previous one.
- Parameters
-
eDataID | ID of entry within the DataPool to which the given callback function shall be registered. |
pCallback | function pointer to the callback, which shall be registered to eDataID |
◆ RegisterDynamicDataPoolResource()
Creates a dynamic DataPool Entry and returns its ID.
- Returns
- ID of newly created entry within DataPool
◆ RemoveAutoRegister()
Removes a DataID from the Auto-Registry of the given ObjectID. Objects with this ObjectID will no longer be automatically registered to this DataID upon their construction.
- Parameters
-
eDataID | ID of entry within DataPool to which this ObjectID shall no longer be automatically registered |
eObjectID | ObjectID, which shall no longer be automatically registered to eDataID |
◆ Set()
Sets the value of a DataPool entry. Setting a value in the Datapool will trigger a notification to all its observers during the next call to ProcessNotifications. This API is threadsafe.
- Parameters
-
eDataID | ID of entry within the DataPool, which shall be set |
kValue | New value to of eDataID |
uiX | X-Index of value to be set within eDataID (if it is a multidimensional DataPoolEntry) |
uiY | Y-Index of value to be set within eDataID (if it is a multidimensional DataPoolEntry) |
◆ SetDataPoolEntry()
Sets a specific DataPoolEntry for the given DataPoolResource. This enables users to write custom DataPoolEntries, which e.g., read data from external data sources such as databases, or application specific data structures.
- Parameters
-
eDataID | ID of entry within the DataPool, which shall be set |
pkEntry | Custom DataPoolEntry to be assigned to eDataID |
◆ SetQuantity()
static void CGUIDataPool::SetQuantity |
( |
const DataPoolResource_t |
eDataID, |
|
|
const eC_UInt |
uiX, |
|
|
const eC_UInt |
uiY, |
|
|
const eC_Bool & |
bPreserve = false |
|
) |
| |
|
static |
Sets the Quantity of the given DataPoolEntry. The quantity is the number of values, which is stored in the entry. It is stored as a two-dimensional array.
- Parameters
-
eDataID | ID of entry whose quantity shall be set |
uiX | New X Quantity |
uiY | New Y Quantity |
bPreserve | if set the contents are retained as far as possible |
◆ Unlock()
static eC_Bool CGUIDataPool::Unlock |
( |
| ) |
|
|
inlinestatic |
Unlocks the DataPool after thread-critical operations.
- Returns
- True if the DataPool was unlocked successfully, False otherwise.
◆ Unregister() [1/4]
Unregisters a DataPoolConnector from ALL Data entries.
- Parameters
-
pkObserver | Pointer to DataPoolConnector, which shall be unregistered from all DataPoolEntries |
◆ Unregister() [2/4]
static void CGUIDataPool::Unregister |
( |
CGUIObject * |
pkObserver | ) |
|
|
static |
Unregisters an object from ALL Data entries.
- Parameters
-
pkObserver | Pointer to GUIObject, which shall be unregistered from all DataPoolEntries |
◆ Unregister() [3/4]
Unregisters a DataPoolConnector to/from the data entry with the given ID.
- Parameters
-
eDataID | ID of entry within the DataPool from which the given DataPoolConnector shall be unregistered. |
pkObserver | Pointer to DataPoolConnector, which shall be unregistered from eDataID |
◆ Unregister() [4/4]
Unregisters an object to/from the data entry with the given ID.
- Parameters
-
eDataID | ID of entry within the DataPool from which the given object shall be unregistered. |
pkObserver | Pointer to GUIObject, which shall be unregistered from eDataID |
◆ UnregisterCallback()
Unregisters the Callback function for the DataPoolEntry for the given ID.
- Parameters
-
eDataID | ID of entry within the DataPool for which the callback shall be unregistered. |
◆ WriteDataPoolToFile()
static void CGUIDataPool::WriteDataPoolToFile |
( |
const eC_String & |
rkPath | ) |
|
|
static |
Writes the DataPool to a file. The DataPool file will contain the current Auto-Registry. All Object handles, which were registered to a DataPool entry through an earlier call to AutoRegister will be written to the DataPool file.
- Parameters
-
rkPath | Full filename (including path) of the file containing the data pool |
The documentation for this class was generated from the following file: