CLHEP VERSION Reference Documentation
   
CLHEP Home Page     CLHEP Documentation     CLHEP Bug Reports

Random/CLHEP/Random/engineIDulong.h
Go to the documentation of this file.
1// $Id
2// -*- C++ -*-
3//
4// -----------------------------------------------------------------------
5// HEP Random
6// --- engineIDulong ---
7// function header file
8// -----------------------------------------------------------------------
9
10// Class generating new engines from streamed saves.
11
12// =======================================================================
13// M Fischler - Created: Mar. 8, 2005
14// =======================================================================
15
16#ifndef engineIDulong_h
17#define engineIDulong_h 1
18
19namespace CLHEP {
20
21unsigned long crc32ul(const std::string & s);
22
23template <class E>
24unsigned long engineIDulong() {
25 static unsigned long id = crc32ul(E::engineName());
26 return id;
27}
28
29} // namespace CLHEP
30
31#ifdef ENABLE_BACKWARDS_COMPATIBILITY
32// backwards compatibility will be enabled ONLY in CLHEP 1.9
33using namespace CLHEP;
34#endif
35
36
37#endif
38
unsigned long crc32ul(const std::string &s)
unsigned long engineIDulong()