mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-13 00:31:14 +00:00
Organize sockets as a map of vectors of FairMQChannels. Update FairMQStateMachine by removing SETTINGINPUT, SETTINGOUTPUT, BIND and CONNECT states and by adding INITIALIZING_TASK, RESETTING_TASK and RESETTING_DEVICE states. Run states functions in their own thread.
43 lines
1.2 KiB
C++
43 lines
1.2 KiB
C++
/********************************************************************************
|
|
* Copyright (C) 2014 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
|
|
* *
|
|
* This software is distributed under the terms of the *
|
|
* GNU Lesser General Public Licence version 3 (LGPL) version 3, *
|
|
* copied verbatim in the file "LICENSE" *
|
|
********************************************************************************/
|
|
/**
|
|
* FairMQPollerZMQ.h
|
|
*
|
|
* @since 2014-01-23
|
|
* @author A. Rybalchenko
|
|
*/
|
|
|
|
#ifndef FAIRMQPOLLERZMQ_H_
|
|
#define FAIRMQPOLLERZMQ_H_
|
|
|
|
#include <vector>
|
|
|
|
#include "FairMQPoller.h"
|
|
#include "FairMQChannel.h"
|
|
|
|
class FairMQPollerZMQ : public FairMQPoller
|
|
{
|
|
public:
|
|
FairMQPollerZMQ(const std::vector<FairMQChannel>& channels);
|
|
|
|
virtual void Poll(int timeout);
|
|
virtual bool CheckInput(int index);
|
|
virtual bool CheckOutput(int index);
|
|
|
|
virtual ~FairMQPollerZMQ();
|
|
|
|
private:
|
|
zmq_pollitem_t* items;
|
|
int fNumItems;
|
|
|
|
/// Copy Constructor
|
|
FairMQPollerZMQ(const FairMQPollerZMQ&);
|
|
FairMQPollerZMQ operator=(const FairMQPollerZMQ&);
|
|
};
|
|
|
|
#endif /* FAIRMQPOLLERZMQ_H_ */ |