7#ifndef XAODMISSINGET_VERSIONS_MISSINGETCOMPONENTMAP_V1_H
8#define XAODMISSINGET_VERSIONS_MISSINGETCOMPONENTMAP_V1_H
178 template <
class COMPARE>
void sort(COMPARE comp);
228 if ( pPart->
type() == Type::CaloCluster )
231 if ( pPart->
type() == Type::TrackParticle )
278 template<
int OBJTYPE>
281 MissingETBase::Types::object_vector_t::iterator fSign(sig.begin());
282 while ( fSign != sig.end() ) {
if ( (*fSign)->type() != OBJTYPE ) { fSign = sig.erase(fSign); }
else { ++fSign; } }
#define SG_BASE(D, B)
Declare that class D derives from class B.
An STL vector of pointers that by default owns its pointed-to elements.
DataModel_detail::const_iterator< DataVector > const_iterator
typename DataVectorBase< MissingETComponent_v1 >::Base::size_type size_type
void reserve(size_type n)
DataModel_detail::iterator< DataVector > iterator
DataVector(SG::OwnershipPolicy ownPolicy=SG::OWN_ELEMENTS, SG::IndexTrackingPolicy trackIndices=SG::DEFAULT_TRACK_INDICES)
SG::OwnershipPolicy ownPolicy() const
size_t index() const
Return the index of this element within its container.
Class providing the definition of the 4-vector interface.
virtual Type::ObjectType type() const =0
The type of the object as a simple enumeration.
bool checkUsage(const IParticle *pPart, MissingETBase::UsageHandler::Policy p=MissingETBase::UsageHandler::OnlyCluster) const
Check if a given object is already used in MET.
particle_map_t m_particleLinks
Store for linked physics object information lookup.
static const size_t m_clusterLinkReserve
size_t signal_key_t
Key type for signals (clusters, tracks) is type of index in container.
const MissingET * retrieveMissingET(const std::string &name) const
Retrieve MissingET object by name.
static const size_t m_trackLinkReserve
bool setTracks(const MissingET *pMET, const IParticle *pPart, const MissingETBase::Types::object_vector_t &signalList)
void clear(SG::OwnershipPolicy ownPolicy, SG::IndexTrackingPolicy trackIndices)
void f_setupLookupCache(signal_vector_t &signalLinks, size_t reserve)
Set up the signal object lookup.
bool f_checkObjectUsage(MissingETBase::Types::object_vector_t &sig, const signal_vector_t &signalLinks) const
Check signal object usage.
bool addObjects(const MissingET *pMET, const IParticle *pPart, const MissingETBase::Types::object_vector_t &signalList, MissingETBase::UsageHandler::Policy p=MissingETBase::UsageHandler::OnlyCluster)
signal_vector_t m_clusterLinks
Store for linked cluuster signal information lookup.
MissingETComponentMap_v1(SG::OwnershipPolicy own=SG::OWN_ELEMENTS, SG::IndexTrackingPolicy trackIndices=SG::DEFAULT_TRACK_INDICES)
Default constructor.
void resize(size_type sz)
std::vector< indexedlink_t > signal_vector_t
Indexed list type for signal object link locations.
bool setClusters(const MissingET *pMET, const IParticle *pPart, const MissingETBase::Types::object_vector_t &signalList)
signal_vector_t m_trackLinks
Store for linked track signal information lookup.
void f_clearLookupCache()
Clear the lookup cache.
const_iterator find(const MissingET *pMET) const
Find MET object referenced by pointer.
void clear(SG::OwnershipPolicy ownPolicy)
bool f_extractSignal(MissingETBase::Types::object_vector_t &sig) const
Signal type extractor.
size_t getObjectIndex(const IParticle *pPart) const
size_t getComponentIndex(const IParticle *pPart) const
iterator erase(iterator first, iterator last)
const MissingET * f_retrieveMissingETIncl(MissingETBase::Types::bitmask_t src) const
const IParticle * particle_key_t
Key type for physics objects is the base pointer type of these objects.
void f_fillLookupCache()
Fill the lookup cache from the composition map data content.
iterator erase(iterator position)
size_t findIndex(const MissingET *pMET) const
MissingETBase::Types::indexedlink_t indexedlink_t
Type for the description of the link locations.
bool setObjects(const MissingET *pMET, const IParticle *pPart, const MissingETBase::Types::object_vector_t &objectList)
const MissingET * f_retrieveMissingETExcl(MissingETBase::Types::bitmask_t src) const
virtual ~MissingETComponentMap_v1()
Base class destructor.
size_t f_getIndex(const IParticle *pPart) const
std::map< particle_key_t, indexedlink_t > particle_map_t
Map type for physics object.
std::vector< const xAOD::IParticle * > object_vector_t
Vector of object type.
uint64_t bitmask_t
Type for status word bit mask.
std::tuple< size_t, size_t > indexedlink_t
Type for links defined as index pairs.
Policy
Policies on usage checks.
@ OnlyCluster
CaloCluster based only.
@ DEFAULT_TRACK_INDICES
Default value.
@ OWN_ELEMENTS
this data object owns its elements
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
MissingET_v1 MissingET
Version control by type defintion.
static size_t invalidIndex()
Access invalid index indicator.