walberla::pe::ConstRigidBodyIterator Class Reference

#include <RigidBodyIterator.h>

Public Types

using ContainerType = std::vector< std::unique_ptr< RigidBody > >
 
using iterator_category = std::random_access_iterator_tag
 
using value_type = RigidBody const
 
using pointer = RigidBody const *
 
using reference = RigidBody const &
 
using difference_type = std::ptrdiff_t
 

Public Member Functions

Constructors
 ConstRigidBodyIterator ()=default
 
 ConstRigidBodyIterator (const RigidBodyIterator &it)
 
 ConstRigidBodyIterator (const typename ContainerType::iterator &it)
 
 ConstRigidBodyIterator (const typename ContainerType::const_iterator &it)
 
 ConstRigidBodyIterator (const ConstRigidBodyIterator &it)=default
 
 ConstRigidBodyIterator (ConstRigidBodyIterator &&it)=default
 
ConstRigidBodyIteratoroperator= (const ConstRigidBodyIterator &it)=default
 
ConstRigidBodyIteratoroperator= (ConstRigidBodyIterator &&it)=default
 
Operators
ConstRigidBodyIteratoroperator++ ()
 
ConstRigidBodyIterator operator++ (int)
 
ConstRigidBodyIteratoroperator-- ()
 
ConstRigidBodyIterator operator-- (int)
 
ConstRigidBodyIteratoroperator+= (difference_type n)
 
ConstRigidBodyIterator operator+ (difference_type n) const
 
ConstRigidBodyIteratoroperator-= (difference_type n)
 
ConstRigidBodyIterator operator- (difference_type n) const
 
difference_type operator- (const ConstRigidBodyIterator &it) const
 
Access operators
reference operator[] (difference_type n) const
 
reference operator* () const
 
pointer operator-> () const
 
Utility functions
pointer getBodyID () const
 
ContainerType::const_iterator get () const
 

Private Attributes

Member variables
ContainerType::const_iterator it_
 wrapped iterator More...
 

Friends

bool operator== (const ConstRigidBodyIterator &lhs, const ConstRigidBodyIterator &rhs)
 Equality comparison between two PtrIterator objects. More...
 
bool operator!= (const ConstRigidBodyIterator &lhs, const ConstRigidBodyIterator &rhs)
 Inequality comparison between two PtrIterator objects. More...
 
bool operator> (const ConstRigidBodyIterator &lhs, const ConstRigidBodyIterator &rhs)
 Greater-than comparison between two PtrIterator objects. More...
 
bool operator< (const ConstRigidBodyIterator &lhs, const ConstRigidBodyIterator &rhs)
 Less-than comparison between two PtrIterator objects. More...
 
bool operator>= (const ConstRigidBodyIterator &lhs, const ConstRigidBodyIterator &rhs)
 Greater-or-equal-than comparison between two PtrIterator objects. More...
 
bool operator<= (const ConstRigidBodyIterator &lhs, const ConstRigidBodyIterator &rhs)
 Less-or-equal-than comparison between two PtrIterator objects. More...
 

Member Typedef Documentation

◆ ContainerType

using walberla::pe::ConstRigidBodyIterator::ContainerType = std::vector< std::unique_ptr<RigidBody> >

◆ difference_type

◆ iterator_category

using walberla::pe::ConstRigidBodyIterator::iterator_category = std::random_access_iterator_tag

◆ pointer

◆ reference

◆ value_type

Constructor & Destructor Documentation

◆ ConstRigidBodyIterator() [1/6]

walberla::pe::ConstRigidBodyIterator::ConstRigidBodyIterator ( )
inlinedefault

◆ ConstRigidBodyIterator() [2/6]

walberla::pe::ConstRigidBodyIterator::ConstRigidBodyIterator ( const RigidBodyIterator it)
inline

◆ ConstRigidBodyIterator() [3/6]

walberla::pe::ConstRigidBodyIterator::ConstRigidBodyIterator ( const typename ContainerType::iterator &  it)
inlineexplicit

◆ ConstRigidBodyIterator() [4/6]

walberla::pe::ConstRigidBodyIterator::ConstRigidBodyIterator ( const typename ContainerType::const_iterator &  it)
inlineexplicit

◆ ConstRigidBodyIterator() [5/6]

walberla::pe::ConstRigidBodyIterator::ConstRigidBodyIterator ( const ConstRigidBodyIterator it)
default

◆ ConstRigidBodyIterator() [6/6]

walberla::pe::ConstRigidBodyIterator::ConstRigidBodyIterator ( ConstRigidBodyIterator &&  it)
default

