00001 #include "EvtParityC.hh"
00002
00003 std::map<string, double> parityC::_parityCMap_;
00004
00005
00006 void parityC::readParityC(){
00007 string location = getenv("BESEVTGENROOT");
00008 location += "/share/_parityC.list_";
00009
00010 cout<<"The _parity.list_ location is "<<location<<endl;
00011
00012 ifstream file(location.c_str());
00013 string parname;
00014 double pval;
00015 if(file==0){cout<<" parity::readParity: No particle parity list are available"<<endl;abort();}
00016 while(!file.eof()){
00017 file>>parname>>pval;
00018 pair<string, double> prt(parname,pval);
00019
00020
00021
00022 _parityCMap_.insert(prt);
00023 }
00024 }
00025
00026 double parityC::getC(string parname){
00027 double thepar;
00028 thepar = _parityCMap_[parname];
00029
00030 return thepar;
00031 }