source: Sophya/trunk/SophyaPI/PIext/nomgadapter.h@ 2975

Last change on this file since 2975 was 2975, checked in by ansari, 19 years ago

Ajout flag int lev ds les adaptateurs NObjMgrAdapter::Print(ostream& os, int lev=0) et NamedObjMgr::Print() + modif commande print - Reza 20 Juin 2006

File size: 2.3 KB
Line 
1// This may look like C code, but it is really -*- C++ -*-
2// Adaptateur pour objets gere par NamedObjMgr (piapp)
3// Reza 05/99
4// LAL-IN2P3/CNRS CEA-DAPNIA
5
6#ifndef NOMGADAPTER_H_SEEN
7#define NOMGADAPTER_H_SEEN
8
9#include "machdefs.h"
10#include "ppersist.h"
11#include "anydataobj.h"
12#include "pidrawer.h"
13#include "parradapter.h"
14#include "ntupintf.h"
15#include "generalfit.h"
16
17
18// Classe d'adaptateur d'objets de donnees pour la gestion d'objets
19// nommes (NamedObjMgr) de piapp
20
21class NObjMgrAdapter {
22public:
23 NObjMgrAdapter(AnyDataObj* o);
24 virtual ~NObjMgrAdapter();
25
26 virtual NObjMgrAdapter* Clone(AnyDataObj* o);
27
28 // Returns the actual data-object
29 virtual AnyDataObj* GetDataObj();
30
31 // Returns the actual data-object type (class name)
32 virtual string GetDataObjType();
33
34 // Returns a new data-object, cloning the original object
35 virtual AnyDataObj* CloneDataObj(bool share=false);
36
37 // Copies data from object o
38 virtual void CopyFrom(AnyDataObj* o);
39
40// Returns a string representation of the object
41 virtual string ToString();
42// Fills the object from a string
43 virtual void FillFromString();
44
45// Returns a string with synthetic information about the object (lev-> Level of details)
46 virtual string GetInfoString(int lev=0);
47
48 virtual void SavePPF(POutPersist& s, string const & nom);
49
50 virtual void Print(ostream& os, int lev=0);
51 virtual PIDrawer* GetDrawer(string& dopt);
52 virtual P2DArrayAdapter* Get2DArray(string& dopt);
53
54// NTupleInterface* nti = GetNTupleInterface(adel)
55// Retourne un objet de type NTupleInterface (nti), ainsi que adel
56// si adel == true, le programme appelant doit faire delete de nti
57 virtual NTupleInterface* GetNTupleInterface(bool& adel);
58
59// Methode pour l'interface GeneralFit.
60// Si adel==true:
61// le programme appelant doit faire delete du GeneralFitData retourne
62 virtual GeneralFitData* GetGeneralFitData(bool& adel
63 ,GeneralFitData::FitErrType errtype=GeneralFitData::DefaultError
64 ,double errscale=1.,double errmin=0.
65 ,int i1=0,int i2=-1,int j1=0,int j2=-1);
66 virtual AnyDataObj* FitResidusObj(GeneralFit& mfit);
67 virtual AnyDataObj* FitFunctionObj(GeneralFit& mfit);
68
69protected:
70 AnyDataObj* mObj;
71};
72
73#endif
Note: See TracBrowser for help on using the repository browser.