10 #ifndef LARCOREALG_GEOMETRY_DETAILS_EXTRACTMAXGEOMETRYELEMENTS_H 11 #define LARCOREALG_GEOMETRY_DETAILS_EXTRACTMAXGEOMETRYELEMENTS_H 42 template <std::
size_t Levels = 4U>
51 template <std::size_t Levels >
55 static_assert(Levels > 0U);
56 static_assert(Levels <= 4U);
58 std::array<unsigned int, Levels> maxElements;
61 auto setMax = [&maxElements](std::size_t index,
unsigned int value) {
62 if (maxElements[index] <
value) maxElements[index] =
value;
65 setMax(0U, Cryostats.size());
66 if constexpr (Levels > 1U) {
68 setMax(1U, cryo.NTPC());
69 if constexpr (Levels > 2U) {
71 setMax(2U, TPC.Nplanes());
72 if constexpr (Levels > 3U) {
74 setMax(3U, plane.Nwires());
87 #endif // LARCOREALG_GEOMETRY_DETAILS_EXTRACTMAXGEOMETRYELEMENTS_H Encapsulate the construction of a single cyostat.
Simple data structure holding the data of the geometry.
Geometry information for a single TPC.
static std::array< unsigned int, Levels > extractMaxGeometryElements(geo::GeometryData_t::CryostatList_t const &Cryostats)
Extracts the maximum number of elements per type.
std::vector< geo::CryostatGeo > CryostatList_t
Type of list of cryostats.
Geometry information for a single cryostat.
Geometry information for a single wire plane.The plane is represented in the geometry by a solid whic...
Encapsulate the construction of a single detector plane.
Encapsulate the construction of a single detector plane.