Changeset 1340 for trunk/source/digits_hits/scorer/src/G4PSEnergyDeposit.cc
- Timestamp:
- Nov 5, 2010, 3:45:55 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/digits_hits/scorer/src/G4PSEnergyDeposit.cc
r1337 r1340 25 25 // 26 26 // 27 // $Id: G4PSEnergyDeposit.cc,v 1. 1 2007/07/11 01:31:02 asaimExp $28 // GEANT4 tag $Name: geant4-09-04-beta-01$27 // $Id: G4PSEnergyDeposit.cc,v 1.3 2010/07/22 07:23:45 taso Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // G4PSEnergyDeposit … … 36 36 // 37 37 // Created: 2005-11-14 Tsukasa ASO, Akinori Kimura. 38 // 2010-07-22 Introduce Unit specification. 38 39 // 39 40 /////////////////////////////////////////////////////////////////////////////// 40 41 41 42 G4PSEnergyDeposit::G4PSEnergyDeposit(G4String name, G4int depth) 43 :G4VPrimitiveScorer(name,depth),HCID(-1) 44 { 45 SetUnit("MeV"); 46 } 47 48 G4PSEnergyDeposit::G4PSEnergyDeposit(G4String name, const G4String& unit, 49 G4int depth) 42 50 :G4VPrimitiveScorer(name,depth),HCID(-1) 43 {;} 51 { 52 SetUnit(unit); 53 } 44 54 45 55 G4PSEnergyDeposit::~G4PSEnergyDeposit() … … 83 93 for(; itr != EvtMap->GetMap()->end(); itr++) { 84 94 G4cout << " copy no.: " << itr->first 85 << " energy deposit: " << G4BestUnit(*(itr->second),"Energy") 95 << " energy deposit: " 96 << *(itr->second)/GetUnitValue() 97 << " [" << GetUnit()<<"]" 86 98 << G4endl; 87 99 } 88 100 } 101 102 void G4PSEnergyDeposit::SetUnit(const G4String& unit) 103 { 104 CheckAndSetUnit(unit,"Energy"); 105 }
Note: See TracChangeset
for help on using the changeset viewer.