UPtrList< T >::iterator Class Reference

Random-access iterator with non-const access. More...

Public Types

using iterator_category = std::random_access_iterator_tag
 
using value_type = T
 
using difference_type = label
 
using pointer = T *
 
using reference = T &
 

Public Member Functions

 iterator (T **ptr) noexcept
 Construct for a given entry. More...
 
pointer get () const
 Return pointer, can be nullptr. More...
 
pointer operator-> () const
 
reference operator* () const
 
reference operator() () const
 
reference operator[] (difference_type n) const
 
iteratoroperator++ () noexcept
 
iterator operator++ (int) noexcept
 
iteratoroperator-- () noexcept
 
iterator operator-- (int) noexcept
 
iteratoroperator+= (difference_type n) noexcept
 
iteratoroperator-= (difference_type n) noexcept
 
iterator operator+ (difference_type n) const noexcept
 
iterator operator- (difference_type n) const noexcept
 
difference_type operator- (const iterator &iter) const noexcept
 
bool operator== (const iterator &iter) const noexcept
 
bool operator!= (const iterator &iter) const noexcept
 
bool operator< (const iterator &iter) const noexcept
 
bool operator> (const iterator &iter) const noexcept
 
bool operator<= (const iterator &iter) const noexcept
 
bool operator>= (const iterator &iter) const noexcept
 

Friends

class const_iterator
 

Detailed Description

template<class T>
class Foam::UPtrList< T >::iterator

Random-access iterator with non-const access.

Definition at line 322 of file UPtrList.H.

Member Typedef Documentation

◆ iterator_category

using iterator_category = std::random_access_iterator_tag

Definition at line 329 of file UPtrList.H.

◆ value_type

using value_type = T

Definition at line 330 of file UPtrList.H.

◆ difference_type

using difference_type = label

Definition at line 331 of file UPtrList.H.

◆ pointer

using pointer = T*

Definition at line 332 of file UPtrList.H.

◆ reference

using reference = T&

Definition at line 333 of file UPtrList.H.

Constructor & Destructor Documentation

◆ iterator()

iterator ( T **  ptr)
inlinenoexcept

Construct for a given entry.

Definition at line 277 of file UPtrListI.H.

Member Function Documentation

◆ get()

T * get
inline

Return pointer, can be nullptr.

Definition at line 285 of file UPtrListI.H.

◆ operator->()

T * operator->
inline

Definition at line 292 of file UPtrListI.H.

◆ operator*()

T & operator*
inline

Definition at line 299 of file UPtrListI.H.

Referenced by UPtrList< T >::iterator::operator()(), and UPtrList< T >::const_iterator::operator()().

Here is the caller graph for this function:

◆ operator()()

reference operator() ( ) const
inline

Definition at line 349 of file UPtrList.H.

References UPtrList< T >::iterator::operator*().

Here is the call graph for this function:

◆ operator[]()

T & operator[] ( difference_type  n) const
inline

Definition at line 306 of file UPtrListI.H.

◆ operator++() [1/2]

Foam::UPtrList< T >::iterator & operator++
inlinenoexcept

Definition at line 313 of file UPtrListI.H.

◆ operator++() [2/2]

Foam::UPtrList< T >::iterator operator++ ( int  )
inlinenoexcept

Definition at line 322 of file UPtrListI.H.

◆ operator--() [1/2]

Foam::UPtrList< T >::iterator & operator--
inlinenoexcept

Definition at line 332 of file UPtrListI.H.

◆ operator--() [2/2]

Foam::UPtrList< T >::iterator operator-- ( int  )
inlinenoexcept

Definition at line 341 of file UPtrListI.H.

◆ operator+=()

Foam::UPtrList< T >::iterator & operator+= ( difference_type  n)
inlinenoexcept

Definition at line 351 of file UPtrListI.H.

◆ operator-=()

Foam::UPtrList< T >::iterator & operator-= ( difference_type  n)
inlinenoexcept

Definition at line 360 of file UPtrListI.H.

◆ operator+()

Foam::UPtrList< T >::iterator operator+ ( difference_type  n) const
inlinenoexcept

Definition at line 369 of file UPtrListI.H.

◆ operator-() [1/2]

Foam::UPtrList< T >::iterator operator- ( difference_type  n) const
inlinenoexcept

Definition at line 377 of file UPtrListI.H.

References n.

◆ operator-() [2/2]

Foam::label operator- ( const iterator iter) const
inlinenoexcept

Definition at line 385 of file UPtrListI.H.

◆ operator==()

bool operator== ( const iterator iter) const
inlinenoexcept

Definition at line 393 of file UPtrListI.H.

◆ operator!=()

bool operator!= ( const iterator iter) const
inlinenoexcept

Definition at line 401 of file UPtrListI.H.

◆ operator<()

bool operator< ( const iterator iter) const
inlinenoexcept

Definition at line 409 of file UPtrListI.H.

◆ operator>()

bool operator> ( const iterator iter) const
inlinenoexcept

Definition at line 417 of file UPtrListI.H.

◆ operator<=()

bool operator<= ( const iterator iter) const
inlinenoexcept

Definition at line 425 of file UPtrListI.H.

◆ operator>=()

bool operator>= ( const iterator iter) const
inlinenoexcept

Definition at line 433 of file UPtrListI.H.

Friends And Related Function Documentation

◆ const_iterator

friend class const_iterator
friend

Definition at line 334 of file UPtrList.H.


The documentation for this class was generated from the following files: