KaliVeda  1.13/01
Heavy-Ion Analysis Toolkit
GTDataParameters.h
Go to the documentation of this file.
1 /***************************************************************************
19  ***************************************************************************
20  * *
21  * This program is free software; you can redistribute it and/or modify *
22  * it under the terms of the GNU General Public License as published by *
23  * the Free Software Foundation; either version 2 of the License, or *
24  * (at your option) any later version. *
25  * *
26  ***************************************************************************/
27 
28 #ifndef GTDataParameters_H
29 #define GTDataParameters_H
30 
31 #include "TNamed.h"
32 #include "TString.h"
33 
47 class GTDataPar : public TNamed {
48 public:
49  GTDataPar(const TString name, const int index, const int bits) :
50  TNamed(name, (TString)"")
51  {
52  fIndex = index;
53  fBits = bits;
54  }
55  int Index(void)const
56  {
57  return (fIndex);
58  };
59  int Bits(void) const
60  {
61  return fBits;
62  };
63 private:
64  int fIndex; // Parameter index in data array
65  int fBits; // number of bits used to represent parameter
66 };
67 
68 
70 class GTDataParameters : public TObject {
71 public:
72  GTDataParameters(void);
73  ~GTDataParameters(void);
74  int Fill(const char* buffParam);
75  int GetIndex(const TString parName) const;
76  const char* GetParName(const int index) const;
77  GTDataPar* GetPar(const int index) const;
78  GTDataPar* GetPar(const TString parName) const;
80  {
81  return fMaxIndex;
82  };
83  const TList* GetList() const
84  {
85  return fList;
86  };
87 private:
88  char* CopyParam(char* Dest, char* Source) const;
92 public:
93  ClassDef(GTDataParameters, 1) // Data Parameter names and index class
94 };
95 
96 #endif
int Int_t
#define ClassDef(name, id)
Classes handling VME/VXI parameters in GANIL DAQ data.
int Bits(void) const
int Index(void) const
GTDataPar(const TString name, const int index, const int bits)
char * CopyParam(char *Dest, char *Source) const
Small utility routine to copy a char string.
GTDataPar * GetPar(const int index) const
Return the parameter corresponding to the parameter number.
Int_t fMaxIndex
but OK for now.
Int_t GetMaxIndex() const
const char * GetParName(const int index) const
Return the text label name corresponding to a parameter number.
int GetIndex(const TString parName) const
Return the index number corresponding to a text label.
const TList * GetList() const
GTDataParameters(void)
Default constructor. Don't create anything yet.
int Fill(const char *buffParam)