#include <IPCManager.h>
Public Member Functions | |
void | initialise (bool segmentationMode, UInt_t nbRawCells, UInt_t nbRecoCells, UInt_t nbDqmCells, UInt_t rawCellSize, UInt_t recoCellSize, UInt_t dqmCellSize, int freeResRequiredForAllocate, BUProxy *bu, SMProxy *sm, log4cplus::Logger logger, unsigned int resourceStructureTimeout, EvffedFillerRB *frb, xdaq::Application *) throw (evf::Exception) |
IPCMethod *const | ipc () |
IPCManager (bool useMQ) | |
virtual | ~IPCManager () |
Private Attributes | |
IPCMethod * | ipc_ |
bool | useMessageQueueIPC_ |
Class used to create and initialize an IPC method of the required type. If constructed with argument <false>, the manager will create and initialize a FUResourceTable object. If constructed with argument <true>, the manager will create and initialize a FUResourceQueue object.
Definition at line 27 of file IPCManager.h.
IPCManager::IPCManager | ( | bool | useMQ | ) |
Definition at line 19 of file IPCManager.cc.
: useMessageQueueIPC_(useMQ) { }
IPCManager::~IPCManager | ( | ) | [virtual] |
void IPCManager::initialise | ( | bool | segmentationMode, |
UInt_t | nbRawCells, | ||
UInt_t | nbRecoCells, | ||
UInt_t | nbDqmCells, | ||
UInt_t | rawCellSize, | ||
UInt_t | recoCellSize, | ||
UInt_t | dqmCellSize, | ||
int | freeResRequiredForAllocate, | ||
BUProxy * | bu, | ||
SMProxy * | sm, | ||
log4cplus::Logger | logger, | ||
unsigned int | resourceStructureTimeout, | ||
EvffedFillerRB * | frb, | ||
xdaq::Application * | app | ||
) | throw (evf::Exception) |
Initialize the IPCMethod object with the given parameters.
Definition at line 29 of file IPCManager.cc.
References gather_cfg::cout, and fwlog::logger().
Referenced by evf::rb_statemachine::SharedResources::configureResources().
{ // XXX: MQ IPC is disabled until it is ready useMessageQueueIPC_ = false; if (!useMessageQueueIPC_) { // IPC communication type is SharedMemory //improve replace with logging cout << "IPCMANAGER:: ----> IPC communication type is Shared Memory!" << endl; ipc_ = new FUResourceTable(segmentationMode, nbRawCells, nbRecoCells, nbDqmCells, rawCellSize, recoCellSize, dqmCellSize, freeResReq, bu, sm, logger, resourceStructureTimeout, frb, app); } else { // IPC communication type is MessageQueue cout << "IPCMANAGER:: ----> IPC communication type is Message Queue!" << endl; ipc_ = new FUResourceQueue(segmentationMode, nbRawCells, nbRecoCells, nbDqmCells, rawCellSize, recoCellSize, dqmCellSize, freeResReq, bu, sm, logger, resourceStructureTimeout, frb, app); } }
IPCMethod *const IPCManager::ipc | ( | ) |
Returns a const pointer to the IPCMethod object created by the manager.
Definition at line 59 of file IPCManager.cc.
References ipc_.
Referenced by evf::rb_statemachine::SharedResources::configureResources().
{ return ipc_; }
IPCMethod* evf::IPCManager::ipc_ [private] |
Definition at line 55 of file IPCManager.h.
Referenced by ipc(), and ~IPCManager().
bool evf::IPCManager::useMessageQueueIPC_ [private] |
Definition at line 52 of file IPCManager.h.