1#ifndef __JDETECTOR__JMODULEROUTER__
2#define __JDETECTOR__JMODULEROUTER__
56 for (
const_iterator module = detector.begin(); module != detector.end(); ++module) {
57 router.put(module->getID(), JModuleAddress(std::distance(detector.begin(), module)));
81 return router.get(
id.getID());
105 return router.has(
id.getID());
129 return hasModule(
id.getID()) &&
id.getPMTAddress() >= 0 &&
id.getPMTAddress() < (int)
getModule(
id.getID()).size();
Data structure for detector geometry and calibration.
Address of module in detector data structure.
int first
index of module in detector data structure
Router for direct addressing of module data in detector data structure.
JDetector::const_iterator const_iterator
JReference< const JDetector > JReference_t
JModuleRouter(const JDetector &detector)
Constructor.
const JPMT & getPMT(const JPMTIdentifier &id) const
Get PMT parameters.
bool hasPMT(const JPMTIdentifier &id) const
Has PMT.
bool hasModule(const JObjectID &id) const
Has module.
const int getIndex(const JObjectID &id) const
Get index of module.
JTOOLS::JRouter< JModuleAddress > router
const JModuleAddress & getAddress(const JObjectID &id) const
Get address of module.
const JModuleRouter & getModuleRouter() const
Get module router.
const JModule & getModule(const JObjectID &id) const
Get module parameters.
JUTMPosition getUTMPosition(const JObjectID &id) const
Get UTM position of given module identifier.
Data structure for a composite optical module.
const JPMT & getPMT(const int index) const
Get PMT.
Data structure for PMT geometry, calibration and status.
Auxiliary class for object identification.
The template JReference class can be used to reference an object.
const JClass_t & getReference() const
Get reference to object.
Data structure for UTM position.
file Auxiliary data structures and methods for detector calibration.
JPosition3D getPosition(const JModule &first, const JModule &second)
Get position to go from first to second module.
const JObjectID & getUndefinedObjectID()
Get undefined object identifier.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).