9 #ifndef THEPEG_FactoryBase_H 10 #define THEPEG_FactoryBase_H 15 #include "ThePEG/Interface/Interfaced.h" 16 #include "FactoryBase.fh" 22 class IAnalysisFactory;
24 class IHistogramFactory;
25 class IDataPointSetFactory;
121 operator AIDA::IDataPointSet * () {
return dset; }
166 const string &
filename()
const {
return theFilename; }
172 const string &
suffix()
const {
return theSuffix; }
177 const string &
storeType()
const {
return theStoreType; }
188 normalizeToXSec(tH1DPtr histogram,
CrossSection unit = picobarn)
const = 0;
196 normalizeToXSec(tH2DPtr histogram,
CrossSection unit = picobarn)
const = 0;
203 virtual void normalizeToXSecFraction(tH1DPtr histogram)
const = 0;
210 virtual void normalizeToXSecFraction(tH2DPtr histogram)
const = 0;
216 virtual void normalizeToUnity(tH1DPtr histogram)
const = 0;
222 virtual void normalizeToUnity(tH2DPtr histogram)
const = 0;
231 return *theAnalysisFactory;
237 AIDA::ITree & tree()
const;
242 AIDA::IHistogramFactory & histogramFactory()
const;
247 AIDA::IDataPointSetFactory & dataSetFactory()
const;
252 void mkdir(
const string & path);
257 void mkdirs(
const string & path);
262 void cd(
const string & path);
279 tH1DPtr createHistogram1D(
const string & path,
int nb,
double lo,
double up);
296 tH1DPtr createHistogram1D(
const string & path,
const string & title,
int nb,
297 double lo,
double up);
312 tH1DPtr createHistogram1D(
const string & path,
const string & title,
313 const std::vector<double> & edges);
333 tH2DPtr createHistogram2D(
const string & path,
334 int nbx,
double xlo,
double xup,
335 int nby,
double ylo,
double yup);
355 tH2DPtr createHistogram2D(
const string & path,
const string & title,
356 int nbx,
double xlo,
double xup,
357 int nby,
double ylo,
double yup);
373 tH2DPtr createHistogram2D(
const string & path,
const string & title,
374 const std::vector<double> & xedges,
375 const std::vector<double> & yedges);
384 DataFiller createDataSet(
const string & path,
const string & title,
int dim);
393 void registerClient(
tIPtr client);
407 theAnalysisFactory = x;
451 virtual void doinitrun();
457 virtual void dofinish();
524 #include "ThePEG/Utilities/ClassTraits.h" 544 static string className() {
return "ThePEG::FactoryBase"; }
string theFilename
Together with theSuffix, the name of the file where the resulting histograms will be stored...
PersistentIStream is used to read persistent objects from a stream where they were previously written...
void analysisFactory(AIDA::IAnalysisFactory *x)
Set the underlying AIDA::IAnalysisFactory object.
static AbstractClassDescription< FactoryBase > initFactoryBase
The static object used to initialize the description of this class.
PersistentOStream is used to write objects persistently to a stream from which they can be read in ag...
A concreate implementation of ClassDescriptionBase describing an abstract class with persistent data...
const string & suffix() const
Together with filename(), the name of the file where the resulting histograms will be stored...
AIDA::IAnalysisFactory & analysisFactory() const
Access the underlying AIDA::IAnalysisFactory object.
TransientRCPtr is a simple wrapper around a bare pointer which can be assigned to and from an RCPtr a...
AIDA::IHistogram2D * tH2DPtr
Convenient typedef for pointer to AIDA::IHistogram2D.
Here is the documentation of the FactoryBase class.
This is the main namespace within which all identifiers in ThePEG are declared.
string theSuffix
Together with theFilename, the name of the file where the resulting histograms will be stored...
string theStoreType
The format in which the histograms are stored in the output file.
AIDA::IDataPointSet * tDSetPtr
Convenient typedef for pointer to AIDA::IHistogram1D.
const AIDA::IHistogram2D * tcH2DPtr
Convenient typedef for pointer to const AIDA::IHistogram2D.
DataFiller & operator<<(double x)
Add a number to measurement currently being read.
DataFiller is a helper class to facilitate adding data to a DataPointSet.
const string & storeType() const
The format in which the histograms are stored in the output file.
AIDA::IDataPointSet * dset
The underlying IDataPointSet.
deque< double > v
The collected numbers to be committed to the IDataPointSet.
set< IPtr > clients
A set of client objects which have required histograms from this factory.
The Interfaced class is derived from the InterfacedBase class adding a couple of things particular to...
AIDA::IHistogram1D * tH1DPtr
Convenient typedef for pointer to AIDA::IHistogram1D.
DataFiller(AIDA::IDataPointSet *dps)
The standard constructor needs a IDataPointSet as argument.
The default concrete implementation of ClassTraitsBase.
AIDA::IDataPointSetFactory * theDataSetFactory
A pointer to the underlying AIDA::IDataPointSetFactory object.
This template class allows the compiler to check calculations with physical quantities for dimensiona...
const AIDA::IDataPointSet * tcDSetPtr
Convenient typedef for pointer to const AIDA::IHistogram1D.
AIDA::ITree * theTree
A pointer to the underlying AIDA::ITree object.
const AIDA::IHistogram1D * tcH1DPtr
Convenient typedef for pointer to const AIDA::IHistogram1D.
const string & filename() const
Together with suffix(), the name of the file where the resulting histograms will be stored...
DataFiller(const DataFiller &df)
Copy constructor.
BaseClassTraits describes the base classes of the templated class.
AIDA::IAnalysisFactory * theAnalysisFactory
A pointer to the underlying AIDA::IAnalysisFactory object.
AIDA::IHistogramFactory * theHistogramFactory
A pointer to the underlying AIDA::IHistogramFactory object.
The templated ClassTraitsBase class defines a set of default information about classes used by ThePEG...