All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
IRndmGen.h
Go to the documentation of this file.
1 // $Header: /tmp/svngaudi/tmp.jEpFh25751/Gaudi/GaudiKernel/GaudiKernel/IRndmGen.h,v 1.5 2008/10/27 19:22:20 marcocle Exp $
2 #ifndef GAUDIKERNEL_IRNDMGEN_H
3 #define GAUDIKERNEL_IRNDMGEN_H
4 
5 // STL include files
6 #include <string>
7 #include <vector>
8 
9 // Framework include files
10 #include "GaudiKernel/IInterface.h"
11 
12 // Declaration of the interface ID ( interface id, major version, minor version)
13 static const InterfaceID IID_IRndmBit(150, 1, 0);
14 static const InterfaceID IID_IRndmFlat(151, 1, 0);
15 static const InterfaceID IID_IRndmChi2(152, 1, 0);
16 static const InterfaceID IID_IRndmGamma(153, 1, 0);
17 static const InterfaceID IID_IRndmGauss(154, 1, 0);
18 static const InterfaceID IID_IRndmLandau(155, 1, 0);
19 static const InterfaceID IID_IRndmPoisson(156, 1, 0);
20 static const InterfaceID IID_IRndmStudentT(157, 1, 0);
21 static const InterfaceID IID_IRndmBinomial(158, 1, 0);
22 static const InterfaceID IID_IRndmExponential(159, 1, 0);
23 static const InterfaceID IID_IRndmBreitWigner(160, 1, 0);
24 static const InterfaceID IID_IRndmBreitWignerCutOff(161, 1, 0);
25 static const InterfaceID IID_IRndmDefinedPdf(162, 1, 0);
26 static const InterfaceID IID_IRndmGaussianTail(163, 1, 0);
27 
28 
36 class GAUDI_API IRndmGen: virtual public IInterface {
37 public:
40 
41  class Param {
42  protected:
45  public:
47  Param( const InterfaceID& type = IID_IRndmFlat ) : m_type(type) {}
49  virtual ~Param() {}
51  virtual const InterfaceID& type() const { return m_type; }
53  virtual Param* clone() const = 0;
54  };
55 
57  virtual StatusCode initialize(const IRndmGen::Param& par) = 0;
59  virtual StatusCode finalize() = 0;
61  virtual const InterfaceID& type() const = 0;
63  virtual long ID() const = 0;
65  virtual const IRndmGen::Param* parameters() const = 0;
67  virtual double shoot() const = 0;
74  virtual StatusCode shootArray( std::vector<double>& array, long howmany, long start = 0) const = 0;
75 
77  virtual ~IRndmGen() {}
78 
79 };
80 
81 #endif // GAUDIKERNEL_IRNDMGEN_H
virtual const InterfaceID & type() const
Parameter's type.
Definition: IRndmGen.h:51
Definition of a interface for a generic random number generators.
Definition: IRndmGen.h:36
Interface ID class.
Definition: IInterface.h:55
virtual ~Param()
Standard Destructor.
Definition: IRndmGen.h:49
virtual ~IRndmGen()
Virtual destructor.
Definition: IRndmGen.h:77
string type
Definition: gaudirun.py:126
const InterfaceID m_type
Type of the generator.
Definition: IRndmGen.h:44
This class is used for returning status codes from appropriate routines.
Definition: StatusCode.h:30
Definition of the basic interface.
Definition: IInterface.h:160
#define DeclareInterfaceID(name, major, minor)
Macro to declare the interface ID when using the new mechanism of extending and implementing interfac...
Definition: IInterface.h:23
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Param(const InterfaceID &type=IID_IRndmFlat)
Standard constructor.
Definition: IRndmGen.h:47
#define GAUDI_API
Definition: Kernel.h:108
tuple start
Definition: IOTest.py:88