5#ifndef TRACKINGTESTEDM_H
6#define TRACKINGTESTEDM_H
26 TrkEDMTestAlg(
const std::string& name, ISvcLocator* pSvcLocator);
49 template <
class COLLECTION>
52 template <
class PRD,
class IDHELPER,
class COLLECTION >
53 void checkPRD(
const PRD* prd,
const IDHELPER* helper,
const COLLECTION& coll);
56 std::pair<const Trk::TrkDetElementBase*, const Trk::TrkDetElementBase*>
getReadoutElements(
const PRD* prd)
const;
58 template <
class IDHELPER,
class PRD>
94 typename T::const_iterator::const_iterator element =
container->begin();
95 typename T::const_iterator::const_iterator lastElement =
container->end();
97 stream <<
"Found container "<<containerName<<
", which has "<<
container->numberOfCollections()<<
" collections (see below)."<<std::endl;
99 ATH_MSG_VERBOSE(
"Found container "<<containerName<<
", which has "<<
container->numberOfCollections()<<
" collections (see below).");
106 stream<<
"Found "<<totalConsituents<<
" constituent objects."<<std::endl;
112 stream<<
"WARNING! Could not find container: "<<containerName<<
"!"<<std::endl;
129 stream <<
"Found container "<<containerName<<
", which has "<<
container->size()
130 <<
" elements (see below)."<<std::endl;
133 <<
" elements (see below).");
139 stream<<
"Found "<<totalConsituents<<
" constituent objects. (size was reported as "<<
container->size()<<
")"<<std::endl;
144 stream<<
"WARNING! Could not find container: "<<containerName<<
"!"<<std::endl;
160 const std::string& containerLoc = *it;
170 unsigned int numConsituents=0;
172 typename T::const_iterator element =
container->begin();
173 typename T::const_iterator lastElement =
container->end();
175 for ( ; element!=lastElement ; ++element) {
180 stream << std::setprecision(6) << **element<<std::endl;
185 stream<<
"WARNING! Zero pointer!"<<std::endl;
190 return numConsituents;
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_WARNING(x)
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
ServiceHandle< StoreGateSvc > & evtStore()
This is a "hash" representation of an Identifier.
std::pair< const Trk::TrkDetElementBase *, const Trk::TrkDetElementBase * > getReadoutElements(const PRD *prd) const
std::map< std::string, unsigned int > m_numConstObjsFound
void loadAndDumpIdentifiableContainer(const std::string &collectionName, std::ofstream &stream)
void loadAndDumpMultipleContainers(std::vector< std::string > &collectionNames, std::ofstream &stream)
load container of objects, and dump each contained object to MsgStream, and or external file (dependi...
virtual StatusCode runTest()=0
TrkEDMTestAlg(const std::string &name, ISvcLocator *pSvcLocator)
bool testDetectorElement(IdentifierHash idhash, const IDHELPER *helper, const PRD *prd) const
void loadAndDumpContainer(const std::string &collectionName, std::ofstream &stream)
load container of objects, and dump each contained object to MsgStream, and or external file (dependi...
void checkPRD(const PRD *prd, const IDHELPER *helper, const COLLECTION &coll)
std::map< std::string, unsigned int > m_numContsFound
bool m_doDetailedChecks
If true, try to examine the PRDs etc in detail and catch any errors.
void checkPRDCollectionValidity(const COLLECTION &coll)
std::string m_summaryDumpFileName
unsigned int m_eventNum
numbers of event
unsigned int dumpAndTestElements(const T *container, std::ofstream &stream)
unsigned int m_numDetailedWarnings
Count of detailed warning found.
std::ofstream m_summaryFileOutput
This is the base class for all tracking detector elements with read-out relevant information.
bool contains(const std::string &s, const std::string ®x)
does a string contain the substring
Ensure that the ATLAS eigen extensions are properly loaded.