28 namespace geo {
class GeometryConfigurationWriter; }
102 using InfoPtr_t = std::unique_ptr<sumdata::GeometryConfigurationInfo>;
127 {
return std::make_unique<sumdata::GeometryConfigurationInfo>(
info); }
138 produces<sumdata::GeometryConfigurationInfo, art::InRun>();
182 <<
"Geometry configuration information from service:\n" << confInfo;
221 return allRunData.empty()?
nullptr: allRunData.front().product();
237 <<
"Built geometry configuration information from run data:\n" << confInfo;
std::string const & DetName() const
Writes geometry configuration information into art runs.
DataVersion_t dataVersion
Version of the data in this object (0 is invalid version).
Description of the current configuration of detector geometry.
GeometryConfigurationWriter(Parameters const &)
Constructor: gets its configuration and does nothing with it.
InfoPtr_t makeInfoFromRunData(art::Run &run) const
art framework interface to geometry description
bool getByLabel(std::string const &label, std::string const &instance, Handle< PROD > &result) const
static InfoPtr_t makeInfoPtr(sumdata::GeometryConfigurationInfo const &info)
Alias to std::make_unique<sumdata::GeometryConfigurationInfo>.
std::vector< Handle< PROD > > getMany(SelectorBase const &selector=MatchAllSelector{}) const
static InfoPtr_t convertRunDataToGeometryInformation(sumdata::RunData const &data)
Converts the legacy data into geometry configuration information.
ProductID put(std::unique_ptr< PROD > &&edp, std::string const &instance={})
#define DEFINE_ART_PRODUCING_SERVICE(klass)
std::unique_ptr< sumdata::GeometryConfigurationInfo > InfoPtr_t
Alias for the pointer to the data product object to be put into the run.
InfoPtr_t readGeometryInformation(art::Run &run) const
Reads geometry information from the run (returns null pointer if none).
static InfoPtr_t extractInfoFromGeometry()
Creates configuration information based on the current Geometry service.
unsigned int DataVersion_t
Type used for the version of data.
sumdata::RunData const * readRunData(art::Run &run) const
Returns a pointer to the sumdata::RunData in run (nullptr if none).
LArSoft geometry interface.
virtual void postReadRun(art::Run &run) override
Writes the information from the service configuration into the run.
Description of the current configuration of detector geometry.
InfoPtr_t loadInfo(art::Run &run) const
Loads the geometry information from the run (either directly or legacy).