]> git.uio.no Git - u/mrichter/AliRoot.git/blob - MONITOR/alistoragemanager/AliStorageTypes.h
Merge branch 'master' of https://git.cern.ch/reps/AliRoot
[u/mrichter/AliRoot.git] / MONITOR / alistoragemanager / AliStorageTypes.h
1 #ifndef AliStorageTypes_H
2 #define AliStorageTypes_H
3
4 #include <TSystem.h>
5 #include <TFile.h>
6
7 inline const char* GetConfigFilePath(){
8     return Form("%s/setupStorageDatabase.sh",gSystem->Getenv("HOME"));
9 }
10
11 enum storageSockets{
12         SERVER_COMMUNICATION_REQ=0,
13         SERVER_COMMUNICATION_REP,
14         CLIENT_COMMUNICATION_REQ,
15         CLIENT_COMMUNICATION_REP,
16         EVENTS_SERVER_PUB,
17         EVENTS_SERVER_SUB,
18         XML_PUB,
19         ITS_POINTS_PUB,
20         ITS_POINTS_SUB,
21         NUMBER_OF_SOCKETS
22 };
23         
24 enum statusType{
25         STATUS_WAITING=1,
26         STATUS_OK,
27         STATUS_ERROR,
28         STATUS_DOWN
29 };
30
31 enum requestType{
32         REQUEST_CONNECTION=1,
33         REQUEST_RECEIVING,
34         REQUEST_SAVING,
35         REQUEST_CURRENT_SIZE,
36         REQUEST_LIST_EVENTS,
37         REQUEST_GET_EVENT,
38         REQUEST_GET_NEXT_EVENT,
39         REQUEST_GET_PREV_EVENT,
40         REQUEST_GET_LAST_EVENT,
41         REQUEST_GET_FIRST_EVENT,
42         REQUEST_MARK_EVENT,
43         REQUEST_SET_PARAMS,
44         REQUEST_GET_PARAMS
45 };
46
47 struct clientRequestStruct{
48         int messageType;
49         int maxStorageSize;
50         int maxOccupation;
51         int removeEvents;
52         int eventsInChunk;
53 };
54
55 struct eventStruct{
56         int runNumber;
57         int eventNumber;
58 };
59
60 struct listRequestStruct{
61         int runNumber[2];
62         int eventNumber[2];
63         int marked[2];
64         int multiplicity[2];
65         char system[2][20];
66 };
67
68 struct serverRequestStruct{
69         int messageType;
70         struct eventStruct event;
71         struct listRequestStruct list;
72 };
73
74 struct recPointsStruct{
75   TFile *files[10];
76 };
77
78 typedef struct serverListStruct{
79         int runNumber;
80         int eventNumber;
81         char system[20];
82         int multiplicity;
83         int marked;
84 }serverListStruct;
85
86 #endif