1 #ifndef __JDETECTOR__JMODULEMAPPER__
2 #define __JDETECTOR__JMODULEMAPPER__
18 namespace JDETECTOR {}
19 namespace JPP {
using namespace JDETECTOR; }
34 template<
class JAttributes_t>
37 JAttributes_t& attributes);
65 template<
class JAttributes_t>
80 static JAttributes_t attributes;
160 template<
class JAttributes_t = JNullType>
211 template<
class JMatch_t>
230 template<
class JMatch_t>
260 template<
class JMatch_t>
265 zmap.resize(detector.size());
271 for (
int i = 0; i != (int) detector.size(); ++i) {
272 for (
int j = i; ++j != (int) detector.size(); ) {
273 if (match(detector[i], detector[j])) {
JModuleAttributes< JAttributes_t > moduleattributes_type
Type definition of module data.
void configure(JMatch_t match)
Configure this module mapper.
Data structure for a composite optical module.
JModuleMapper(const JModuleRouter &router, JMatch_t match)
Constructor.
JMaximalDistance(const double Dmax_m)
Constructor.
Router for direct addressing of module data in detector data structure.
JModuleAttributes(const int index, const JModule &first, const JModule &second)
Constructor.
JModuleMapper(const JDetector &detector, JMatch_t match)
Constructor.
JModuleAttributes()
Default constructor.
double getDmax() const
Get maximal distance.
JTOOLS::JRouter< JModuleAddress > router
double getDistance(const JVector3D &pos) const
Get distance to point.
void setAttributes< JNullType >(const JModule &first, const JModule &second, JNullType &attributes)
Template specialisation to set no attributes for the default empty object.
Data structure for detector geometry and calibration.
std::vector< moduleattributes_type > container_type
Type definition of a list with module data.
Data structure for module address and module attributes.
JModuleMapper(const JDetector &detector)
Constructor.
int first
index of module in detector data structure
Auxiliary class to match modules according maximal distance.
Auxiliary class for no type definition.
static const JAttributes_t & getAttributes(const JModule &first, const JModule &second)
Get module attributes.
Address of module in detector data structure.
const container_type & getList(const JObjectID &id) const
Get list with module data matching given module.
void setAttributes(const JModule &first, const JModule &second, JAttributes_t &attributes)
Template method to set module attributes.
Direct access to module in detector data structure.
const JClass_t & getReference() const
Get reference to object.
JModuleMapper(const JModuleRouter &router)
Constructor.
Mapper for directly addressing of associated modules in the detector data structure.
Auxiliary class for object identification.
const JModuleAddress & getAddress(const JObjectID &id) const
Get address of module.
bool operator()(const JModule &first, const JModule &second) const
Test whether two module match.
std::vector< container_type > zmap