#ifndef HPARTICLECONSTANTS_H #define HPARTICLECONSTANTS_H // ----------------------------------------------------------------------------- #include "TObject.h" #include "TString.h" #include #include #include #include using namespace std; // ----------------------------------------------------------------------------- class HGeantKine; // ----------------------------------------------------------------------------- typedef struct { TString fName; TString fSpace; Long_t fId; Int_t fFormat; // 0=dec,1 =hex TString fDescription; TString printBitsString(Long_t data){ // print the binary reprentation of data. // Lowest bits at the right side TString tmp; for(Int_t i = 31; i >= 0; i --){ if((i+1)%4==0&&i<31) tmp+=" "; tmp+=((data >> i) & 0x1); } return tmp; } void printBits(Long_t data){ // print the binary reprentation of data. // Lowest bits at the right side for(Int_t i = 31; i >= 0; i --){ if(i%4==0) cout<<" "<> i) & 0x1) < nameToProp; static vector vnames; public: static Int_t getValue(TString name); static void printValue(TString name); static void printValueMatch(TString name); static void printSpace(TString space); static Bool_t addConstant(Long_t id, TString name,Int_t form,TString space,TString descr); static void clearConstants(); static vector initConstantNamesV(); static map initConstantNames(); static void print(Bool_t sort=kFALSE); // ------------------------------------------------------------------------- ClassDef(HParticleConstants,0) }; // ----------------------------------------------------------------------------- #endif