source: branches/Corsika7405Compatibility/mcamera/MCameraDC.h@ 18752

Last change on this file since 18752 was 9005, checked in by tbretz, 16 years ago
*** empty log message ***
File size: 1.4 KB
Line 
1#ifndef MARS_MCameraDC
2#define MARS_MCameraDC
3
4#ifndef MARS_MParContainer
5#include "MParContainer.h"
6#endif
7#ifndef MARS_MCamEvent
8#include "MCamEvent.h"
9#endif
10
11#ifndef ROOT_TArrayF
12#include <TArrayF.h>
13#endif
14
15class MCameraDC : public MParContainer, public MCamEvent
16{
17 friend class MReportCamera;
18 friend class MReportCurrents;
19private:
20 Byte_t fStatus; // CaCo monitored status of the High Voltage [0-9], Cam.HV.PS_state
21
22 TArrayF fArray; // [nA] Unsigned Int!
23
24 Int_t Interprete(TString &str, Int_t len=0);
25
26public:
27 MCameraDC(Int_t size=577, const char *name=NULL, const char *title=NULL);
28
29 Byte_t GetStatus() const { return fStatus; }
30
31 void SetCurrent(Int_t i, Float_t val) { fArray[i] = (Int_t)val; }
32 Float_t GetCurrent(Int_t i) const { return (*this)[i]; }
33 Float_t &operator[](Int_t i) { return (Float_t&)fArray[i]; }
34 const Float_t &operator[](Int_t i) const { return (*const_cast<MCameraDC*>(this))[i]; }
35
36 Float_t GetMin() const;
37 Float_t GetMax() const;
38
39 void Print(Option_t *opt=NULL) const;
40
41 Bool_t GetPixelContent(Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type=0) const
42 {
43 if (idx>=fArray.GetSize())
44 return kFALSE;
45
46 val = fArray[idx];
47 return val>0;
48 }
49 void DrawPixelContent(Int_t num) const
50 {
51 }
52
53 ClassDef(MCameraDC, 2) // Storage Container for the Currents (PRELIMINARY)
54};
55
56#endif
Note: See TracBrowser for help on using the repository browser.