Celeritas 0.6.0-129+develop.846910afa
Loading...
Searching...
No Matches
Public Member Functions | List of all members
celeritas::VolumeParams Class Reference

Define and manage a hierarchy of volumes and instances thereof. More...

#include <VolumeParams.hh>

Public Types

Type aliases
using VolumeMap = LabelIdMultiMap< VolumeId >
 
using VolInstMap = LabelIdMultiMap< VolumeInstanceId >
 
using SpanVolInst = Span< VolumeInstanceId const >
 
VolumeVisitor template interface
using VolumeRef = VolumeId
 
using VolumeInstanceRef = VolumeInstanceId
 

Public Member Functions

 VolumeParams (inp::Volumes const &)
 Construct from input.
 
 VolumeParams ()
 Construct with no volumes, often for unit testing.
 
bool empty () const
 Empty if no volumes are present (e.g., ORANGE debugging)
 
VolumeId world () const
 World volume.
 
LevelId::size_type depth () const
 Depth of the volume DAG (a world without children is depth zero)
 
VolumeId::size_type num_volumes () const
 Number of volumes.
 
VolumeInstanceId::size_type num_volume_instances () const
 Number of volume instances.
 
VolumeMap constvolume_labels () const
 Get volume metadata.
 
VolInstMap constvolume_instance_labels () const
 Get volume instance metadata.
 
SpanVolInst parents (VolumeId v_id) const
 Find all instances of a volume (incoming edges).
 
SpanVolInst children (VolumeId v_id) const
 Get the list of daughter volumes (outgoing edges).
 
GeoMatId material (VolumeId v_id) const
 Get the geometry material of a volume.
 
VolumeId volume (VolumeInstanceId vi_id) const
 Get the volume being instantiated (outgoing node).
 

Detailed Description

Define and manage a hierarchy of volumes and instances thereof.

See the introduction to the Geometry API section (api_geometry in user manual) for a detailed description of volumes in the detector geometry description. This class abstracts the graph of user-defined volumes, relating nodes (VolumeId, aka logical volume) to edges (VolumeInstanceId, aka physical volume) and providing the means to determine the path (VolumeUniqueInstanceId, aka touchable history) of a track state. In conjunction with GeantGeoParams this allows conversion between the Celeritas geometry implementation and the Geant4 geometry navigation.

Construction requirements:


The documentation for this class was generated from the following files: