EICd
EIC data model
ReconstructedParticleRelationsConst.h
Go to the documentation of this file.
1 // AUTOMATICALLY GENERATED FILE - DO NOT EDIT
2 
3 #ifndef EICD_ConstReconstructedParticleRelations_H
4 #define EICD_ConstReconstructedParticleRelations_H
5 
7 
8 #include "eicd/Index.h"
9 #include "podio/ObjectID.h"
10 
11 
12 
13 namespace eic {
14 
15 
16 /** @class ConstReconstructedParticleRelations
17  * Relational info associated with our reconstructed particle
18  * @author: S. Joosten
19  */
21 
25 
26 public:
27  /// default constructor
30 
31  /// constructor from existing ReconstructedParticleRelationsObj
33 
34  /// copy constructor
36 
37  /// copy-assignment operator
39 
40  /// support cloning (deep-copy)
42 
43  /// destructor
45 
46 
47 public:
48 
49  /// Access the ReconstructedParticle index
50  const eic::Index& recID() const;
51 
52  /// Access the Start vertex for this particle
53  const eic::Index& vertexID() const;
54 
55  /// Access the Index of the associated track, if any
56  const eic::Index& trackID() const;
57 
58  /// Access the Index of associated pos/barrel/neg ECAL cluster, if any
59  const eic::Index& ecalID() const;
60 
61  /// Access the Index of associated pos/barrel/neg HCAL cluster, if any
62  const eic::Index& hcalID() const;
63 
64  /// Access the Index of associated pos/barrel/neg Cherenkov info, if any
65  const eic::Index& cherID() const;
66 
67  /// Access the Index of the associated TOF info, if any
68  const eic::Index& tofID() const;
69 
70  /// Access the Index of the associated MC particle, if any
71  const eic::Index& mcID() const;
72 
73 
74 
75 
76 
77  /// check whether the object is actually available
78  bool isAvailable() const;
79  /// disconnect from ReconstructedParticleRelationsObj instance
80  void unlink() { m_obj = nullptr; }
81 
82  bool operator==(const ConstReconstructedParticleRelations& other) const { return m_obj == other.m_obj; }
83  bool operator==(const ReconstructedParticleRelations& other) const;
84 
85  // less comparison operator, so that objects can be e.g. stored in sets.
86  bool operator<(const ConstReconstructedParticleRelations& other) const { return m_obj < other.m_obj; }
87 
88  unsigned int id() const { return getObjectID().collectionID * 10000000 + getObjectID().index; }
89 
90  const podio::ObjectID getObjectID() const;
91 
92 private:
94 };
95 
96 } // namespace eic
97 
98 
99 #endif
eic::ConstReconstructedParticleRelations::~ConstReconstructedParticleRelations
~ConstReconstructedParticleRelations()
destructor
Definition: ReconstructedParticleRelationsConst.cc:50
eic::Index
Definition: Index.h:11
eic::ConstReconstructedParticleRelations::clone
ConstReconstructedParticleRelations clone() const
support cloning (deep-copy)
Definition: ReconstructedParticleRelationsConst.cc:46
eic::ConstReconstructedParticleRelations::cherID
const eic::Index & cherID() const
Access the Index of associated pos/barrel/neg Cherenkov info, if any.
Definition: ReconstructedParticleRelationsConst.cc:58
eic::ConstReconstructedParticleRelations::vertexID
const eic::Index & vertexID() const
Access the Start vertex for this particle.
Definition: ReconstructedParticleRelationsConst.cc:54
eic
Definition: BasicParticle.cc:13
eic::ConstReconstructedParticleRelations::ConstReconstructedParticleRelations
ConstReconstructedParticleRelations()
default constructor
Definition: ReconstructedParticleRelationsConst.cc:16
eic::ConstReconstructedParticleRelations::isAvailable
bool isAvailable() const
check whether the object is actually available
Definition: ReconstructedParticleRelationsConst.cc:67
eic::ConstReconstructedParticleRelations::operator==
bool operator==(const ConstReconstructedParticleRelations &other) const
Definition: ReconstructedParticleRelationsConst.h:82
eic::ConstReconstructedParticleRelations::tofID
const eic::Index & tofID() const
Access the Index of the associated TOF info, if any.
Definition: ReconstructedParticleRelationsConst.cc:59
eic::ConstReconstructedParticleRelations::id
unsigned int id() const
Definition: ReconstructedParticleRelationsConst.h:88
eic::ConstReconstructedParticleRelations::operator=
ConstReconstructedParticleRelations & operator=(const ConstReconstructedParticleRelations &other)
copy-assignment operator
Definition: ReconstructedParticleRelationsConst.cc:36
eic::ConstReconstructedParticleRelations::mcID
const eic::Index & mcID() const
Access the Index of the associated MC particle, if any.
Definition: ReconstructedParticleRelationsConst.cc:60
eic::ReconstructedParticleRelationsConstCollectionIterator
Definition: ReconstructedParticleRelationsCollection.h:51
eic::ReconstructedParticleRelations
Definition: ReconstructedParticleRelations.h:22
eic::ConstReconstructedParticleRelations::recID
const eic::Index & recID() const
Access the ReconstructedParticle index.
Definition: ReconstructedParticleRelationsConst.cc:53
eic::ConstReconstructedParticleRelations::unlink
void unlink()
disconnect from ReconstructedParticleRelationsObj instance
Definition: ReconstructedParticleRelationsConst.h:80
eic::ConstReconstructedParticleRelations::hcalID
const eic::Index & hcalID() const
Access the Index of associated pos/barrel/neg HCAL cluster, if any.
Definition: ReconstructedParticleRelationsConst.cc:57
eic::ConstReconstructedParticleRelations::trackID
const eic::Index & trackID() const
Access the Index of the associated track, if any.
Definition: ReconstructedParticleRelationsConst.cc:55
ReconstructedParticleRelationsObj.h
eic::ReconstructedParticleRelationsCollection
Definition: ReconstructedParticleRelationsCollection.h:76
eic::ConstReconstructedParticleRelations
Definition: ReconstructedParticleRelationsConst.h:20
eic::ReconstructedParticleRelationsObj
Definition: ReconstructedParticleRelationsObj.h:18
eic::ConstReconstructedParticleRelations::operator<
bool operator<(const ConstReconstructedParticleRelations &other) const
Definition: ReconstructedParticleRelationsConst.h:86
Index.h
eic::ConstReconstructedParticleRelations::ecalID
const eic::Index & ecalID() const
Access the Index of associated pos/barrel/neg ECAL cluster, if any.
Definition: ReconstructedParticleRelationsConst.cc:56
eic::ConstReconstructedParticleRelations::getObjectID
const podio::ObjectID getObjectID() const
Definition: ReconstructedParticleRelationsConst.cc:74