Gaudi Framework, version v24r2

Home   Generated: Wed Dec 4 2013
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
RndmGen.cpp
Go to the documentation of this file.
1 //====================================================================
2 // Random RndmGen class implementation
3 //--------------------------------------------------------------------
4 //
5 // Package : Gaudi/RndmGen ( The LHCb Offline System)
6 // Author : M.Frank
7 // History :
8 // +---------+----------------------------------------------+--------+
9 // | Date | Comment | Who |
10 // +---------+----------------------------------------------+--------+
11 // | 21/11/99| Initial version. | MF |
12 // +---------+----------------------------------------------+--------+
13 //====================================================================
14 #define GAUDI_RANDOMGENSVC_RNDMGEN_CPP
15 
16 #include <cfloat>
19 #include "RndmGen.h"
20 
22 RndmGen::RndmGen(IInterface* engine) : m_params(0), m_engine(0) {
23  if ( 0 != engine ) {
24  engine->queryInterface(IRndmEngine::interfaceID(), pp_cast<void>(&m_engine)).ignore();
25  }
26 }
27 
30  if ( m_engine ) m_engine->release();
31  m_engine = 0;
32  if ( m_params ) delete m_params;
33  m_params = 0;
34 }
35 
38  m_params = par.clone();
40 }
41 
44  return StatusCode::SUCCESS;
45 }
46 
48 double RndmGen::shoot() const {
49  return DBL_MAX;
50 }
51 
54  if ( 0 != m_engine ) {
55  long cnt = start;
56  array.resize(start+howmany);
57  for ( long i = start, num = start+howmany; i < num; i++ ) {
58  array[cnt++] = shoot();
59  }
60  return StatusCode::SUCCESS;
61  }
62  return StatusCode::FAILURE;
63 }
64 

Generated at Wed Dec 4 2013 14:33:11 for Gaudi Framework, version v24r2 by Doxygen version 1.8.2 written by Dimitri van Heesch, © 1997-2004