LArSoft  v10_04_05
Liquid Argon Software toolkit - https://larsoft.org/
readout::ROPID Struct Reference

Class identifying a set of planes sharing readout channels. More...

#include "readout_types.h"

Inheritance diagram for readout::ROPID:
readout::TPCsetID geo::CryostatID

Public Types

using ROPID_t = unsigned int
 Type for the ID number. More...
 
using ParentID_t = TPCsetID
 Type of the parent ID. More...
 
using TPCsetID_t = unsigned short
 Type for the ID number. More...
 
using CryostatID_t = unsigned int
 Type for the ID number. More...
 

Public Member Functions

constexpr ROPID ()=default
 Default constructor: an invalid plane ID. More...
 
constexpr ROPID (TPCsetID const &tpcsetid, ROPID_t r)
 Constructor: readout plane with index r in the TPC set identified by tpcsetid. More...
 
constexpr ROPID (CryostatID_t c, TPCsetID_t s, ROPID_t r)
 
constexpr auto const & deepestIndex () const
 Returns the value of the deepest ID available (readout plane's). More...
 
auto & deepestIndex ()
 Returns the deepest ID available (readout plane's). More...
 
constexpr ParentID_t const & parentID () const
 Return the parent ID of this one (a TPC set ID). More...
 
constexpr ParentID_tparentID ()
 
template<std::size_t Index>
constexpr auto getIndex () const
 Returns the index level Index of this type. More...
 
constexpr TPCsetID const & asTPCsetID () const
 Conversion to ROPID (for convenience of notation). More...
 
constexpr TPCsetIDasTPCsetID ()
 
constexpr CryostatID const & asCryostatID () const
 Conversion to TPCsetID (for convenience of notation). More...
 
constexpr CryostatIDasCryostatID ()
 
std::string toString () const
 Human-readable representation of the ROP ID. More...
 
 operator std::string () const
 Human-readable representation of the ROP ID. More...
 
ID validity
constexpr operator bool () const
 Returns true if the ID is valid. More...
 
void setValidity (bool valid)
 Sets the validity of the ID. More...
 
void markValid ()
 Sets the ID as valid. More...
 
void markInvalid ()
 Sets the ID as invalid. More...
 

Static Public Member Functions

static constexpr auto first ()
 
static constexpr auto first (CryostatID const &id)
 
static constexpr auto first (TPCsetID const &id)
 
static constexpr ROPID_t getInvalidID ()
 Return the value of the invalid ROP ID as a r-value. More...
 

Public Attributes

ROPID_t ROP = InvalidID
 Index of the readout plane within its TPC set. More...
 
TPCsetID_t TPCset = InvalidID
 Index of the TPC set within its cryostat. More...
 
bool isValid = false
 Whether this ID points to a valid element. More...
 
CryostatID_t Cryostat = InvalidID
 Index of cryostat. More...
 

Static Public Attributes

static constexpr ROPID_t InvalidID = std::numeric_limits<ROPID_t>::max()
 Special code for an invalid ID. More...
 
static constexpr auto Level = geo::details::index_for<ROPID>()
 Level of this element. More...
 

Detailed Description

Class identifying a set of planes sharing readout channels.

This identifier provides the TPC set location and a number representing the set of planes. This set is defined by not sharing readout channels with any other plane outside the set.

The name stands for "readout plane".

Definition at line 118 of file readout_types.h.

Member Typedef Documentation

using geo::CryostatID::CryostatID_t = unsigned int
inherited

Type for the ID number.

Definition at line 188 of file geo_types.h.

Type of the parent ID.

Definition at line 121 of file readout_types.h.

using readout::ROPID::ROPID_t = unsigned int

Type for the ID number.

Definition at line 119 of file readout_types.h.

using readout::TPCsetID::TPCsetID_t = unsigned short
inherited

Type for the ID number.

Definition at line 55 of file readout_types.h.

Constructor & Destructor Documentation

constexpr readout::ROPID::ROPID ( )
default

Default constructor: an invalid plane ID.

constexpr readout::ROPID::ROPID ( TPCsetID const &  tpcsetid,
ROPID_t  r 
)
inline

Constructor: readout plane with index r in the TPC set identified by tpcsetid.

Definition at line 132 of file readout_types.h.

132 : TPCsetID(tpcsetid), ROP(r) {}
TRandom r
Definition: spectrum.C:23
ROPID_t ROP
Index of the readout plane within its TPC set.
constexpr TPCsetID()=default
Default constructor: an invalid TPC set ID.
constexpr readout::ROPID::ROPID ( CryostatID_t  c,
TPCsetID_t  s,
ROPID_t  r 
)
inline

Constructor: readout plane with index r in the cryostat index c, TPC set index s.

Definition at line 136 of file readout_types.h.

136 : TPCsetID(c, s), ROP(r) {}
TRandom r
Definition: spectrum.C:23
ROPID_t ROP
Index of the readout plane within its TPC set.
constexpr TPCsetID()=default
Default constructor: an invalid TPC set ID.

Member Function Documentation

constexpr CryostatID const& readout::TPCsetID::asCryostatID ( ) const
inlineinherited

Conversion to TPCsetID (for convenience of notation).

Definition at line 98 of file readout_types.h.

Referenced by readout::operator<<().

98 { return parentID(); }
constexpr ParentID_t const & parentID() const
Return the parent ID of this one (a cryostat ID).
Definition: readout_types.h:91
constexpr CryostatID& readout::TPCsetID::asCryostatID ( )
inlineinherited

Definition at line 99 of file readout_types.h.

99 { return parentID(); }
constexpr ParentID_t const & parentID() const
Return the parent ID of this one (a cryostat ID).
Definition: readout_types.h:91
constexpr TPCsetID const& readout::ROPID::asTPCsetID ( ) const
inline

Conversion to ROPID (for convenience of notation).

Definition at line 163 of file readout_types.h.

Referenced by readout::operator<<(), and geo::WireReadoutStandardGeom::ROPtoTPCs().

163 { return parentID(); }
constexpr ParentID_t const & parentID() const
Return the parent ID of this one (a TPC set ID).
constexpr TPCsetID& readout::ROPID::asTPCsetID ( )
inline

Definition at line 164 of file readout_types.h.

164 { return parentID(); }
constexpr ParentID_t const & parentID() const
Return the parent ID of this one (a TPC set ID).
constexpr auto const& readout::ROPID::deepestIndex ( ) const
inline

Returns the value of the deepest ID available (readout plane's).

Definition at line 152 of file readout_types.h.

152 { return ROP; }
ROPID_t ROP
Index of the readout plane within its TPC set.
auto& readout::ROPID::deepestIndex ( )
inline

Returns the deepest ID available (readout plane's).

Definition at line 154 of file readout_types.h.

154 { return ROP; }
ROPID_t ROP
Index of the readout plane within its TPC set.
static constexpr auto readout::ROPID::first ( )
inlinestatic

Definition at line 138 of file readout_types.h.

References readout::TPCsetID::first().

138 { return ROPID{TPCsetID::first(), 0}; }
static constexpr auto first()
Definition: readout_types.h:74
constexpr ROPID()=default
Default constructor: an invalid plane ID.
static constexpr auto readout::ROPID::first ( CryostatID const &  id)
inlinestatic

Definition at line 139 of file readout_types.h.

References readout::TPCsetID::first().

139 { return ROPID{TPCsetID::first(id), 0}; }
static constexpr auto first()
Definition: readout_types.h:74
constexpr ROPID()=default
Default constructor: an invalid plane ID.
static constexpr auto readout::ROPID::first ( TPCsetID const &  id)
inlinestatic

Definition at line 140 of file readout_types.h.

References readout::details::writeToString().

140 { return ROPID{id, 0}; }
constexpr ROPID()=default
Default constructor: an invalid plane ID.
template<std::size_t Index>
constexpr auto readout::ROPID::getIndex ( ) const

Returns the index level Index of this type.

Definition at line 204 of file readout_types.h.

205 {
206  static_assert(Index <= Level, "This ID type does not have the requested Index level.");
207  return details::getAbsIDindex<Index>(*this);
208 }
static constexpr auto Level
Level of this element.
static constexpr ROPID_t readout::ROPID::getInvalidID ( )
inlinestatic

Return the value of the invalid ROP ID as a r-value.

Definition at line 170 of file readout_types.h.

References InvalidID.

170 { return ROPID::InvalidID; }
static constexpr ROPID_t InvalidID
Special code for an invalid ID.
void geo::CryostatID::markInvalid ( )
inlineinherited

Sets the ID as invalid.

Definition at line 220 of file geo_types.h.

References geo::details::writeToString().

220 { setValidity(false); }
void setValidity(bool valid)
Sets the validity of the ID.
Definition: geo_types.h:214
void geo::CryostatID::markValid ( )
inlineinherited

Sets the ID as valid.

Definition at line 217 of file geo_types.h.

217 { setValidity(true); }
void setValidity(bool valid)
Sets the validity of the ID.
Definition: geo_types.h:214
constexpr geo::CryostatID::operator bool ( ) const
inlineexplicitinherited

Returns true if the ID is valid.

Definition at line 211 of file geo_types.h.

211 { return isValid; }
bool isValid
Whether this ID points to a valid element.
Definition: geo_types.h:194
readout::ROPID::operator std::string ( ) const
inlineexplicit

Human-readable representation of the ROP ID.

Definition at line 147 of file readout_types.h.

147 { return toString(); }
std::string toString() const
Human-readable representation of the ROP ID.
constexpr ParentID_t const& readout::ROPID::parentID ( ) const
inline

Return the parent ID of this one (a TPC set ID).

Definition at line 156 of file readout_types.h.

156 { return *this; }
constexpr ParentID_t& readout::ROPID::parentID ( )
inline

Definition at line 157 of file readout_types.h.

157 { return *this; }
void geo::CryostatID::setValidity ( bool  valid)
inlineinherited

Sets the validity of the ID.

Definition at line 214 of file geo_types.h.

214 { isValid = valid; }
bool isValid
Whether this ID points to a valid element.
Definition: geo_types.h:194
std::string readout::ROPID::toString ( ) const
inline

Human-readable representation of the ROP ID.

Definition at line 146 of file readout_types.h.

146 { return details::writeToString(*this); }
std::string writeToString(T const &value)
Definition: readout_types.h:22

Member Data Documentation

CryostatID_t geo::CryostatID::Cryostat = InvalidID
inherited

Index of cryostat.

Definition at line 195 of file geo_types.h.

Referenced by detsim::WienerFilterAna::analyze(), trkf::SpacePointAna::analyze(), pma::ProjectionMatchingAlg::buildShowerSeg(), mvapid::MVAAlg::CalcSegmentdEdxDist(), tca::ChgFracBetween(), tca::ChgFracNearEnd(), lar_cluster3d::StandardHit3DBuilder::CollectArtHits(), lar_cluster3d::SnippetHit3DBuilder::CollectArtHits(), trkf::SpacePointAlg::compatible(), tca::CompleteIncomplete3DVerticesInGaps(), ems::MultiEMShowers::convCluster(), detinfo::DetectorPropertiesData::ConvertTicksToX(), detinfo::DetectorPropertiesData::ConvertXToTicks(), geo::GeometryCore::Cryostat(), geo::GeometryCore::CryostatPtr(), cluster::ClusterCrawlerAlg::EncodeCTP(), tca::EncodeCTP(), ems::EndPoint::EndPoint(), trkf::SpacePointAlg::fillComplexSpacePoint(), tca::FillmAllTraj(), lar_pandora::PFParticleHitDumper::FillRecoWires(), trkf::SpacePointAlg::fillSpacePoint(), tca::FillWireHitRange(), tca::FillWireIntersections(), tca::Find3DVertices(), apa::DisambigAlg::FindChanTimeEndPts(), hit::HitCheater::FindHitsOnChannel(), larg4::LArVoxelReadoutGeometry::FindNestedVolume(), tca::FindParent(), tca::FitTP3Ds(), ems::EMShower3D::GetCloseHits(), geo::GeometryCore::GetClosestOpDet(), calo::GnocchiCalorimetry::GetPitch(), pma::Track3D::GetUnconstrainedProj3D(), detinfo::DetectorPropertiesData::GetXTicksOffset(), cluster::MergeClusterAlg::GlobalWire(), cluster::BlurredClusteringAlg::GlobalWire(), shower::EMShowerAlg::GlobalWire_(), geo::GeometryCore::HasCryostat(), tss::Hit2D::Hit2D(), pma::Hit3D::Hit3D(), lar_cluster3d::SpacePointHit3DBuilder::Hit3DBuilder(), hit::DisambigCheater::InitHitToWids(), trkf::KHitWireLine::KHitWireLine(), trkf::KHitWireX::KHitWireX(), lar_cluster3d::StandardHit3DBuilder::makeDeadChannelPair(), lar_cluster3d::SnippetHit3DBuilder::makeDeadChannelPair(), lar_cluster3d::StandardHit3DBuilder::makeHitPair(), lar_cluster3d::SnippetHit3DBuilder::makeHitPair(), lar_cluster3d::StandardHit3DBuilder::makeHitTriplet(), lar_cluster3d::SnippetHit3DBuilder::makeHitTriplet(), tca::MakePFPTjs(), trkf::SpacePointAlg::makeSpacePoints(), trkf::CosmicTrackerAlg::MakeSPT(), tca::Match2Planes(), evd::SimulationDrawer::MCTruthOrtho(), apa::APAGeometryAlg::NearestWireIDOnChan(), geo::WireReadoutStandardGeom::NTPCsets(), geo::operator<(), anab::operator<<(), recob::operator<<(), geo::operator<<(), geo::operator==(), lar_cluster3d::PrincipalComponentsAlg::PCAAnalysis_2D(), tca::Print3S(), tca::Print3V(), tca::PrintAllTraj(), tca::PrintTP3Ds(), cluster::LineCluster::produce(), cluster::TrajCluster::produce(), hit::DPRawHitFinder::produce(), detsim::SimDriftElectrons::produce(), calo::Calorimetry::produce(), calo::GnocchiCalorimetry::produce(), trkf::SpacePointAlg::separation(), tca::SignalAtTp(), cheat::BackTracker::SpacePointHitsToWeightedXYZ(), apa::DisambigAlg::TrivialDisambig(), tca::ValidTwoPlaneMatch(), trkf::VertexFitAlg::VertexFit(), cluster::ClusterCrawlerAlg::Vtx3ClusterMatch(), cluster::ClusterCrawlerAlg::Vtx3ClusterSplit(), cluster::ClusterCrawlerAlg::VtxMatch(), tca::WireHitRangeOK(), and lar_cluster3d::SnippetHit3DBuilder::WireIDsIntersect().

constexpr ROPID_t readout::ROPID::InvalidID = std::numeric_limits<ROPID_t>::max()
static

Special code for an invalid ID.

Definition at line 124 of file readout_types.h.

Referenced by getInvalidID().

constexpr auto readout::ROPID::Level = geo::details::index_for<ROPID>()
static

Level of this element.

Definition at line 167 of file readout_types.h.

ROPID_t readout::ROPID::ROP = InvalidID

Index of the readout plane within its TPC set.

Definition at line 126 of file readout_types.h.

Referenced by geo::WireReadoutStandardGeom::HasROP(), and readout::operator<<().

TPCsetID_t readout::TPCsetID::TPCset = InvalidID
inherited

Index of the TPC set within its cryostat.

Definition at line 63 of file readout_types.h.

Referenced by geo::WireReadoutStandardGeom::HasTPCset(), and readout::operator<<().


The documentation for this struct was generated from the following file: