Transaction Table. More...
#include <rtransactiontable.h>
Collaboration diagram for RTransactionTable:
Public Member Functions | |
RTransactionTable (RDb *db, RString name) | |
RTransactionTable (RDb *db, RString name, size_t nb,...) | |
size_raw | WriteTransaction (size_t id,...) |
RQuery * | ReadTransaction (size_raw id, bool wait) |
void | WaitTransaction (size_raw id) |
void | RemoveTransaction (size_raw id) |
~RTransactionTable (void) | |
RTransactionTable (RDb *db, RString name) | |
RTransactionTable (RDb *db, RString name, size_t nb,...) | |
size_raw | WriteTransaction (size_t id,...) |
RQuery * | ReadTransaction (size_raw id, bool wait) |
void | WaitTransaction (size_raw id) |
void | RemoveTransaction (size_raw id) |
~RTransactionTable (void) | |
Private Attributes | |
RString | Name |
RContainer< RString, true, false > | Params |
RDb * | DB |
Detailed Description
Transaction Table.
The RTransactionTable class provides a representation for a transaction table.
Constructor & Destructor Documentation
RTransactionTable | ( | RDb * | db, |
RString | name | ||
) |
Constructor of a transaction table.
- Parameters
-
db Database. name Name of the transaction table.
RTransactionTable | ( | RDb * | db, |
RString | name, | ||
size_t | nb, | ||
... | |||
) |
Constructor of a transaction table.
- Parameters
-
db Database. name Name of the transaction table. nb Number of parameters. ... Name of the parameters of the transaction (transid is reserved).
~RTransactionTable | ( | void | ) |
Destructor.
RTransactionTable | ( | RDb * | db, |
RString | name | ||
) |
Constructor of a transaction table.
- Parameters
-
db Database. name Name of the transaction table.
RTransactionTable | ( | RDb * | db, |
RString | name, | ||
size_t | nb, | ||
... | |||
) |
Constructor of a transaction table.
- Parameters
-
db Database. name Name of the transaction table. nb Number of parameters. ... Name of the parameters of the transaction (transid is reserved).
~RTransactionTable | ( | void | ) |
Destruct the transaction table.
Member Function Documentation
size_raw WriteTransaction | ( | size_t | id, |
... | |||
) |
Write a given transaction.
- Parameters
-
id Identifier of the transaction (if null, a new is created). ... Values of the parameters of the transaction (transid is reserved).
- Returns
- The identifier of the transaction.
Get a transaction.
- Parameters
-
id Identifier of the transaction. If null, all the existing transactions are loaded. wait If true, the method waits until at least one transaction arrived.
- Returns
- Pointer to a query containing the loaded transactions. This query should be destroyed by the caller.
void WaitTransaction | ( | size_raw | id | ) |
Wait that a given transaction arrived.
- Parameters
-
id Identifier of the transaction.
void RemoveTransaction | ( | size_raw | id | ) |
Remove a given transaction.
- Parameters
-
id Identifier of the transaction. If null, all the existing transactions are removed.
size_raw WriteTransaction | ( | size_t | id, |
... | |||
) |
Write a given transaction.
- Parameters
-
id Identifier of the transaction (if null, a new is created). ... Values of the parameters of the transaction (transid is reserved).
- Returns
- The identifier of the transaction.
Get a transaction.
- Parameters
-
id Identifier of the transaction. If null, all the existing transactions are loaded. wait If true, the method waits until at least one transaction arrived.
- Returns
- Pointer to a query containing the loaded transactions. This query should be destroyed by the caller.
void WaitTransaction | ( | size_raw | id | ) |
Wait that a given transaction arrived.
- Parameters
-
id Identifier of the transaction.
void RemoveTransaction | ( | size_raw | id | ) |
Remove a given transaction.
- Parameters
-
id Identifier of the transaction. If null, all the existing transactions are removed.
Field Documentation
|
private |
Name of the table.
|
private |
Parameters involved in a transaction.
|
private |
Database.