14#ifndef ATHCONTAINERS_JAGGEDVECDECORATOR_H
15#define ATHCONTAINERS_JAGGEDVECDECORATOR_H
75template <
class PAYLOAD_T,
class ALLOC>
81 using Payload_t = PAYLOAD_T;
84 using PayloadAlloc_t =
typename std::allocator_traits<ALLOC>::template rebind_alloc<Payload_t>;
87 using Elt_t = SG::JaggedVecElt<PAYLOAD_T>;
91 using JVecProxy = detail::JaggedVecProxyT<Payload_t, detail::JaggedVecProxyValBase>;
92 using JVecProxyInSpan = detail::JaggedVecProxyT<Payload_t, detail::JaggedVecProxyRefBase>;
95 using Converter_t = detail::JaggedVecConverter<Payload_t>;
98 using ConstConverter_t = detail::JaggedVecConstConverter<Payload_t>;
101 using const_Elt_span =
typename AuxDataTraits<JaggedVecElt<Payload_t>, ALLOC>
::const_span;
103 using Elt_span =
typename AuxDataTraits<JaggedVecElt<Payload_t>, ALLOC>
::span;
111 using element_type =
typename ConstConverter_t::element_type;
121 using rhs_const_reference_type = std::span<const Payload_t>;
144 Decorator (
const std::string& name,
const std::string& clsname);
167 template <IsConstAuxElement ELT>
194 template <IsConstAuxElement ELT,
195 CxxUtils::InputRangeOverT<PAYLOAD_T> RANGE>
196 void set (
const ELT& e,
const RANGE&
x)
const;
205 template <CxxUtils::InputRangeOverT<PAYLOAD_T> RANGE>
314 template <IsConstAuxElement ELT>
335 const std::string& clsname,
Handle mappings between names and auxid_t.
Basic definitions for auxiliary types.
Manage lookup of vectors of auxiliary data.
Helper class to provide type-safe access to aux data.
Flag that a class may have auxiliary data associated with it.
Helper class to provide constant type-safe access to aux data, specialized for JaggedVecElt.
Conversions for accessing jagged vector variables.
Definition of JaggedVecElt.
Factory object that creates vectors using AuxTypeVector, specialized for JaggedVec.
Define macros for attributes used to control the static checker.
CxxUtils::span< container_value_type > span
CxxUtils::span< const container_value_type > const_span
Manage lookup of vectors of auxiliary data.
Describe one element of a jagged vector.
Base class usable for accessors for variables with linked variables.
range_with_at< std::ranges::transform_view< SPAN, XFORM > > transform_view_with_at
Helper to add at() methods to a transform_view.
AuxVarFlags
Additional flags to qualify an auxiliary variable.
const_Elt_span getEltSpan(const AuxVectorData &container) const
Get a span over the array of JaggedVecElt objects.
Payload_t * getPayloadDecorArray(const AuxVectorData &container) const
Get a pointer to the start of the payload array, as a decoration.
Payload_span getPayloadDecorSpan(const AuxVectorData &container) const
Get a span over the payload vector, as a decoration.
SG::Decorator< T, ALLOC > Decorator
Helper class to provide type-safe access to aux data, specialized for JaggedVecElt.
SG::auxid_t auxid() const
Return the aux id for this variable.
void set(const ELT &e, const element_type &x) const
Set the variable for one element.
reference_type operator()(const ELT &e) const
Fetch the variable for one element, as a non-const reference.
Elt_span getEltDecorSpan(const AuxVectorData &container) const
Get a span over the array of JaggedVecElt objects, as a decoration.
CxxUtils::transform_view_with_at< PackedLinkVector_span, ELSpanConverter > span
const_Payload_span getPayloadSpan(const AuxVectorData &container) const
Get a span over the payload vector.
void const_container_pointer_type
elt_span reference_type
Type referencing an item.
size_t index() const
Return the index of this element within its container.
const SG::AuxVectorData * container() const
Return the container holding this element.
CxxUtils::transform_view_with_at< const_PackedLinkVector_span, ConstVectorTransform_t > const_span
Helper class to provide constant type-safe access to aux data, specialized for a vector of PackedLink...
XAOD_AUXDATA_DEPRECATED bool isAvailableWritable(const std::string &name, const std::string &clsname="")
Check if an aux variable is available for writing.
const Payload_t * getPayloadArray(const AuxVectorData &container) const
Get a pointer to the start of the payload array.
const_span getDataSpan(const AuxVectorData &container) const
Get a span over the auxiliary data array.
elt_span element_type
Type the user sees.
span getDecorationSpan(const AuxVectorData &container) const
Get a span over the auxiliary data array.
void container_pointer_type
Not supported.
const Elt_t * getEltArray(const AuxVectorData &container) const
Get a pointer to the start of the array of JaggedVecElt objects.
Elt_t * getEltDecorArray(const AuxVectorData &container) const
Get a pointer to the start of the array of JaggedVecElt objects, as a decoration.
size_t auxid_t
Identifier for a particular aux data item.
Add at() methods to a range class.
Add to a range class conversions to containers.