00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef TGO4PARAMETERMEMBER_H
00015 #define TGO4PARAMETERMEMBER_H
00016
00017 #include "TNamed.h"
00018
00019 class TGo4ParameterMember : public TNamed {
00020 public:
00021
00022 enum { kTString_t = 10001, kTGo4Fitter_t = 10002 };
00023
00024 TGo4ParameterMember();
00025 TGo4ParameterMember(const char* name, const char* title);
00026 virtual ~TGo4ParameterMember();
00027
00028 void SetType(const char* name, Int_t id) { fTypeName = name; fTypeId = id; }
00029 const char* GetTypeName() const { return fTypeName.Data(); }
00030 Int_t GetTypeId() const { return fTypeId; }
00031 Bool_t IsFitterItem() const { return GetTypeId()==kTGo4Fitter_t; }
00032
00033 void SetMemberId(Int_t id) { fMemberId = id; }
00034 Int_t GetMemberId() const { return fMemberId; }
00035
00036 void SetStrValue(const char* value) { fValue = value; }
00037 const char* GetStrValue() const { return fValue.Data(); }
00038 Bool_t CanStrEdit() const { return fTypeId!=kTGo4Fitter_t; }
00039
00040 void SetArrayIndexes(Int_t ndim=0, Int_t indx1 = -1, Int_t indx2 = -1);
00041 Bool_t CheckArrayIndexes(Int_t ndim, Int_t indx1, Int_t indx2);
00042 Bool_t IsArrayItem() const { return (fIndex1>=0); }
00043 const char* GetFullName(TString& buf);
00044
00045 void SetVisible(Bool_t on = kTRUE) { fVisible = on; }
00046 Bool_t IsVisible() const { return fVisible; }
00047
00048 TObject* GetObject() const { return fObject; }
00049 void SetObject(TObject* obj, Bool_t owner);
00050
00051 void SetValue(char* addr);
00052 void GetValue(char* addr);
00053
00054 void SetToZero();
00055 Int_t PrintMember(Text_t* buffer = 0, Int_t buflen = 0) const;
00056
00057 virtual void Clear(Option_t* opt="");
00058
00059 virtual void Print(Option_t* dummy="") const;
00060
00061 protected:
00062
00063 TString fTypeName;
00064 Int_t fTypeId;
00065 Int_t fMemberId;
00066 TString fValue;
00067 Int_t fIndex1;
00068 Int_t fIndex2;
00069 TObject* fObject;
00070 Bool_t fObjectOwner;
00071 Bool_t fVisible;
00072
00073 ClassDef(TGo4ParameterMember, 1);
00074 };
00075
00076
00077 #endif