ATLAS Offline Software
Public Member Functions | Protected Attributes | Private Member Functions | Friends | List of all members
pool::TokenList::iterator Class Reference

Forward iterator class for navigation of TokenList objects. More...

#include <TokenList.h>

Inheritance diagram for pool::TokenList::iterator:
Collaboration diagram for pool::TokenList::iterator:

Public Member Functions

 ~iterator ()
 
 iterator (const iterator_base &rhs)
 
iteratoroperator= (const iterator_base &rhs)
 
Tokenoperator-> ()
 
Tokenoperator* ()
 
iteratoroperator++ ()
 
bool operator== (const iterator_base &rhs) const
 
bool operator!= (const iterator_base &rhs) const
 
bool next ()
 
const std::string & tokenName () const
 

Protected Attributes

const TokenListm_list
 
size_t m_index
 

Private Member Functions

 iterator (TokenList *list, size_t idx=0)
 

Friends

class TokenList
 

Detailed Description

Forward iterator class for navigation of TokenList objects.

Definition at line 138 of file TokenList.h.

Constructor & Destructor Documentation

◆ ~iterator()

pool::TokenList::iterator::~iterator ( )
inline

Definition at line 142 of file TokenList.h.

142 {};

◆ iterator() [1/2]

pool::TokenList::iterator::iterator ( const iterator_base rhs)
inline

Definition at line 143 of file TokenList.h.

143 : iterator_base( rhs ) {}

◆ iterator() [2/2]

pool::TokenList::iterator::iterator ( TokenList list,
size_t  idx = 0 
)
inlineprivate

Definition at line 149 of file TokenList.h.

149 : iterator_base( list, idx ) {}

Member Function Documentation

◆ next()

bool pool::TokenList::iterator_base::next ( )
inlineinherited

Definition at line 125 of file TokenList.h.

125 { return ++m_index < m_list->size(); }

◆ operator!=()

bool pool::TokenList::iterator_base::operator!= ( const iterator_base rhs) const
inlineinherited

Definition at line 123 of file TokenList.h.

123 { return !(*this==rhs); }

◆ operator*()

Token& pool::TokenList::iterator::operator* ( )
inline

Definition at line 152 of file TokenList.h.

152 { return *operator->(); }

◆ operator++()

iterator& pool::TokenList::iterator::operator++ ( )
inline

Definition at line 153 of file TokenList.h.

153 { iterator_base::operator++(); return *this; }

◆ operator->()

Token* pool::TokenList::iterator::operator-> ( )
inline

Definition at line 151 of file TokenList.h.

151 { return m_list->m_tokenVector[ m_index ]; }

◆ operator=()

iterator& pool::TokenList::iterator::operator= ( const iterator_base rhs)
inline

Definition at line 144 of file TokenList.h.

144  {
145  iterator_base::operator=( rhs );
146  return *this;
147  }

◆ operator==()

bool pool::TokenList::iterator_base::operator== ( const iterator_base rhs) const
inlineinherited

Definition at line 120 of file TokenList.h.

120  {
121  return m_list == rhs.m_list && m_index == rhs.m_index;
122  }

◆ tokenName()

const std::string& pool::TokenList::iterator_base::tokenName ( ) const
inlineinherited

Definition at line 126 of file TokenList.h.

126 { return m_list->m_tokenNames[ m_index ]; }

Friends And Related Function Documentation

◆ TokenList

friend class TokenList
friend

Definition at line 141 of file TokenList.h.

Member Data Documentation

◆ m_index

size_t pool::TokenList::iterator_base::m_index
protectedinherited

Definition at line 134 of file TokenList.h.

◆ m_list

const TokenList* pool::TokenList::iterator_base::m_list
protectedinherited

Definition at line 133 of file TokenList.h.


The documentation for this class was generated from the following file:
pool::TokenList::iterator_base::m_list
const TokenList * m_list
Definition: TokenList.h:133
pool::TokenList::m_tokenNames
std::vector< std::string > m_tokenNames
Token names.
Definition: TokenList.h:193
pool::TokenList::size
size_t size() const
Returns the size of the Token list.
Definition: TokenList.h:206
histSizes.list
def list(name, path='/')
Definition: histSizes.py:38
pool::TokenList::iterator_base::m_index
size_t m_index
Definition: TokenList.h:134
pool::TokenList::iterator_base::operator++
void operator++()
Definition: TokenList.h:124
pool::TokenList::iterator::operator->
Token * operator->()
Definition: TokenList.h:151
pool::TokenList::iterator_base::iterator_base
iterator_base(const TokenList *list, size_t idx=0)
Definition: TokenList.h:128
LArNewCalib_DelayDump_OFC_Cali.idx
idx
Definition: LArNewCalib_DelayDump_OFC_Cali.py:69
pool::TokenList::m_tokenVector
std::vector< Token * > m_tokenVector
Token vector (corresponding to m_tokenNames)
Definition: TokenList.h:196