List events panel in ED looks better now + preparation for sending RecPoints from...
[u/mrichter/AliRoot.git] / MONITOR / alistoragemanager / AliStorageEventManager.h
CommitLineData
164d3d29 1#ifndef AliStorageEventManager_H
2#define AliStorageEventManager_H
3
4#include "AliESDEvent.h"
5#include "AliStorageTypes.h"
6
7#include <vector>
8#include <string>
9#include <sstream>
10
11#include <TMessage.h>
a7f93de6 12#include <TFile.h>
164d3d29 13
14namespace zmq
15{
16 class context_t;
17 class socket_t;
18}
19
20class AliStorageEventManager
21{
22public:
23 static AliStorageEventManager* GetEventManagerInstance();
24
25 void Send(std::vector<serverListStruct> list,storageSockets socket);
26 void Send(struct serverRequestStruct *request,storageSockets socket);
27 bool Send(struct clientRequestStruct *request,storageSockets socket,int timeout = -1);
28 void Send(AliESDEvent *event,storageSockets socket);
a7f93de6 29 void Send(TFile *file,storageSockets socket);
30 void Send(struct recPointsStruct *files,storageSockets socket);
164d3d29 31 void Send(long message,storageSockets socket);
32 void Send(bool message,storageSockets socket);
33 void SendAsXml(AliESDEvent *event,storageSockets socket);
34
d2416c53 35 std::vector<serverListStruct> GetServerListVector(storageSockets socket,int timeout=-1);
fae81379 36 AliESDEvent* GetEvent(storageSockets socket,int timeout=-1);
a7f93de6 37 TFile* GetFile(storageSockets socket,int timeout=-1);
38 struct recPointsStruct* GetFiles(storageSockets socket,int timeout=-1);
164d3d29 39 struct serverRequestStruct* GetServerStruct(storageSockets socket);
186c4b6e 40 struct clientRequestStruct* GetClientStruct(storageSockets socket,int timeout=-1);
164d3d29 41 long GetLong(storageSockets socket);
42 bool GetBool(storageSockets socket);
43
44
45 bool CreateSocket(storageSockets socket);
46private:
47 AliStorageEventManager();
48 ~AliStorageEventManager();
49
50 static AliStorageEventManager *fManagerInstance;
51
52 std::string fStorageServer;
53 std::string fEventServer;
54 int fStorageServerPort;
55 int fStorageClientPort;
56 int fEventServerPort;
57 int fXmlServerPort;
a7f93de6 58 int fItsPointsServerPort;
164d3d29 59
60 zmq::context_t *fContexts[7];
61 zmq::socket_t *fSockets[7];
62
63 AliStorageEventManager(const AliStorageEventManager&);
64 AliStorageEventManager& operator=(const AliStorageEventManager&);
65};
66
67#endif