]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TEvtGen/EvtGenBase/EvtRandomEngine.hh
Completely reengineered version of CMake build system (Johny)
[u/mrichter/AliRoot.git] / TEvtGen / EvtGenBase / EvtRandomEngine.hh
CommitLineData
da0e9ce3 1//--------------------------------------------------------------------------
2//
3// Environment:
4// This software is part of the EvtGen package developed jointly
5// for the BaBar and CLEO collaborations. If you use all or part
6// of it, please give an appropriate acknowledgement.
7//
8// Copyright Information: See EvtGen/COPYRIGHT
9// Copyright (C) 1998 Caltech, UCSB
10//
11// Module: EvtGen/EvtRandom.hh
12//
13// Description:Class to generate random numbers. Single member
14// function random is expected to return a random
15// number in the range ]0..1[.
16//
17// Modification history:
18//
19// RYD December 25, 1999 Module created
20// RYD October 2, 2006 Converted to a pure interface class
21//
22//------------------------------------------------------------------------
23
24#ifndef EVTRANDOMENGINE_HH
25#define EVTRANDOMENGINE_HH
26
27#include <TRandom.h>
28
29class EvtRandomEngine{
30
31public:
32
33 virtual ~EvtRandomEngine() {};
34
35 virtual double random()=0;
36
37private:
38
39};
40
41//define class for generating random numbers (I put this in place of the commented part)
42class EvtNUMRandomEngine:public EvtRandomEngine{
43public:
44 double random(){return gRandom->Rndm();}
45};
46
47
48//old lines: those are in the macro testEvtGen.cc
49/*
50//define class for generating random numbers
51class EvtCLHEPRandomEngine:public EvtRandomEngine{
52public:
53 double random();
54};
55
56#ifdef NOCLHEPNAMESPACE
57namespace CLHEP {
58typedef HepJamesRandom HepJamesRandom ;
59}
60#endif
61
62double EvtCLHEPRandomEngine::random(){
63 static CLHEP::HepJamesRandom randengine;
64 return randengine.flat();
65}
66*/
67
68#endif
69
70