42 #ifdef G4MULTITHREADED
63 #ifdef G4MULTITHREADED
90 G4Random::getTheEngine();
95 if ( dynamic_cast<const CLHEP::HepJamesRandom*>(aNewRNG) ) {
98 if ( dynamic_cast<const CLHEP::MixMaxRng*>(aNewRNG) ) {
101 if ( dynamic_cast<const CLHEP::RanecuEngine*>(aNewRNG) ) {
104 if ( dynamic_cast<const CLHEP::Ranlux64Engine*>(aNewRNG) ) {
107 if ( dynamic_cast<const CLHEP::MTwistEngine*>(aNewRNG) ) {
110 if ( dynamic_cast<const CLHEP::DualRand*>(aNewRNG) ) {
113 if ( dynamic_cast<const CLHEP::RanluxEngine*>(aNewRNG) ) {
116 if ( dynamic_cast<const CLHEP::RanshiEngine*>(aNewRNG) ) {
121 G4Random::setTheEngine( retRNG );
125 msg<<
" Unknown type of RNG Engine - " <<
G4endl
126 <<
" Can cope only with HepJamesRandom, MixMaxRng, Ranecu, Ranlux64, MTwistEngine, DualRand, Ranlux or Ranshi."
128 <<
" Cannot clone this type of RNG engine, as required for this thread" <<
G4endl
129 <<
" Aborting " <<
G4endl;
130 G4Exception(
"G4UserWorkerInitializition::SetupRNGEngine()",
static void * StartThread(void *context)
#define G4THREADJOIN(worker)
std::ostringstream G4ExceptionDescription
virtual void SetupRNGEngine(const CLHEP::HepRandomEngine *aRNGEngine) const
G4UserWorkerThreadInitialization()
virtual G4WorkerRunManager * CreateWorkerRunManager() const
#define G4MUTEX_INITIALIZER
#define G4THREADCREATE(worker, func, arg)
virtual ~G4UserWorkerThreadInitialization()
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
virtual G4Thread * CreateAndStartWorker(G4WorkerThread *workerThreadContext)
virtual void JoinWorker(G4Thread *aThread)