LArSoft
v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
|
Base forward iterator browsing all cryostat IDs in the detector. More...
#include "geometry_iterators.h"
Public Types | |
using | GeoID_t = typename upper_iterator::GeoID_t |
using | LocalID_t = LocalID |
type of the ID we change More... | |
using | iterator = id_iterator_base< LocalID_t, GeoID_t > |
type of this iterator More... | |
Iterator traits | |
using | difference_type = std::ptrdiff_t |
using | value_type = LocalID_t |
using | reference = value_type const & |
using | pointer = value_type const * |
using | iterator_category = std::forward_iterator_tag |
Public Member Functions | |
id_iterator_base ()=default | |
Default constructor; effect not defined: assign to it before using! More... | |
id_iterator_base (GeometryCore const *geo, GeoID_t const &start_from) | |
Constructor: points to the specified element. More... | |
bool | operator== (id_iterator_base const &as) const |
Returns true if the two iterators point to the same element. More... | |
bool | operator!= (id_iterator_base const &as) const |
Returns true if the two iterators point to different elements. More... | |
reference | operator* () const |
Returns the element ID the iterator points to. More... | |
pointer | operator-> () const |
Returns the element ID the iterator points to. More... | |
iterator & | operator++ () |
Prefix increment: returns this iterator pointing to the next element. More... | |
iterator | operator++ (int) |
Postfix increment: returns the current iterator, then increments it. More... | |
Protected Types | |
using | ID_t = std::remove_reference_t< decltype(std::declval< LocalID_t >().deepestIndex())> |
specific type for element ID More... | |
Protected Member Functions | |
LocalID_t const & | localID () const |
Returns the type of ID we act on. More... | |
void | next () |
Skips to the next element. More... | |
ID_t const & | local_index () const |
Returns the index (part if the ID) this iterator runs on. More... | |
Private Types | |
using | upper_iterator = id_iterator_base< typename LocalID::ParentID_t, GEOID > |
Private Member Functions | |
LocalID_t & | localID () |
Returns the type of ID we act on (non-const version) More... | |
ID_t & | local_index () |
Returns the index (part if the ID) this iterator runs on (non-const) More... | |
Private Attributes | |
geo::GeometryCore const * | geom |
ID_t | limit = LocalID_t::InvalidID |
maximum number of elements in the current cryostat More... | |
Base forward iterator browsing all cryostat IDs in the detector.
Base forward iterator browsing all TPC IDs in the detector.
GEOID | ID type to be used |
This iterator assumes that GEOID is derived from geo::CryostatID. Note that no polymorphic behaviour is required, or expected, from GEOID.
This iterator is designed to carry on, untouched, anything else that the GEOID type defines beyond the required CryostatID data.
Currently, backward iterations are not supported.
GEOID | ID type to be used |
This iterator requires that GEOID is derived from geo::TPCID. Note that no polymorphic behaviour is required, or expected, from GEOID.
This iterator is designed to carry on, untouched, anything else that the GEOID type defines beyond the required TPCID data.
Currently, backward iterations are not supported.
Definition at line 48 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::difference_type = std::ptrdiff_t |
Definition at line 171 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::GeoID_t = typename upper_iterator::GeoID_t |
Definition at line 162 of file geometry_iterators.h.
|
protected |
specific type for element ID
Definition at line 218 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::iterator = id_iterator_base<LocalID_t, GeoID_t> |
type of this iterator
Definition at line 167 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::iterator_category = std::forward_iterator_tag |
Definition at line 175 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::LocalID_t = LocalID |
type of the ID we change
Definition at line 164 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::pointer = value_type const* |
Definition at line 174 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::reference = value_type const& |
Definition at line 173 of file geometry_iterators.h.
|
private |
Definition at line 159 of file geometry_iterators.h.
using geo::details::id_iterator_base< LocalID, GEOID >::value_type = LocalID_t |
Definition at line 172 of file geometry_iterators.h.
|
default |
Default constructor; effect not defined: assign to it before using!
|
inline |
Constructor: points to the specified element.
Definition at line 182 of file geometry_iterators.h.
References geo::details::NSiblings().
|
inlineprotected |
Returns the index (part if the ID) this iterator runs on.
Definition at line 240 of file geometry_iterators.h.
|
inlineprivate |
Returns the index (part if the ID) this iterator runs on (non-const)
Definition at line 251 of file geometry_iterators.h.
|
inlineprotected |
Returns the type of ID we act on.
Definition at line 215 of file geometry_iterators.h.
Referenced by geo::details::id_iterator_base< CryostatID, GEOID >::operator!=(), geo::details::id_iterator_base< CryostatID, GEOID >::operator==(), and geo::details::id_iterator_base< LocalID, GEOID >::operator==().
|
inlineprivate |
Returns the type of ID we act on (non-const version)
Definition at line 248 of file geometry_iterators.h.
|
inlineprotected |
Skips to the next element.
Definition at line 221 of file geometry_iterators.h.
References geo::details::NSiblings().
|
inline |
Returns true if the two iterators point to different elements.
Definition at line 190 of file geometry_iterators.h.
References geo::operator==().
|
inline |
Returns the element ID the iterator points to.
Definition at line 193 of file geometry_iterators.h.
|
inline |
Prefix increment: returns this iterator pointing to the next element.
Definition at line 199 of file geometry_iterators.h.
|
inline |
Postfix increment: returns the current iterator, then increments it.
Definition at line 206 of file geometry_iterators.h.
|
inline |
Returns the element ID the iterator points to.
Definition at line 196 of file geometry_iterators.h.
|
inline |
Returns true if the two iterators point to the same element.
Definition at line 187 of file geometry_iterators.h.
References geo::details::id_iterator_base< LocalID, GEOID >::localID().
|
private |
Definition at line 243 of file geometry_iterators.h.
|
private |
maximum number of elements in the current cryostat
Definition at line 245 of file geometry_iterators.h.