9 constexpr
double HIVENUMBERS_BUFFER_SIZE = 1000;
21 : m_buffer_index( 0 ), m_buffer_size( HIVENUMBERS_BUFFER_SIZE ), m_generator( copy.m_generator ) {
28 : m_buffer_index( 0 ), m_buffer_size( HIVENUMBERS_BUFFER_SIZE ), m_generator( 0 ) {
31 if ( !status.
isSuccess() ) {
throw GaudiException(
"Initialization failed !",
"HiveRndm::HiveNumbers", status ); }
39 if ( svc.
isValid() && 0 == m_generator ) {
49 if ( 0 != m_generator ) {
50 m_generator->finalize().
ignore();
51 m_generator->release();
57 #if !defined( GAUDI_V22_API ) || defined( G22_NEW_SVCLOCATOR ) 60 : m_buffer_index( 0 ), m_buffer_size( HIVENUMBERS_BUFFER_SIZE ), m_generator( 0 ) {
62 if ( !status.
isSuccess() ) {
throw GaudiException(
"Initialization failed !",
"HiveRndm::HiveNumbers", status ); }
const unsigned int m_buffer_size
virtual StatusCode finalize()
Finalization.
Define general base for Gaudi exception.
tbb::spin_rw_mutex_v3 HiveNumbersMutex
virtual StatusCode generator(const IRndmGen::Param &par, IRndmGen *&refpGen)=0
Add a Generator factory.
bool isValid() const
Allow for check if smart pointer is valid.
constexpr static const auto SUCCESS
std::vector< double > m_buffer
IRndmGen * m_generator
Pointer to random number generator.
Random Generator service interface definition Definition of a interface for a service to access rando...
This class is used for returning status codes from appropriate routines.
virtual ~HiveNumbers()
Standard destructor.
const StatusCode & ignore() const
Ignore/check StatusCode.
virtual StatusCode initialize(const SmartIF< IRndmGenSvc > &svc, const IRndmGen::Param &par)
Initialization.
constexpr static const auto FAILURE
virtual unsigned long addRef()=0
Increment the reference count of Interface instance.
HiveNumbers()
Standard constructor.
static HiveNumbersMutex m_genMutex