[339] | 1 | #include "machdefs.h"
|
---|
| 2 | #include <stdlib.h>
|
---|
| 3 | #include <typeinfo>
|
---|
| 4 | #include <iostream.h>
|
---|
| 5 | #include <string>
|
---|
| 6 |
|
---|
| 7 | #include "nomgfdadapter.h"
|
---|
| 8 | #include "pipodrw.h"
|
---|
| 9 |
|
---|
| 10 | //-------------------------------------------------------------------------
|
---|
| 11 | // Class Adaptateur d'objet (Pour NamedObjMgr) d'objet GeneralFitData
|
---|
| 12 | //-------------------------------------------------------------------------
|
---|
| 13 |
|
---|
| 14 | /* --Methode-- */
|
---|
| 15 | NOMAdapter_GeneralFitData::NOMAdapter_GeneralFitData(GeneralFitData* o)
|
---|
| 16 | : NObjMgrAdapter(o)
|
---|
| 17 | {
|
---|
| 18 | mG = o;
|
---|
| 19 | }
|
---|
| 20 |
|
---|
| 21 | /* --Methode-- */
|
---|
| 22 | NOMAdapter_GeneralFitData::~NOMAdapter_GeneralFitData()
|
---|
| 23 | {
|
---|
| 24 | }
|
---|
| 25 |
|
---|
| 26 | /* --Methode-- */
|
---|
| 27 | NObjMgrAdapter* NOMAdapter_GeneralFitData::Clone(AnyDataObj* o)
|
---|
| 28 | {
|
---|
| 29 | GeneralFitData* g = dynamic_cast<GeneralFitData *>(o);
|
---|
| 30 | if (g) return ( new NOMAdapter_GeneralFitData(g) );
|
---|
| 31 | return ( new NObjMgrAdapter(o) );
|
---|
| 32 | }
|
---|
| 33 |
|
---|
| 34 | /* --Methode-- */
|
---|
| 35 | void NOMAdapter_GeneralFitData::SavePPF(POutPersist& pos, string const & nom)
|
---|
| 36 | {
|
---|
| 37 | #ifdef SANS_EVOLPLANCK
|
---|
| 38 | // PEIDA-EROS L'histo est lui-meme PPersist
|
---|
| 39 | string tag = nom; // A cause de const
|
---|
| 40 | mG->Write(pos,0,tag);
|
---|
| 41 | #else
|
---|
| 42 | string s = typeid(*mObj).name();
|
---|
| 43 | cout<<"NOMAdapter_GeneralFitData::SavePPF() - Error : Not supported for "<<s<<endl;
|
---|
| 44 | #endif
|
---|
| 45 | }
|
---|
| 46 |
|
---|
| 47 | /* --Methode-- */
|
---|
| 48 | void NOMAdapter_GeneralFitData::Print(ostream& os)
|
---|
| 49 | {
|
---|
| 50 | os << *(mG);
|
---|
| 51 | }
|
---|
| 52 |
|
---|
| 53 | /* --Methode-- */
|
---|
| 54 | NTupleInterface* NOMAdapter_GeneralFitData::GetNTupleInterface()
|
---|
| 55 | {
|
---|
| 56 | return( new NTupInt_GeneralFitData(mG) );
|
---|
| 57 | }
|
---|
| 58 |
|
---|
| 59 | // -------------------------------------------------------------
|
---|
| 60 |
|
---|
| 61 | /* --Methode-- */
|
---|
| 62 | NTupInt_GeneralFitData::NTupInt_GeneralFitData(GeneralFitData* g)
|
---|
| 63 | {
|
---|
| 64 | mG = g;
|
---|
| 65 | }
|
---|
| 66 |
|
---|
| 67 | /* --Methode-- */
|
---|
| 68 | NTupInt_GeneralFitData::~NTupInt_GeneralFitData()
|
---|
| 69 | {
|
---|
| 70 | }
|
---|
| 71 |
|
---|
| 72 | /* --Methode-- */
|
---|
| 73 | uint_4 NTupInt_GeneralFitData::NbLines() const
|
---|
| 74 | {
|
---|
| 75 | return(mG->NbLines());
|
---|
| 76 | }
|
---|
| 77 |
|
---|
| 78 | /* --Methode-- */
|
---|
| 79 | uint_4 NTupInt_GeneralFitData::NbColumns() const
|
---|
| 80 | {
|
---|
| 81 | return(mG->NbColumns());
|
---|
| 82 | }
|
---|
| 83 |
|
---|
| 84 | /* --Methode-- */
|
---|
| 85 | r_8* NTupInt_GeneralFitData::GetLineD(int n) const
|
---|
| 86 | {
|
---|
| 87 | return(mG->GetLineD(n));
|
---|
| 88 | }
|
---|
| 89 |
|
---|
| 90 | /* --Methode-- */
|
---|
| 91 | string NTupInt_GeneralFitData::VarList_C(const char* nx) const
|
---|
| 92 | {
|
---|
| 93 | return(mG->VarList_C(nx));
|
---|
| 94 | }
|
---|