3#ifndef EDM4EIC_CherenkovParticleID_H
4#define EDM4EIC_CherenkovParticleID_H
10#include "podio/RelationRange.h"
13#include "podio/utilities/MaybeSharedPtr.h"
14#include "podio/detail/OrderKey.h"
19#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
20#include "nlohmann/json_fwd.hpp"
33OrderKey
getOrderKey(
const edm4eic::CherenkovParticleID& obj);
62 CherenkovParticleID(
const float npe,
const float refractiveIndex,
const float photonEnergy);
88 static constexpr std::string_view
typeName =
"edm4eic::CherenkovParticleID";
105 std::vector<edm4eic::RawTrackerHit>::const_iterator
rawHits_begin()
const;
106 std::vector<edm4eic::RawTrackerHit>::const_iterator
rawHits_end()
const;
107 podio::RelationRange<edm4eic::RawTrackerHit>
getRawHits()
const;
110 std::vector<edm4eic::CherenkovParticleIDHypothesis>::const_iterator
hypotheses_begin()
const;
111 std::vector<edm4eic::CherenkovParticleIDHypothesis>::const_iterator
hypotheses_end()
const;
112 podio::RelationRange<edm4eic::CherenkovParticleIDHypothesis>
getHypotheses()
const;
123 void unlink() { m_obj = podio::utils::MaybeSharedPtr<CherenkovParticleIDObj>{
nullptr}; }
138 friend std::hash<CherenkovParticleID>;
142 swap(a.m_obj, b.m_obj);
150 podio::utils::MaybeSharedPtr<CherenkovParticleIDObj> m_obj{
new CherenkovParticleIDObj{}, podio::utils::MarkOwned};
155#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
165struct std::hash<
edm4eic::CherenkovParticleID> {
167 return std::hash<edm4eic::CherenkovParticleIDObj*>{}(obj.m_obj.get());
175#if defined(__clang__)
176 #pragma clang diagnostic push
177 #pragma clang diagnostic ignored "-Wunknown-warning-option"
178 #pragma clang diagnostic ignored "-Wdeprecated-redundant-constexpr-static-def"
179 #pragma clang diagnostic ignored "-Wdeprecated"
181 #pragma clang diagnostic pop
182#elif defined(__GNUC__)
183 #pragma GCC diagnostic push
184 #pragma GCC diagnostic ignored "-Wdeprecated"
186 #pragma GCC diagnostic pop
Definition CherenkovParticleIDCollectionData.h:33
Definition CherenkovParticleIDCollection.h:139
Definition CherenkovParticleID.h:46
float getNpe() const
Access the Overall photoelectron count.
Definition CherenkovParticleID.cc:87
constexpr bool operator==(const CherenkovParticleID &other) const
Definition CherenkovParticleID.h:125
CherenkovParticleIDCollection collection_type
Definition CherenkovParticleID.h:56
MutableCherenkovParticleID clone(bool cloneRelations=true) const
Definition CherenkovParticleID.cc:32
const edm4eic::TrackSegment getChargedParticle() const
Access the reconstructed charged particle.
Definition CherenkovParticleID.cc:91
MutableCherenkovParticleID mutable_type
Definition CherenkovParticleID.h:55
std::vector< edm4hep::Vector2f >::const_iterator thetaPhiPhotons_end() const
Definition CherenkovParticleID.cc:170
CherenkovParticleID & operator=(CherenkovParticleID other) &
copy-assignment operator
Definition CherenkovParticleID.cc:27
podio::ObjectID id() const
Definition CherenkovParticleID.h:134
std::vector< edm4eic::RawTrackerHit >::const_iterator rawHits_end() const
Definition CherenkovParticleID.cc:106
std::vector< edm4hep::Vector2f >::const_iterator thetaPhiPhotons_begin() const
Definition CherenkovParticleID.cc:164
std::size_t hypotheses_size() const
Definition CherenkovParticleID.cc:144
float getPhotonEnergy() const
Access the Average energy for these Cherenkov photons [GeV].
Definition CherenkovParticleID.cc:89
~CherenkovParticleID()=default
destructor
friend class CherenkovParticleIDCollectionIterator
Definition CherenkovParticleID.h:51
const podio::ObjectID getObjectID() const
Definition CherenkovParticleID.cc:203
CherenkovParticleID()=default
default constructor
static constexpr std::string_view typeName
Definition CherenkovParticleID.h:88
friend void swap(CherenkovParticleID &a, CherenkovParticleID &b)
Definition CherenkovParticleID.h:140
bool isAvailable() const
check whether the object is actually available
Definition CherenkovParticleID.cc:199
CherenkovParticleID(const CherenkovParticleID &other) noexcept=default
copy constructor
CherenkovParticleID & operator=(CherenkovParticleID other) &&=delete
void unlink()
disconnect from CherenkovParticleIDObj instance
Definition CherenkovParticleID.h:123
std::vector< edm4eic::CherenkovParticleIDHypothesis >::const_iterator hypotheses_end() const
Definition CherenkovParticleID.cc:138
std::vector< edm4eic::CherenkovParticleIDHypothesis >::const_iterator hypotheses_begin() const
Definition CherenkovParticleID.cc:132
friend class MutableCherenkovParticleID
Definition CherenkovParticleID.h:48
bool operator<(const CherenkovParticleID &other) const
Definition CherenkovParticleID.h:132
friend class CherenkovParticleIDCollection
Definition CherenkovParticleID.h:49
static CherenkovParticleID makeEmpty()
Definition CherenkovParticleID.cc:83
podio::RelationRange< edm4hep::Vector2f > getThetaPhiPhotons() const
Definition CherenkovParticleID.cc:187
std::size_t rawHits_size() const
Definition CherenkovParticleID.cc:112
podio::RelationRange< edm4eic::RawTrackerHit > getRawHits() const
Definition CherenkovParticleID.cc:123
bool operator!=(const MutableCherenkovParticleID &other) const
Definition CherenkovParticleID.h:129
constexpr bool operator!=(const CherenkovParticleID &other) const
Definition CherenkovParticleID.h:128
podio::RelationRange< edm4eic::CherenkovParticleIDHypothesis > getHypotheses() const
Definition CherenkovParticleID.cc:155
std::vector< edm4eic::RawTrackerHit >::const_iterator rawHits_begin() const
Definition CherenkovParticleID.cc:100
float getRefractiveIndex() const
Access the Average refractive index at the Cherenkov photons' vertices.
Definition CherenkovParticleID.cc:88
std::size_t thetaPhiPhotons_size() const
Definition CherenkovParticleID.cc:176
CherenkovParticleID(CherenkovParticleID &&other) noexcept=default
move constructor
Definition CherenkovParticleIDHypothesis.h:20
Definition CherenkovParticleIDObj.h:26
Definition MutableCherenkovParticleID.h:38
Definition MutableTrackSegment.h:37
Definition RawTrackerHit.h:41
Definition TrackSegment.h:45
Definition ArrowMapper.cc:63
std::ostream & operator<<(std::ostream &o, const CalorimeterHit &value)
Definition CalorimeterHit.cc:99
Definition CalorimeterHit.h:31
OrderKey getOrderKey(const edm4eic::CalorimeterHit &obj)
Definition CalorimeterHit.cc:146
std::size_t operator()(const edm4eic::CherenkovParticleID &obj) const
Definition CherenkovParticleID.h:166