This static class generates message queues on demand and stores the queues in a map. More...
#include <MsgQueueFactory.h>
Public Member Functions | |
~MsgQueueFactory () | |
Destructor. | |
Static Public Member Functions | |
static AbstractMsgQueue * | getOrCreateMsgQueue (const std::string &name, uint32_t queuelength, bool blocking) |
searches for a queue with the specified name and creates a new one in case it does not find it | |
Static Private Attributes | |
static std::map< std::string, AbstractMsgQueue * > | blockingIPCQueueCol_ |
Collection of blocking message queues key ---> name of the key element ---> abstract queue linked to the name. | |
static std::map< std::string, AbstractMsgQueue * > | nonBlockingIPCQueueCol_ |
Collection of non blocking message queues key ---> name of the key element ---> abstract queue linked to the name. | |
static std::map< std::string, AbstractMsgQueue * > | localQueueCol_ |
Collection of local message queues key ---> name of the key element ---> abstract queue linked to the name. |
This static class generates message queues on demand and stores the queues in a map.
Definition at line 20 of file MsgQueueFactory.h.
fesa::MsgQueueFactory::~MsgQueueFactory | ( | ) |
Destructor.
Definition at line 81 of file MsgQueueFactory.cpp.
References blockingIPCQueueCol_, localQueueCol_, and nonBlockingIPCQueueCol_.
AbstractMsgQueue * fesa::MsgQueueFactory::getOrCreateMsgQueue | ( | const std::string & | name, | |
uint32_t | queuelength, | |||
bool | blocking | |||
) | [static] |
searches for a queue with the specified name and creates a new one in case it does not find it
name | The name of the requested Message queue | |
queuelength | the maximum length of the message queue | |
blocking | the access to the queue can be blocking or not |
Throws | FesaErrorQueuenameDuplication exception when a second message queue with same name but different length exists |
Definition at line 31 of file MsgQueueFactory.cpp.
References blockingIPCQueueCol_, FesaErrorQueuenameDuplication, fesa::AbstractEquipment::getInstance(), fesa::AbstractEquipment::getProcessType(), fesa::AbstractMsgQueue::getQueueLength(), localQueueCol_, nonBlockingIPCQueueCol_, and fesa::unsplit.
Referenced by fesa::AbstractEventSourceFactory::createOnDemandEventSource(), fesa::NotificationConsumer::NotificationConsumer(), and fesa::NotificationProducer::NotificationProducer().
std::map< std::string, AbstractMsgQueue * > fesa::MsgQueueFactory::blockingIPCQueueCol_ [static, private] |
Collection of blocking message queues key ---> name of the key element ---> abstract queue linked to the name.
Definition at line 46 of file MsgQueueFactory.h.
Referenced by getOrCreateMsgQueue(), and ~MsgQueueFactory().
std::map< std::string, AbstractMsgQueue * > fesa::MsgQueueFactory::localQueueCol_ [static, private] |
Collection of local message queues key ---> name of the key element ---> abstract queue linked to the name.
Definition at line 60 of file MsgQueueFactory.h.
Referenced by getOrCreateMsgQueue(), and ~MsgQueueFactory().
std::map< std::string, AbstractMsgQueue * > fesa::MsgQueueFactory::nonBlockingIPCQueueCol_ [static, private] |
Collection of non blocking message queues key ---> name of the key element ---> abstract queue linked to the name.
Definition at line 53 of file MsgQueueFactory.h.
Referenced by getOrCreateMsgQueue(), and ~MsgQueueFactory().