Writes geometry configuration information into art runs. More...
Classes | |
struct | Config |
Service configuration. More... | |
Public Types | |
using | Parameters = art::ServiceTable< Config > |
Public Member Functions | |
GeometryConfigurationWriter (Parameters const &) | |
Constructor: gets its configuration and does nothing with it. More... | |
Private Types | |
using | InfoPtr_t = std::unique_ptr< 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 |
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 (sumdata::RunData const &data) |
Converts the legacy data into geometry configuration information. More... | |
static InfoPtr_t | makeInfoPtr (sumdata::GeometryConfigurationInfo const &info) |
Alias to std::make_unique<sumdata::GeometryConfigurationInfo> . More... | |
Writes geometry configuration information into art runs.
This service is part of the mandatory version check of 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 geo::Geometry
service.
The service guarantees that configuration information of type sumdata::GeometryConfigurationInfo
is present into the run, accessible with an input tag GeometryConfigurationWriter
:
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 78 of file GeometryConfigurationWriter_service.cc.
|
private |
Alias for the pointer to the data product object to be put into the run.
Definition at line 102 of file GeometryConfigurationWriter_service.cc.
using geo::GeometryConfigurationWriter::Parameters = art::ServiceTable<Config> |
Definition at line 87 of file GeometryConfigurationWriter_service.cc.
geo::GeometryConfigurationWriter::GeometryConfigurationWriter | ( | Parameters const & | ) |
Constructor: gets its configuration and does nothing with it.
Definition at line 136 of file GeometryConfigurationWriter_service.cc.
|
staticprivate |
Converts the legacy data
into geometry configuration information.
Definition at line 227 of file GeometryConfigurationWriter_service.cc.
|
staticprivate |
Creates configuration information based on the current Geometry
service.
Definition at line 176 of file GeometryConfigurationWriter_service.cc.
|
private |
Loads the geometry information from the run
(either directly or legacy).
Definition at line 155 of file GeometryConfigurationWriter_service.cc.
|
private |
Upgrades legacy sumdata::RunData
in run
to geometry information (returns null pointer if no legacy information is present).
Definition at line 203 of file GeometryConfigurationWriter_service.cc.
|
inlinestaticprivate |
Alias to std::make_unique<sumdata::GeometryConfigurationInfo>
.
Definition at line 126 of file GeometryConfigurationWriter_service.cc.
|
overrideprivatevirtual |
Writes the information from the service configuration into the run
.
Definition at line 143 of file GeometryConfigurationWriter_service.cc.
|
private |
Reads geometry information from the run (returns null pointer if none).
Definition at line 191 of file GeometryConfigurationWriter_service.cc.
|
private |
Returns a pointer to the sumdata::RunData
in run
(nullptr if none).
Definition at line 216 of file GeometryConfigurationWriter_service.cc.