GEMC  1.8
Geant4 Monte-Carlo Framework
MPHBaseClass.cc
Go to the documentation of this file.
1 // %%%%%%%%%%%%%
2 // gemc headers
3 // %%%%%%%%%%%%%
4 #include "MPHBaseClass.h"
5 
6 using namespace std;
7 
8 MPHBaseClass* GetMPHClass (map<string, MPHB_Factory> *MProcessHit_Map, string HCname)
9 {
10  if(MProcessHit_Map->find(HCname) == MProcessHit_Map->end())
11  {
12  cout << endl << endl << " >>> WARNING: " << HCname << " NOT FOUND IN ProcessHit Map." << endl;
13  return NULL;
14  }
15 
16  return (*MProcessHit_Map)[HCname]();
17 }
STL namespace.
MPHBaseClass * GetMPHClass(map< string, MPHB_Factory > *MProcessHit_Map, string HCname)
Return MPHBaseClass from the Hit Process Map.
Definition: MPHBaseClass.cc:8