14 #ifndef DD4hep_GEOMETRY_VOLUMEMANAGER_H
15 #define DD4hep_GEOMETRY_VOLUMEMANAGER_H
24 #include "TGeoMatrix.h"
35 class VolumeManagerContext;
36 class VolumeManagerObject;
86 typedef std::map<VolumeID, VolumeManager>
Managers;
87 typedef std::map<DetElement, VolumeManager>
Detectors;
88 typedef std::map<VolumeID, VolumeManagerContext*>
Volumes;
VolumeManager addSubdetector(DetElement detector, Readout ro)
Add a new Volume manager section according to a new subdetector.
bool adoptPlacement(Context *context)
Register physical volume with the manager (normally: section manager)
Handle class holding a placed volume (also called physical volume)
const char * name() const
Access the object name (or "" if not supported by the object)
VolumeManagerObject Object
Some useful Container abbreviations used by the VolumeManager.
PlacedVolume lookupPlacement(VolumeID volume_id) const
Lookup a physical (placed) volume identified by its 64 bit hit ID.
Object & _data() const
Additional data accessor.
VolumeManager & operator=(const VolumeManager &m)
Assignment operator.
This structure describes the cached data for one placement held by the volume manager.
IDDescriptor idSpec() const
Access IDDescription structure.
Handle to the implementation of the readout structure of a subdetector.
T * ptr() const
Access to the held object.
std::ostream & operator<<(std::ostream &os, const VolumeManager &m)
Enable printouts for debugging.
DD4hep::Geometry::DetElement DetElement
PlacedVolume::VolIDs VolIDs
This structure describes the internal data of the volume manager object.
VolumeManager(const VolumeManager &e)
Constructor to be used when reading the already parsed object.
VolumeManager()
Default constructor.
VolumeManagerContext Context
VolumeManager subdetector(VolumeID id) const
Access the volume manager by cell id.
std::map< VolumeID, VolumeManager > Managers
DetElement lookupDetElement(VolumeID volume_id) const
Lookup the closest subdetector detector element in the hierarchy according to a contained 64 bit hit ...
DetElement lookupDetector(VolumeID volume_id) const
Lookup a top level subdetector detector element according to a contained 64 bit hit ID...
Context * lookupContext(VolumeID volume_id) const
Lookup the context, which belongs to a registered physical volume.
Handle class describing a detector element.
Class to support the retrieval of detector elements and volumes given a valid identifier.
Handle: a templated class like a shared pointer, which allows specialized access to tgeometry objects...
const TGeoMatrix & worldTransformation(VolumeID volume_id) const
Access the transformation of a physical volume to the world coordinate system.
DD4hep::VolumeID VolumeID
std::map< DetElement, VolumeManager > Detectors
T * m_element
Single and only data member: Reference to the actual element.
DetElement detector() const
Access the top level detector element.
Class implementing the ID encoding of detector response.
std::map< VolumeID, VolumeManagerContext * > Volumes
std::map< TGeoNode *, Context * > PhysVolumes