13#ifndef STOREGATE_READDECORHANDLE_H
14#define STOREGATE_READDECORHANDLE_H
21#include "GaudiKernel/EventContext.h"
91template <
class T,
class D>
134 const EventContext& ctx);
140 const EventContext& ctx) =
delete;
221 template <
class POINTER_TYPE = const_container_po
inter_type>
222 requires (!std::is_void_v<POINTER_TYPE>)
306template <
class D,
class T>
330template <
class D,
class T>
332 const EventContext& ctx);
346 const EventContext& ctx);
Base class for elements of a container that can have aux data.
Some common helper functions used by decoration handles.
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Handle class for reading from StoreGate.
Manage lookup of vectors of auxiliary data.
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Handle class for reading a decoration on an object.
const_reference_type withDefault(const AuxElement &e, const D &deflt) const
Fetch the variable for one element, as a const reference.
SG::AuxElement::ConstAccessor< D > accessor_t
Accessor type for aux data.
typename accessor_t::const_container_pointer_type const_container_pointer_type
Pointer into the vector holding an aux data item.
ReadDecorHandle(SG::ReadDecorHandleKey< T > &&key)=delete
ReadDecorHandle(ReadDecorHandle &&rhs)
Move constructor.
const_span getDataSpan()
Get a span over the auxilary data array, for the referenced object.
ReadDecorHandle(const ReadDecorHandle &rhs)
Copy constructor.
ReadDecorHandle(const ReadDecorHandleKey< T > &key, const EventContext &ctx)
Constructor from a ReadDecorHandleKey and an explicit event context.
ReadDecorHandle(const ReadDecorHandleKey< T > &key)
Constructor from a ReadDecorHandleKey.
const SG::AuxVectorData * vectorData()
Return the referenced object as a SG::AuxVectorData.
ReadHandle< T > Base
Base class.
SG::auxid_t auxid() const
Return the aux id for this variable.
POINTER_TYPE getDataArray()
Get a pointer to the start of the auxiliary data array, for the referenced object.
ReadDecorHandle(SG::ReadDecorHandleKey< T > &&key, const EventContext &ctx)=delete
bool isPresent() const
Is the referenced container present in SG?
const_reference_type withDefault(size_t index, const D &deflt)
Fetch the variable for one element, as a const reference.
typename accessor_t::const_span const_span
Span of aux data items.
const_reference_type operator()(const AuxElement &e) const
Fetch the variable for one element, as a const reference.
std::string m_decorKey
Name of the decoration alias.
const SG::AuxVectorData * vectorData(std::true_type)
Return the referenced object as a SG::AuxVectorData.
ReadDecorHandle & operator=(const ReadDecorHandle &rhs)
Assignment operator.
typename accessor_t::const_reference_type const_reference_type
Type referencing an aux data item.
const std::string & decorKey() const
Return the name of the decoration alias (CONT.DECOR).
bool isAvailable()
Test to see if this variable exists in the store, for the referenced object.
const SG::AuxVectorData * vectorData(std::false_type)
Return the referenced object as a SG::AuxVectorData.
accessor_t m_acc
Accessor for the aux data item.
AuxElement(SG::AuxVectorData *container, size_t index)
Base class for elements of a container that can have aux data.
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
size_t auxid_t
Identifier for a particular aux data item.