ATLAS Offline Software
|
Proxy for a span of ElementLinks
.
More...
#include <ELProxy.h>
Public Types | |
using | Base = ELSpanProxyBase< CONT, PLINK_ALLOC > |
Base class of this one, holding the actual span. More... | |
using | PLink_t = SG::PackedLink< CONT > |
The PackedLink class we proxy. More... | |
using | Link_t = ElementLink< CONT > |
The ElementLink class we resolve to. More... | |
using | PackedLink_span = detail::PackedLink_span< CONT, PLINK_ALLOC > |
A span over PackedLink . More... | |
using | VElt_t = std::vector< SG::PackedLink< CONT >, PLINK_ALLOC > |
The vector of @PackedLink that we proxy. More... | |
using | iterator = std::ranges::iterator_t< Base > |
Iterator type for this range. More... | |
Public Member Functions | |
ELSpanProxy (VElt_t &velt, AuxVectorData &container, SG::auxid_t auxid, SG::auxid_t linked_auxid) | |
Constructor. More... | |
template<ElementLinkRange< CONT > RANGE> | |
void | operator= (const RANGE &r) |
Assign from a range of ElementLink . More... | |
template<class VALLOC > | |
operator std::vector< Link_t, VALLOC > () const | |
Convert to a vector of ElementLink . More... | |
std::vector< Link_t > | asVector () const |
Convert to a vector of ElementLink . More... | |
template<class VALLOC > | |
bool | operator== (const std::vector< Link_t, VALLOC > &v) const |
Equality testing. More... | |
void | push_back (const Link_t &l) |
Add a new link to this vector of links. More... | |
void | clear () |
Clear this vector of links. More... | |
void | resize (size_t n, const Link_t &l=Link_t()) |
Resize this vector of links. More... | |
void | erase (iterator pos) |
Erase one element from this vector of links. More... | |
void | erase (iterator first, iterator last) |
Erase a range of elements from this vector of links. More... | |
void | insert (iterator pos, const Link_t &l) |
Insert a new link into this vector of links. More... | |
void | insert (iterator pos, size_t n, const Link_t &l) |
Insert copies of a new link into this vector of links. More... | |
template<CxxUtils::detail::InputValIterator< ElementLink< CONT > > ITERATOR> | |
void | insert (iterator pos, ITERATOR first, ITERATOR last) |
Insert a range of links into this vector of links. More... | |
template<ElementLinkRange< CONT > RANGE> | |
void | insert_range (iterator pos, const RANGE &range) |
Insert a range of links into this vector of links. More... | |
template<ElementLinkRange< CONT > RANGE> | |
void | append_range (const RANGE &range) |
Append a range of links to the end of this vector of links. More... | |
void | pop_back () |
Remove the last element in this vector of links. More... | |
void | assign (size_t n, const Link_t &l) |
Set this vector of links to copies of a new link. More... | |
template<CxxUtils::detail::InputValIterator< ElementLink< CONT > > ITERATOR> | |
void | assign (ITERATOR first, ITERATOR last) |
Set this vector of links to a range of links. More... | |
template<ElementLinkRange< CONT > RANGE> | |
void | assign_range (const RANGE &range) |
Set this vector of links to a range of links. More... | |
decltype(auto) | at (size_t i) |
decltype(auto) | at (size_t i) const |
Private Attributes | |
VElt_t & | m_velt |
The vector of PackedLink that we proxy. More... | |
ELProxyInSpanConverter< CONT > | m_cnv |
The converter to use for the span. More... | |
Proxy for a span of ElementLinks
.
This class proxies a vector of PackedLink
. It acts as a span which returns ElementLink
proxies, allowing the span elements to be read and written as ElementLink
.
We also allow assignment from a range of ElementLink
and conversion to a vector of ElementLink
.
The proxies we return will reference the needed PackedLinkConverter
by reference. The actual instance is stored by value in this class.
Here, CONT
is the type of the storable container that we reference, and PLINK_ALLOC
is the allocator type for the vector over PackedLinks
.
using SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::Base = ELSpanProxyBase<CONT, PLINK_ALLOC> |
using SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::iterator = std::ranges::iterator_t<Base> |
using SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::Link_t = ElementLink<CONT> |
The ElementLink
class we resolve to.
using SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::PackedLink_span = detail::PackedLink_span<CONT, PLINK_ALLOC> |
using SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::PLink_t = SG::PackedLink<CONT> |
using SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::VElt_t = std::vector<SG::PackedLink<CONT>, PLINK_ALLOC> |
SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::ELSpanProxy | ( | VElt_t & | velt, |
AuxVectorData & | container, | ||
SG::auxid_t | auxid, | ||
SG::auxid_t | linked_auxid | ||
) |
Constructor.
velt | The vector of PackedLink that we proxy. @proxy container Container holding the variables. |
auxid | The ID of the PackedLink variable. |
linked_auxid | The ID of the linked DataLinks. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::append_range | ( | const RANGE & | range | ) |
Append a range of links to the end of this vector of links.
range | The range to append. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::assign | ( | ITERATOR | first, |
ITERATOR | last | ||
) |
Set this vector of links to a range of links.
first | The first element to copy. |
last | One past the last element to copy. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::assign | ( | size_t | n, |
const Link_t & | l | ||
) |
Set this vector of links to copies of a new link.
n | Number of copies to insert. |
l | The link(s) to insert. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::assign_range | ( | const RANGE & | range | ) |
Set this vector of links to a range of links.
range | The range of links to copy. |
last | One past the last element to copy. |
std::vector<Link_t> SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::asVector | ( | ) | const |
Convert to a vector of ElementLink
.
|
inlineinherited |
Definition at line 38 of file range_with_at.h.
|
inlineinherited |
Definition at line 46 of file range_with_at.h.
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::clear | ( | ) |
Clear this vector of links.
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::erase | ( | iterator | first, |
iterator | last | ||
) |
Erase a range of elements from this vector of links.
first | The first element to erase. |
last | One past the last element to erase. |
pos | The element to erase. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::erase | ( | iterator | pos | ) |
Erase one element from this vector of links.
pos | The element to erase. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::insert | ( | iterator | pos, |
const Link_t & | l | ||
) |
Insert a new link into this vector of links.
pos | The position at which to insert the link. |
l | The link to insert. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::insert | ( | iterator | pos, |
ITERATOR | first, | ||
ITERATOR | last | ||
) |
Insert a range of links into this vector of links.
pos | The position at which to insert the links. |
first | The first element to insert. |
last | One past the last element to insert. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::insert | ( | iterator | pos, |
size_t | n, | ||
const Link_t & | l | ||
) |
Insert copies of a new link into this vector of links.
pos | The position at which to insert the link. |
n | Number of copies to insert. |
l | The link(s) to insert. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::insert_range | ( | iterator | pos, |
const RANGE & | range | ||
) |
Insert a range of links into this vector of links.
pos | The position at which to insert the links. |
range | The range to insert. |
SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::operator std::vector< Link_t, VALLOC > | ( | ) | const |
Convert to a vector of ElementLink
.
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::operator= | ( | const RANGE & | r | ) |
Assign from a range of ElementLink
.
r | The range from which to assign. |
bool SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::operator== | ( | const std::vector< Link_t, VALLOC > & | v | ) | const |
Equality testing.
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::pop_back | ( | ) |
Remove the last element in this vector of links.
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::push_back | ( | const Link_t & | l | ) |
Add a new link to this vector of links.
l | The new link to add. |
void SG::detail::ELSpanProxy< CONT, PLINK_ALLOC >::resize | ( | size_t | n, |
const Link_t & | l = Link_t() |
||
) |
Resize this vector of links.
n | The desired new size. |
l | Value with which to fill any new elements. |
|
private |
|
private |