Writes geometry configuration information into art runs. More...
Classes | |
struct | Config |
Service configuration. More... | |
Public Types | |
using | Parameters = art::ServiceTable< Config > |
Public Member Functions | |
GeometryGArConfigurationWriter (Parameters const &) | |
Constructor: gets its configuration and does nothing with it. More... | |
Public Member Functions inherited from art::ProducingService | |
ProducingService () | |
virtual | ~ProducingService () noexcept |
void | setModuleDescription (ModuleDescription const &) |
void | registerCallbacks (ProducingServiceSignals &) |
void | doPostReadRun (RunPrincipal &) |
void | doPostReadSubRun (SubRunPrincipal &) |
void | doPostReadEvent (EventPrincipal &) |
Private Types | |
using | InfoPtr_t = std::unique_ptr< gar::sumdata::GeometryConfigurationInfo > |
Alias for the pointer to the data product object to be put into the run. More... | |
Private Member Functions | |
virtual void | postReadRun (art::Run &run) override |
Writes the information from the service configuration into the run . More... | |
InfoPtr_t | loadInfo (art::Run &run) const |
Loads the geometry information from the run (either directly or legacy). More... | |
InfoPtr_t | readGeometryInformation (art::Run &run) const |
Reads geometry information from the run (returns null pointer if none). More... | |
InfoPtr_t | makeInfoFromRunData (art::Run &run) const |
gar::sumdata::RunData const * | readRunData (art::Run &run) const |
Returns a pointer to the sumdata::RunData in run (nullptr if none). More... | |
Static Private Member Functions | |
static InfoPtr_t | extractInfoFromGeometry () |
Creates configuration information based on the current Geometry service. More... | |
static InfoPtr_t | convertRunDataToGeometryInformation (gar::sumdata::RunData const &data) |
Converts the legacy data into geometry configuration information. More... | |
static InfoPtr_t | makeInfoPtr (gar::sumdata::GeometryConfigurationInfo const &info) |
Alias to std::make_unique<sumdata::GeometryConfigurationInfo> . More... | |
Additional Inherited Members | |
Static Public Attributes inherited from art::ProducingService | |
static constexpr bool | service_handle_allowed {false} |
Writes geometry configuration information into art runs.
This service is part of the mandatory version check of gar::geo::Geometry
service. It does not require any special configuration, but it must be listed in the configuration in order for Geometry
to work:
The configuration check is described in the documentation of gar::geo::Geometry
service.
The service guarantees that configuration information of type sumdata::GeometryConfigurationInfo
is present into the run, accessible with an input tag GeometryGArConfigurationWriter
:
sumdata::RunData
data product, a reduced version of the configuration information is created from the information in that data product (the first one, if multiple are present)sumdata::GeometryConfigurationInfo
form nor in the legacy sumdata::RunData
form, information is put together based on the current configuration of the Geometry
service.Geometry
service (for obtaining the current configuration to put into the event) Definition at line 83 of file GeometryGArConfigurationWriter_service.cc.
|
private |
Alias for the pointer to the data product object to be put into the run.
Definition at line 105 of file GeometryGArConfigurationWriter_service.cc.
Definition at line 92 of file GeometryGArConfigurationWriter_service.cc.
gar::geo::GeometryGArConfigurationWriter::GeometryGArConfigurationWriter | ( | Parameters const & | ) |
Constructor: gets its configuration and does nothing with it.
Definition at line 137 of file GeometryGArConfigurationWriter_service.cc.
|
staticprivate |
Converts the legacy data
into geometry configuration information.
Definition at line 221 of file GeometryGArConfigurationWriter_service.cc.
|
staticprivate |
Creates configuration information based on the current Geometry
service.
Definition at line 176 of file GeometryGArConfigurationWriter_service.cc.
|
private |
Loads the geometry information from the run
(either directly or legacy).
Definition at line 156 of file GeometryGArConfigurationWriter_service.cc.
|
private |
Upgrades legacy sumdata::RunData
in run
to geometry information (returns null pointer if no legacy information is present).
Definition at line 202 of file GeometryGArConfigurationWriter_service.cc.
|
inlinestaticprivate |
Alias to std::make_unique<sumdata::GeometryConfigurationInfo>
.
Definition at line 128 of file GeometryGArConfigurationWriter_service.cc.
|
overrideprivatevirtual |
Writes the information from the service configuration into the run
.
Reimplemented from art::ProducingService.
Definition at line 144 of file GeometryGArConfigurationWriter_service.cc.
|
private |
Reads geometry information from the run (returns null pointer if none).
Definition at line 189 of file GeometryGArConfigurationWriter_service.cc.
|
private |
Returns a pointer to the sumdata::RunData
in run
(nullptr if none).
Definition at line 212 of file GeometryGArConfigurationWriter_service.cc.