Public Attributes | |
void * | userObject |
I_QueueGetProperties | getProperties |
Access the configuration properties (readonly). | |
I_QueuePut | put |
Puts a new entry into the queue. | |
I_QueuePeekWithSamePriority | peekWithSamePriority |
Returns maximum the first num element in the queue of highest priority but does not remove it from that queue (leaves it untouched). | |
I_QueueRandomRemove | randomRemove |
Removes the given entries from persistence. | |
I_QueueClear | clear |
Clears (removes all entries) this queue. | |
I_QueueShutdown | shutdown |
Shutdown the queue and free memory resources, no persistent entries are destroyed. | |
I_QueueDestroy | destroy |
An administrative command to remove the backend store (e.g. | |
I_QueueNumOfEntries | getNumOfEntries |
Access the current number of entries. | |
I_QueueMaxNumOfEntries | getMaxNumOfEntries |
Access the configured maximum number of elements for this queue. | |
I_QueueNumOfBytes | getNumOfBytes |
Returns the amount of bytes currently in the queue If the implementation of this interface is not able to return the correct number of entries (for example if the implementation must make a remote call to a DB which is temporarly not available) it will return -1. | |
I_QueueMaxNumOfBytes | getMaxNumOfBytes |
Access the configured capacity (maximum bytes) for this queue. | |
I_QueueEmpty | empty |
Check if queue is empty. | |
XMLBLASTER_LOG_LEVEL | logLevel |
Set the logLevel to LOG_TRACE to get logging output. | |
XmlBlasterLogging | log |
Assign your logging function pointer to receive logging output. | |
I_QueueInitialize | initialize |
For internal use only. | |
int | isInitialized |
void * | privateObject |
Hold current state of I_QueueStruct. |
See SQLiteQueue.c for a DB based persistent queue implementation. The 'I_' stands for 'interface'.
Definition at line 88 of file QueueInterface.h.
Definition at line 90 of file QueueInterface.h.
Access the configuration properties (readonly).
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) |
Definition at line 97 of file QueueInterface.h.
Puts a new entry into the queue.
Note that this method takes the entry pointed to by the argument and puts a reference to it into the queue. This means that you can not destroy the entry before the reference to it has been processed.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) | |
queueEntry | The data of type QueueEntry to put into the queue Please initialize it with memset(&queueEntry, 0, sizeof(QueueEntry)); before setting your values so we can add new fields without breaking your code | |
exception | Check *exception.errorCode!=0 for errors: "user.illegalArgument", "resource.db.unavailable", "resource.db.block", "resource.db.unknown" "resource.overflow.queue.entries", "resource.overflow.queue.bytes" |
Definition at line 113 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::put().
Returns maximum the first num element in the queue of highest priority but does not remove it from that queue (leaves it untouched).
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) | |
maxNumOfEntries | Access num entries, if -1 access all entries currently found | |
maxNumOfBytes | so many entries are returned as not to exceed the amount specified. If the first entry is bigger than this amount, it is returned anyway. -1 is unlimited. | |
exception | *exception.errorCode!=0 if the underlying implementation gets an exception: "user.illegalArgument", "resource.db.unavailable", "resource.db.block", "resource.db.unknown" |
Definition at line 129 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::peekWithSamePriority().
Removes the given entries from persistence.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) | |
queueEntryArr | The entries to remove Please initialize each entry with memset(&queueEntry, 0, sizeof(QueueEntry)); (or use calloc() ) before setting your values so we can add new fields without breaking your code | |
exception | Check *exception.errorCode!=0 for errors: "user.illegalArgument", "resource.db.unavailable", "resource.db.block", "resource.db.unknown" "resource.overflow.queue.entries", "resource.overflow.queue.bytes" |
Definition at line 144 of file QueueInterface.h.
Clears (removes all entries) this queue.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) | |
exception | Check *exception.errorCode!=0 for errors: "user.illegalArgument", "resource.db.unavailable", "resource.db.block", "resource.db.unknown" |
Definition at line 154 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::clear().
Shutdown the queue and free memory resources, no persistent entries are destroyed.
The backend store is closed and all memory allocation are freed and the queueP is set to NULL
NOTE: Your queueP is not usable anymore after this call.
queuePP | The pointer to your queue pointer, after freeing it is set to *queuePP=0 | |
exception | *exception.errorCode!=0 if the underlying implementation gets an exception |
Definition at line 163 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::~SQLiteQueuePlugin().
An administrative command to remove the backend store (e.g.
clear all entries and the database files).
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) |
Definition at line 170 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::destroy().
Access the current number of entries.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) |
Definition at line 177 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::getNumOfEntries().
Access the configured maximum number of elements for this queue.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) |
Definition at line 184 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::getMaxNumOfEntries().
Returns the amount of bytes currently in the queue If the implementation of this interface is not able to return the correct number of entries (for example if the implementation must make a remote call to a DB which is temporarly not available) it will return -1.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) |
Definition at line 194 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::getNumOfBytes().
Access the configured capacity (maximum bytes) for this queue.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) |
Definition at line 201 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::getMaxNumOfBytes().
Check if queue is empty.
queueP | The 'this' pointer (similar to the hidden C++ 'this' pointer) returns true if the queue is empty, false otherwise |
Definition at line 208 of file QueueInterface.h.
Referenced by org::xmlBlaster::util::queue::SQLiteQueuePlugin::empty(), and org::xmlBlaster::util::queue::SQLiteQueuePlugin::peekWithSamePriority().
XMLBLASTER_LOG_LEVEL I_QueueStruct::logLevel |
Set the logLevel to LOG_TRACE to get logging output.
Other levels are not supported
Definition at line 214 of file QueueInterface.h.
XmlBlasterLogging I_QueueStruct::log |
Assign your logging function pointer to receive logging output.
Definition at line 220 of file QueueInterface.h.
Definition at line 229 of file QueueInterface.h.