3#ifndef EDM4EIC_MCRecoParticleAssociation_H
4#define EDM4EIC_MCRecoParticleAssociation_H
10#include "podio/utilities/MaybeSharedPtr.h"
11#include "podio/detail/OrderKey.h"
16#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
17#include "nlohmann/json_fwd.hpp"
22class MCRecoParticleAssociationCollection;
23class ReconstructedParticle;
24class MutableReconstructedParticle;
28class MutableMCParticle;
39class MutableMCRecoParticleAssociation;
40class MCRecoParticleAssociationCollection;
41class MCRecoParticleAssociationCollectionData;
85 static constexpr auto typeName =
"edm4eic::MCRecoParticleAssociation";
100 const edm4hep::MCParticle
getSim()
const;
107 void unlink() { m_obj = podio::utils::MaybeSharedPtr<MCRecoParticleAssociationObj>{
nullptr}; }
124 swap(a.m_obj, b.m_obj);
132 podio::utils::MaybeSharedPtr<MCRecoParticleAssociationObj> m_obj{
nullptr};
135std::ostream&
operator<<(std::ostream& o,
const MCRecoParticleAssociation& value);
137#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
138void to_json(nlohmann::json& j,
const MCRecoParticleAssociation& value);
Definition MCRecoParticleAssociationCollectionData.h:32
Definition MCRecoParticleAssociationCollection.h:91
Definition MCRecoParticleAssociationCollection.h:36
Definition MCRecoParticleAssociation.h:47
friend class MutableMCRecoParticleAssociation
Definition MCRecoParticleAssociation.h:49
friend void swap(MCRecoParticleAssociation &a, MCRecoParticleAssociation &b)
Definition MCRecoParticleAssociation.h:122
bool operator<(const MCRecoParticleAssociation &other) const
Definition MCRecoParticleAssociation.h:116
const podio::ObjectID getObjectID() const
Definition MCRecoParticleAssociation.cc:89
const edm4eic::ReconstructedParticle getRec() const
Access the reference to the reconstructed particle.
Definition MCRecoParticleAssociation.cc:66
bool operator!=(const MutableMCRecoParticleAssociation &other) const
Definition MCRecoParticleAssociation.h:113
const edm4hep::MCParticle getSim() const
Access the reference to the Monte-Carlo particle.
Definition MCRecoParticleAssociation.cc:73
bool operator==(const MCRecoParticleAssociation &other) const
Definition MCRecoParticleAssociation.h:109
MutableMCRecoParticleAssociation clone(bool cloneRelations=true) const
Definition MCRecoParticleAssociation.cc:37
std::uint32_t getSimID() const
Access the Index of corresponding MCParticle (position in MCParticles array)
Definition MCRecoParticleAssociation.cc:62
void unlink()
disconnect from MCRecoParticleAssociationObj instance
Definition MCRecoParticleAssociation.h:107
~MCRecoParticleAssociation()=default
destructor
bool isAvailable() const
check whether the object is actually available
Definition MCRecoParticleAssociation.cc:85
MCRecoParticleAssociation(const MCRecoParticleAssociation &other)=default
copy constructor
float getWeight() const
Access the weight of this association.
Definition MCRecoParticleAssociation.cc:64
std::uint32_t getRecID() const
Access the Index of corresponding ReconstructedParticle (position in ReconstructedParticles array)
Definition MCRecoParticleAssociation.cc:63
static constexpr auto typeName
Definition MCRecoParticleAssociation.h:85
static MCRecoParticleAssociation makeEmpty()
Definition MCRecoParticleAssociation.cc:58
MCRecoParticleAssociation()
default constructor
Definition MCRecoParticleAssociation.cc:22
MCRecoParticleAssociation & operator=(MCRecoParticleAssociation other)
copy-assignment operator
Definition MCRecoParticleAssociation.cc:32
friend class MCRecoParticleAssociationCollection
Definition MCRecoParticleAssociation.h:50
bool operator!=(const MCRecoParticleAssociation &other) const
Definition MCRecoParticleAssociation.h:112
podio::ObjectID id() const
Definition MCRecoParticleAssociation.h:118
Definition MCRecoParticleAssociationObj.h:24
Definition MutableMCRecoParticleAssociation.h:39
Definition ReconstructedParticle.h:54
Definition CalorimeterHit.cc:17
std::ostream & operator<<(std::ostream &o, const CalorimeterHit &value)
Definition CalorimeterHit.cc:103
Definition CalorimeterHit.h:25
Definition CalorimeterHit.h:31
OrderKey getOrderKey(const edm4eic::CalorimeterHit &obj)
Definition CalorimeterHit.cc:150