Changeset 1348 for trunk/MagicSoft/Mars/mdata
- Timestamp:
- 06/05/02 10:20:05 (23 years ago)
- Location:
- trunk/MagicSoft/Mars/mdata
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mdata/MData.cc
r1304 r1348 48 48 #include "MData.h" 49 49 50 #include <ostream.h> 51 50 52 ClassImp(MData); 53 54 Bool_t MData::AsciiWrite(ostream &out) const 55 { 56 out << GetValue() << " "; 57 return kTRUE; 58 } 59 -
trunk/MagicSoft/Mars/mdata/MData.h
r1338 r1348 23 23 Double_t operator()() { return GetValue(); } 24 24 25 Bool_t AsciiWrite(ostream &out) const; 26 25 27 ClassDef(MData, 0) // A Base class for a generalized value 26 28 }; -
trunk/MagicSoft/Mars/mdata/MDataChain.cc
r1339 r1348 81 81 #include "MDataChain.h" 82 82 83 #include <math.h> // fabs on Alpha 83 84 #include <ctype.h> // isalnum, ... 84 85 #include <stdlib.h> // strtod, ... … … 131 132 { 132 133 return fMember ? fMember->PreProcess(pList) : kFALSE; 134 } 135 136 // -------------------------------------------------------------------------- 137 // 138 // Checks whether at least one member has the ready-to-save flag. 139 // 140 Bool_t MDataChain::IsReadyToSave() const 141 { 142 *fLog << all << "fM=" << fMember << "/" << (int)fMember->IsReadyToSave() << " " << endl; 143 return fMember ? fMember->IsReadyToSave() : kFALSE; 133 144 } 134 145 -
trunk/MagicSoft/Mars/mdata/MDataChain.h
r1338 r1348 58 58 59 59 Bool_t IsValid() const { return fMember ? kTRUE : kFALSE; } 60 Bool_t IsReadyToSave() const; 60 61 61 62 void Print(Option_t *opt = "") const; -
trunk/MagicSoft/Mars/mdata/MDataList.cc
r1338 r1348 142 142 // -------------------------------------------------------------------------- 143 143 // 144 // Checks whether at least one member has the ready-to-save flag. 145 // 146 Bool_t MDataList::IsReadyToSave() const 147 { 148 TIter Next(&fMembers); 149 150 MData *data = NULL; 151 152 while ((data=(MData*)Next())) 153 if (data->IsReadyToSave()) 154 return kTRUE; 155 156 return kFALSE; 157 } 158 159 // -------------------------------------------------------------------------- 160 // 144 161 // If you want to add a new member to the list call this function with the 145 162 // pointer to the member to be added. -
trunk/MagicSoft/Mars/mdata/MDataList.h
r1305 r1348 41 41 42 42 Bool_t IsValid() const { return fMembers.GetSize() ? kTRUE : kFALSE; } 43 Bool_t IsReadyToSave() const; 43 44 44 45 Double_t GetValue() const; -
trunk/MagicSoft/Mars/mdata/MDataMember.cc
r1334 r1348 59 59 fObject = obj; 60 60 fCall = call; 61 } 62 63 // -------------------------------------------------------------------------- 64 // 65 // obj is a pointer to the instance of your class from which the data 66 // should be requested. TMethodCall (s. root dox) is a pointer 67 // to a TMethodCall object which should be the getter function for 68 // the data you want to get. 69 // 70 MDataMember::MDataMember(MParContainer *obj, const TString call) 71 { 72 fObject = obj; 73 fCall = obj->GetterMethod(call); 61 74 } 62 75 … … 134 147 // -------------------------------------------------------------------------- 135 148 // 149 // Returns the ready-to-save flag of the data member container 150 // 151 Bool_t MDataMember::IsReadyToSave() const 152 { 153 return IsValid() ? fObject->IsReadyToSave() : kFALSE; 154 } 155 156 // -------------------------------------------------------------------------- 157 // 136 158 // Print the name of the data member without an CR. 137 159 // -
trunk/MagicSoft/Mars/mdata/MDataMember.h
r1305 r1348 24 24 } 25 25 MDataMember(MParContainer *obj, TMethodCall *call); 26 MDataMember(MParContainer *obj, const TString call); 26 27 27 28 Double_t GetValue() const; … … 29 30 30 31 Bool_t IsValid() const { return fCall ? kTRUE : kFALSE; } 32 Bool_t IsReadyToSave() const; 31 33 32 34 void Print(Option_t *opt = "") const; -
trunk/MagicSoft/Mars/mdata/MDataValue.h
r1305 r1348 26 26 27 27 Bool_t IsValid() const { return kTRUE; } 28 Bool_t IsReadyToSave() const { return kFALSE; } 28 29 29 30 void Print(Option_t *opt = "") const;
Note:
See TracChangeset
for help on using the changeset viewer.