EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
CbmMCEventHeader.cxx
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file CbmMCEventHeader.cxx
1 
9 #include "CbmMCEventHeader.h"
10 #include "FairRootManager.h"
11 
12 #include <iostream>
13 using std::cout;
14 using std::endl;
15 
16 // ----- Default constructor ------------------------------------------
19  fPhi (0.)
20 {
21 }
22 // ------------------------------------------------------------------------
23 
24 
25 
26 // ----- Constructor with run identifier ------------------------------
28  : FairMCEventHeader(runId),
29  fPhi (0.)
30 {
31 }
32 // ------------------------------------------------------------------------
33 
34 
35 
36 // ----- Standard constructor -----------------------------------------
37 CbmMCEventHeader::CbmMCEventHeader(UInt_t runId, Int_t iEvent,
38  Double_t x, Double_t y, Double_t z, Double_t t,
39  Double_t b, Double_t phi, Int_t nPrim)
40  : FairMCEventHeader(iEvent, x, y, z, t, b, nPrim),
41  fPhi(phi)
42 {
43 }
44 // ------------------------------------------------------------------------
45 
46 
47 
48 // ----- Destructor ---------------------------------------------------
50 // ------------------------------------------------------------------------
51 
52 
53 
54 // ----- Public method Reset ------------------------------------------
57  fPhi = 0.;
58 }
59 // ------------------------------------------------------------------------
60 
62 {
63  cout <<"Register CbmMCEventHeader."<<endl;
64  // For derived classes there has to be no dot at the end of the
65  // branch name which is registered. Don't know why.
66  FairRootManager::Instance()->Register("MCEventHeader.", "Event", this , kTRUE);
67 }
68