#include "IFieldMapDescription.hxx" //#include "IFieldMap.hxx" #include #include #include #include #include #include using std::string; namespace { std::ostream& operator<<(std::ostream& stream,const TVector3& vect){ stream<<"("<AsString()<<"): " << std::endl; TROOT::IncreaseDirLevel(); std::string indent(TROOT::GetDirLevel(),' '); if(fScaling!=1.0) { std::cout<x() <<", "<y() <<", "<z()<<")" << std::endl; } if(fRotation){ double angle = 0; TVector3 axis; fRotation->AngleAxis(angle,axis); std::cout< bad_checksums; for(PathList::const_iterator i_path=fFieldmapPaths.begin(); i_path!=fFieldmapPaths.end();++i_path){ TString path = *i_path; TString newpath = path; gSystem->ExpandPathName(newpath); if (newpath==path) continue; for (int icheck = 0; icheck<=1; icheck++){ TString fullfilename=newpath; if (icheck==0) fullfilename+="/"+basename; else fullfilename+="/"+dirname+"/"+basename; if(!gSystem->AccessPathName(fullfilename.Data())){ TMD5* checksum=TMD5::FileChecksum(fullfilename.Data()); if(string(checksum->AsString()) == fCheckSum->AsString()){ return string(fullfilename.Data()); }else{ bad_checksums.push_back(fullfilename); } } } } COMETError("Unable to find fieldmap file, '"<::const_iterator i_path=bad_checksums.begin(); i_path!=bad_checksums.end();++i_path){ COMETError(" "<<*i_path); } } return ""; } void COMET::IFieldMapDescription::PrintFieldmapSearchPaths(bool use_error_stream){ SetupFilePath(); for(PathList::const_iterator i_path=fFieldmapPaths.begin(); i_path!=fFieldmapPaths.end();++i_path){ if(use_error_stream) COMETError(" "<<*i_path); else COMETLog (" "<<*i_path); } }