Member Function Documentation

◆ get()

ContainerType::const_iterator walberla::pe::ConstRigidBodyIterator::get ( ) const
inline

◆ getBodyID()

pointer walberla::pe::ConstRigidBodyIterator::getBodyID ( ) const
inline

◆ operator*()

reference walberla::pe::ConstRigidBodyIterator::operator* ( ) const
inline

◆ operator+()

ConstRigidBodyIterator walberla::pe::ConstRigidBodyIterator::operator+ ( difference_type  n) const
inline

◆ operator++() [1/2]

ConstRigidBodyIterator& walberla::pe::ConstRigidBodyIterator::operator++ ( )
inline

◆ operator++() [2/2]

ConstRigidBodyIterator walberla::pe::ConstRigidBodyIterator::operator++ ( int  )
inline

◆ operator+=()

ConstRigidBodyIterator& walberla::pe::ConstRigidBodyIterator::operator+= ( difference_type  n)
inline

◆ operator-() [1/2]

difference_type walberla::pe::ConstRigidBodyIterator::operator- ( const ConstRigidBodyIterator it) const
inline

◆ operator-() [2/2]

ConstRigidBodyIterator walberla::pe::ConstRigidBodyIterator::operator- ( difference_type  n) const
inline

◆ operator--() [1/2]

ConstRigidBodyIterator& walberla::pe::ConstRigidBodyIterator::operator-- ( )
inline

◆ operator--() [2/2]

ConstRigidBodyIterator walberla::pe::ConstRigidBodyIterator::operator-- ( int  )
inline

◆ operator-=()

ConstRigidBodyIterator& walberla::pe::ConstRigidBodyIterator::operator-= ( difference_type  n)
inline

◆ operator->()

pointer walberla::pe::ConstRigidBodyIterator::operator-> ( ) const
inline

◆ operator=() [1/2]

ConstRigidBodyIterator& walberla::pe::ConstRigidBodyIterator::operator= ( const ConstRigidBodyIterator it)
default

◆ operator=() [2/2]

ConstRigidBodyIterator& walberla::pe::ConstRigidBodyIterator::operator= ( ConstRigidBodyIterator &&  it)
default

◆ operator[]()

reference walberla::pe::ConstRigidBodyIterator::operator[] ( difference_type  n) const
inline

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( const ConstRigidBodyIterator lhs,
const ConstRigidBodyIterator rhs 
)
friend

Inequality comparison between two PtrIterator objects.

Parameters
lhsThe left-hand side pointer iterator.
rhsThe right-hand side pointer iterator.
Returns
true if the iterators don't point to the same element, false if they do.

◆ operator<

bool operator< ( const ConstRigidBodyIterator lhs,
const ConstRigidBodyIterator rhs 
)
friend

Less-than comparison between two PtrIterator objects.

Parameters
lhsThe left-hand side pointer iterator.
rhsThe right-hand side pointer iterator.
Returns
true if the left-hand side iterator points to a lower element, false if not.

◆ operator<=

bool operator<= ( const ConstRigidBodyIterator lhs,
const ConstRigidBodyIterator rhs 
)
friend

Less-or-equal-than comparison between two PtrIterator objects.

Parameters
lhsThe left-hand side pointer iterator.
rhsThe right-hand side pointer iterator.
Returns
true if the left-hand side iterator points to a lower or the same element, false if not.

◆ operator==

bool operator== ( const ConstRigidBodyIterator lhs,
const ConstRigidBodyIterator rhs 
)
friend

Equality comparison between two PtrIterator objects.

Parameters
lhsThe left-hand side pointer iterator.
rhsThe right-hand side pointer iterator.
Returns
true if the iterators point to the same element, false if not.

◆ operator>

bool operator> ( const ConstRigidBodyIterator lhs,
const ConstRigidBodyIterator rhs 
)
friend

Greater-than comparison between two PtrIterator objects.

Parameters
lhsThe left-hand side pointer iterator.
rhsThe right-hand side pointer iterator.
Returns
true if the left-hand side iterator points to a higher element, false if not.

◆ operator>=

bool operator>= ( const ConstRigidBodyIterator lhs,
const ConstRigidBodyIterator rhs 
)
friend

Greater-or-equal-than comparison between two PtrIterator objects.

Parameters
lhsThe left-hand side pointer iterator.
rhsThe right-hand side pointer iterator.
Returns
true if the left-hand side iterator points to a higher or the same element, false if not.

Member Data Documentation

◆ it_

ContainerType::const_iterator walberla::pe::ConstRigidBodyIterator::it_
private

wrapped iterator


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