14#ifndef ALICEO2_DEVICES_SIMDEVICE_H_
15#define ALICEO2_DEVICES_SIMDEVICE_H_
19#include <fairmq/Device.h>
21#include <TStopwatch.h>
62 bool Kernel(
int workerID,
fair::mq::Channel& requestchannel,
fair::mq::Channel& dataoutchannel,
fair::mq::Channel* statuschannel =
nullptr);
73 std::unique_ptr<o2::data::PrimaryChunk>
chunk;
87 o2::steer::O2MCApplication* mVMCApp =
nullptr;
void doLogInfo(int workerID, std::string const &message)
static bool initSim(fair::mq::Channel &channel, std::unique_ptr< FairRunSim > &simptr)
~O2SimDevice() final
Default destructor.
static FetchedChunk fetchChunk(int workerID, fair::mq::Channel &requestchannel)
requests one chunk of primaries from the server on the given channel
O2SimDevice(o2::steer::O2MCApplication *vmcapp, TVirtualMC *vmc)
bool isWorkAvailable(fair::mq::Channel &statuschannel, int workerID=-1)
void InitTask() final
Overloads the InitTask() method of fair::mq::Device.
ChunkStatus
outcome of asking the primary server for work
@ EndOfWork
the server sent the end-of-work marker
@ Work
a chunk to transport
@ Stop
the request could not be sent, or the server has nothing more to give; stop asking
@ Retry
nothing yet (server busy or no answer); ask again
bool ConditionalRun() final
Overloads the ConditionalRun() method of fair::mq::Device.
GLuint GLsizei const GLchar * message
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
std::unique_ptr< o2::data::PrimaryChunk > chunk
set for ChunkStatus::Work