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

RandBit.cc
Go to the documentation of this file.
1 // $Id: RandBit.cc,v 1.6 2010/06/16 17:24:53 garren Exp $
2 // -*- C++ -*-
3 //
4 // -----------------------------------------------------------------------
5 // HEP Random
6 // --- RandBit ---
7 // class implementation file
8 // -----------------------------------------------------------------------
9 // This file is part of Geant4 (simulation toolkit for HEP).
10 
11 // =======================================================================
12 // M Fischler - Created from RandFlat.cc, deleting almost all the content
13 // since inheritance takes care of it. 2/15/00
14 // M Fischler - put and get to/from streams 12/10/04
15 // =======================================================================
16 
17 #include "CLHEP/Random/defs.h"
18 #include "CLHEP/Random/RandBit.h"
19 #include <string>
20 
21 namespace CLHEP {
22 
23 std::string RandBit::name() const {return "RandBit";}
24 
26 }
27 
28 std::ostream & RandBit::put ( std::ostream & os ) const {
29  os << " " << name() << "\n";
30  RandFlat::put(os);
31  return os;
32 }
33 
34 std::istream & RandBit::get ( std::istream & is ) {
35  std::string inName;
36  is >> inName;
37  if (inName != name()) {
38  is.clear(std::ios::badbit | is.rdstate());
39  std::cerr << "Mismatch when expecting to read state of a "
40  << name() << " distribution\n"
41  << "Name found was " << inName
42  << "\nistream is left in the badbit state\n";
43  return is;
44  }
46  return is;
47 }
48 
49 } // namespace CLHEP
50 
CLHEP::RandBit::~RandBit
virtual ~RandBit()
Definition: RandBit.cc:25
CLHEP::RandFlat::get
std::istream & get(std::istream &is)
Definition: RandFlat.cc:187
is
HepRotation and so forth isNear() norm2() rectify() static Rotation row1 row4(To avoid bloat in the code pulled in for programs which don 't use all these features, we split the implementation .cc files. Only isNear() goes into the original Rotation.cc) --------------------------------------- HepAxisAngle and HepEulerAngles classes --------------------------------------- These classes are very useful and simple structures for holding the result of a nice intuituve decomposition of a rotation there is no longer much content in the distinct ZOOM PhysicsVectors library The only content left in the library is the object files representing the various Exception objects When we build the CLHEP classes for the ZOOM we will set up so as to use ZOOM SpaceVector is(but we can disable namespace usage and most of our users do so at this point). What I do is leave Hep3Vector in the global namespace
CLHEP::RandFlat::put
std::ostream & put(std::ostream &os) const
Definition: RandFlat.cc:156
CLHEP::RandBit::get
std::istream & get(std::istream &is)
Definition: RandBit.cc:34
CLHEP
Definition: ClhepVersion.h:13
CLHEP::RandBit::name
std::string name() const
Definition: RandBit.cc:23
CLHEP::RandBit::put
std::ostream & put(std::ostream &os) const
Definition: RandBit.cc:28