StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
SVT_Reader.hh
1 /***************************************************************************
2  *
3  * Author: M.J. LeVine
4  ***************************************************************************
5  * Description: common definitions for SVT (dummy placeholder)
6  *
7  *
8  * change log
9  * 02-Jul-99 MJL add navigation code to get to SVTP bank
10  *
11  ***************************************************************************
12  *
13  *
14  **************************************************************************/
15 #ifndef SVT_READER_HH
16 #define SVT_READER_HH
17 #include "StDaqLib/GENERIC/EventReader.hh"
18 #include "StDaqLib/GENERIC/RecHeaderFormats.hh"
19 
20 // Detector Reader Virtual Class
21 
22 
23 struct Bank_SVTP: public Bank
24 {
25  Pointer dummy[6]; //**** PLACE HOLDER for real bank definition ******
26  // look at TPC/TPCV2P0.cxx, TPCV2P0.hh for further details
27 };
28 
29 class SVT_Reader : public DetectorReader
30 {
31  friend class EventReader;
32 
33 public:
34  SVT_Reader *getSVTReader(int sector){cout <<"DUMMY implementation"<<endl; return FALSE;};
35  ZeroSuppressedReader *getZeroSuppressedReader(int sector){cout<<sector<<endl; return FALSE;};
36  ADCRawReader *getADCRawReader(int sector){cout<<sector<<endl; return FALSE;};
37  PedestalReader *getPedestalReader(int sector){cout<<sector<<endl; return FALSE;};
38  PedestalRMSReader *getPedestalRMSReader(int sector){cout<<sector<<endl; return FALSE;};
39  GainReader *getGainReader(int sector){cout<<sector<<endl; return FALSE;};
40  CPPReader *getCPPReader(int sector){cout<<sector<<endl; return FALSE;};
41  BadChannelReader *getBadChannelReader(int sector){cout<<sector<<endl; return FALSE;};
42  SVT_Reader(EventReader *er, Bank_SVTP *psvt){
43  pBankSVTP = psvt; // copy arg into class variable
44  ercpy = er; // squirrel away pointer eventreader for our friends
45  if (!pBankSVTP->test_CRC()) ERROR(ERR_CRC);
46  if (pBankSVTP->swap() < 0) ERROR(ERR_SWAP);
47  pBankSVTP->header.CRC = 0;
48  };
49 
50  ~SVT_Reader(){};
51 
52  int MemUsed(){return FALSE;};
53 
54 
55 protected:
56 
57  // copy of EventReader pointer
58  EventReader *ercpy;
59 
60  // Bank Pointers
61  Bank_DATAP *pBankDATAP;
62  Bank_SVTP *pBankSVTP;
63 
64 
65  // Useful functions
66  int InformBuffers(ZeroSuppressedReader *, int sector) { return FALSE; };
67  int InformBuffers(ADCRawReader *,int sector) { return FALSE; };
68  int InformBuffers(PedestalReader *,int sector) { return FALSE; };
69  int InformBuffers(PedestalRMSReader *,int sector) { return FALSE; };
70  int InformBuffers(GainReader *,int sector) { return FALSE; };
71  int InformBuffers(CPPReader *,int sector) { return FALSE; };
72  int InformBuffers(BadChannelReader *,int sector) { return FALSE; };
73  int InformBuffers(ConfigReader *,int sector) { return FALSE; };
74 
75  int AttachBuffers(ZeroSuppressedReader *, int sector) { return FALSE; };
76  int AttachBuffers(ADCRawReader *, int sector) { return FALSE; };
77  int AttachBuffers(PedestalReader *, int sector) { return FALSE; };
78  int AttachBuffers(PedestalRMSReader *, int sector) { return FALSE; };
79  int AttachBuffers(GainReader *, int sector) { return FALSE; };
80  int AttachBuffers(CPPReader *, int sector) { return FALSE; };
81  int AttachBuffers(BadChannelReader *, int sector) { return FALSE; };
82  int AttachBuffers(ConfigReader *, int sector) { return FALSE; };
83 };
84 
85 #endif