ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
ActsPlugins::TGeoLayerBuilder Class Reference

This parses the gGeoManager and looks for a defined combination of volume with contained sensitive detector element. More...

#include <ActsPlugins/Root/TGeoLayerBuilder.hpp>

Inheritance diagram for ActsPlugins::TGeoLayerBuilder:
[legend]
Collaboration diagram for ActsPlugins::TGeoLayerBuilder:
[legend]

Classes

struct  Config
 nested configuration struct for steering of the layer builder More...
struct  LayerConfig
 Helper config structs for volume parsing. More...

Public Types

using ElementFactory
 Type alias for detector element factory function.

Public Member Functions

 TGeoLayerBuilder (const Config &config, std::unique_ptr< const Acts::Logger > logger=Acts::getDefaultLogger("TGeoLayerBuilder", Acts::Logging::INFO))
 Constructor.
 ~TGeoLayerBuilder () override
 Destructor.
const Acts::LayerVector centralLayers (const Acts::GeometryContext &gctx) const final
 LayerBuilder interface method - returning the central layers.
const std::vector< std::shared_ptr< const TGeoDetectorElement > > & detectorElements () const
 Return the created detector elements.
Config getConfiguration () const
 Get the configuration object.
const std::string & identification () const final
 Name identification.
const Acts::LayerVector negativeLayers (const Acts::GeometryContext &gctx) const final
 LayerBuilder interface method - returning the layers at negative side.
const Acts::LayerVector positiveLayers (const Acts::GeometryContext &gctx) const final
 LayerBuilder interface method - returning the layers at positive side.
void setConfiguration (const Config &config)
 Set the configuration object.
void setLogger (std::unique_ptr< const Acts::Logger > newLogger)
 Set logging instance.
Public Member Functions inherited from Acts::ILayerBuilder
virtual ~ILayerBuilder ()=default
 Virtual destructor.

Static Public Member Functions

static std::shared_ptr< TGeoDetectorElementdefaultElementFactory (const TGeoDetectorElement::Identifier &identifier, const TGeoNode &tGeoNode, const TGeoMatrix &tGeoMatrix, const std::string &axes, double scalor, std::shared_ptr< const Acts::ISurfaceMaterial > material)
 Default factory function for creating TGeoDetectorElement instances.

Detailed Description

This parses the gGeoManager and looks for a defined combination of volume with contained sensitive detector element.

The association is done by matching the names of the TGeoNode / TGeoVolume to the search string.

The parsing can be restricted to a given parse volume (in r and z), and given some splitting parameters the surfaces can be automatically split into layers.

Member Typedef Documentation

◆ ElementFactory

Initial value:
std::function<std::shared_ptr<TGeoDetectorElement>(
const TGeoDetectorElement::Identifier&, const TGeoNode&,
const TGeoMatrix& tGeoMatrix, const std::string& axes, double scalor,
std::shared_ptr<const Acts::ISurfaceMaterial> material)>
identifier_type Identifier
Definition TGeoDetectorElement.hpp:47

Type alias for detector element factory function.

Constructor & Destructor Documentation

◆ TGeoLayerBuilder()

ActsPlugins::TGeoLayerBuilder::TGeoLayerBuilder ( const Config & config,
std::unique_ptr< const Acts::Logger > logger = Acts::getDefaultLogger("TGeoLayerBuilder", Acts::Logging::INFO) )
explicit

Constructor.

Parameters
configis the configuration struct
loggerthe local logging instance

◆ ~TGeoLayerBuilder()

ActsPlugins::TGeoLayerBuilder::~TGeoLayerBuilder ( )
override

Destructor.

Member Function Documentation

◆ centralLayers()

const Acts::LayerVector ActsPlugins::TGeoLayerBuilder::centralLayers ( const Acts::GeometryContext & gctx) const
finalvirtual

LayerBuilder interface method - returning the central layers.

Parameters
gctxthe geometry context for this build call
Returns
Vector of central layers

Implements Acts::ILayerBuilder.

◆ defaultElementFactory()

std::shared_ptr< TGeoDetectorElement > ActsPlugins::TGeoLayerBuilder::defaultElementFactory ( const TGeoDetectorElement::Identifier & identifier,
const TGeoNode & tGeoNode,
const TGeoMatrix & tGeoMatrix,
const std::string & axes,
double scalor,
std::shared_ptr< const Acts::ISurfaceMaterial > material )
static

Default factory function for creating TGeoDetectorElement instances.

Parameters
identifierDetector element identifier
tGeoNodeROOT geometry node
tGeoMatrixROOT geometry transformation matrix
axesString describing the axes configuration
scalorScaling factor for geometry transformations
materialSurface material to be assigned to the element
Returns
Shared pointer to the created TGeoDetectorElement

◆ negativeLayers()

const Acts::LayerVector ActsPlugins::TGeoLayerBuilder::negativeLayers ( const Acts::GeometryContext & gctx) const
finalvirtual

LayerBuilder interface method - returning the layers at negative side.

Parameters
gctxthe geometry context for this build call
Returns
Vector of negative-side layers

Implements Acts::ILayerBuilder.

◆ positiveLayers()

const Acts::LayerVector ActsPlugins::TGeoLayerBuilder::positiveLayers ( const Acts::GeometryContext & gctx) const
finalvirtual

LayerBuilder interface method - returning the layers at positive side.

Parameters
gctxthe geometry context for this build call
Returns
Vector of positive-side layers

Implements Acts::ILayerBuilder.

◆ setConfiguration()

void ActsPlugins::TGeoLayerBuilder::setConfiguration ( const Config & config)

Set the configuration object.

Parameters
configis the configuration struct

◆ setLogger()

void ActsPlugins::TGeoLayerBuilder::setLogger ( std::unique_ptr< const Acts::Logger > newLogger)

Set logging instance.

Parameters
newLoggerLogger instance to use for debug output