VPTissue Reference Manual
SimPT_Sim::Container Namespace Reference

Namespace for container related classes. More...

Namespaces

 Impl_
 Namespace for container implementation details.
 

Classes

class  SegmentedVector
 Container that stores objects "almost contiguously" and guarantees that pointers/iterators are not invalidated when the container grows. More...
 
class  SVIterator
 Implementation of iterator for SegmentedVector. More...
 

Typedefs

template<typename T >
using CircularIterator = Impl_::CircularIterator< T, typename T::value_type >
 Alias template defines non-const circular iterator. More...
 
template<typename T >
using ConstCircularIterator = Impl_::CircularIterator< T, typename std::add_const< typename T::value_type >::type, typename std::add_const< typename T::value_type >::type *, typename std::add_const< typename T::value_type >::type & >
 Alias template defines const circular iterator. More...
 

Functions

template<typename T >
CircularIterator< typename T::iterator > make_circular (T &c)
 Helper produces non-const circular iterator whose range corresponds to the begin and end iterators of a container. More...
 
template<typename T >
CircularIterator< typename T::iterator > make_circular (T &c, typename T::iterator i)
 Helper produces non-const circular iterator whose range corresponds to the begin and end iterators of a container. More...
 
template<typename T >
CircularIterator< T > make_circular (T b, T e, T i)
 Helper produces non-const circular iterator with specified range and initial value. More...
 
template<typename T >
CircularIterator< T > make_circular (T b, T e)
 Helper produces non-const circular iterator with specified range with initial value at start of the range. More...
 
template<typename T >
ConstCircularIterator< typename T::const_iterator > make_const_circular (const T &c)
 Helper produces const circular iterator whose range corresponds to the begin and end iterators of a container. More...
 
template<typename T >
ConstCircularIterator< typename T::const_iterator > make_const_circular (const T &c, typename T::const_iterator i)
 Helper produces const circular iterator whose range corresponds to the begin and end iterators of a container. More...
 
template<typename T >
ConstCircularIterator< T > make_const_circular (T b, T e, T i)
 Helper produces non-const circular iterator with specified range and initial value. More...
 
template<typename T >
ConstCircularIterator< T > make_const_circular (T b, T e)
 Helper produces non-const circular iterator with specified range, with initial value at the start of the range. More...
 
template<typename T >
CircularIterator< T > next (CircularIterator< T > i)
 Helper yields the position the iterator would have if moved forward (in circular fashion) by 1 position. More...
 
template<typename T >
ConstCircularIterator< T > next (ConstCircularIterator< T > c)
 Helper yields the position the iterator would have if moved forward (in circular fashion) by 1 position. More...
 
template<typename T >
CircularIterator< T > prev (CircularIterator< T > i)
 Helper yields the position the iterator would have if moved backward (in circular fashion) by 1 position. More...
 
template<typename T >
ConstCircularIterator< T > prev (ConstCircularIterator< T > c)
 Helper yields the position the iterator would have if moved backward (in circular fashion) by 1 position. More...
 

Detailed Description

Namespace for container related classes.

Typedef Documentation

template<typename T >
using SimPT_Sim::Container::CircularIterator = typedef Impl_::CircularIterator<T, typename T::value_type>

Alias template defines non-const circular iterator.

See also
Impl_::CircularIterator

Definition at line 34 of file CircularIterator.h.

template<typename T >
using SimPT_Sim::Container::ConstCircularIterator = typedef Impl_::CircularIterator<T, typename std::add_const<typename T::value_type>::type, typename std::add_const<typename T::value_type>::type*, typename std::add_const<typename T::value_type>::type&>

Alias template defines const circular iterator.

See also
Impl_::CircularIterator

Definition at line 38 of file ConstCircularIterator.h.

Function Documentation

template<typename T >
CircularIterator<typename T::iterator> SimPT_Sim::Container::make_circular ( T &  c)

Helper produces non-const circular iterator whose range corresponds to the begin and end iterators of a container.

Parameters
ccontainer
Returns
CircularIterator pointing to beginning of container

Definition at line 43 of file CircularIterator.h.

Referenced by SimPT_Sim::MeshCheck::CheckCellBoundaryWallNodes(), SimPT_Editor::EditableMesh::ReplaceCell(), SimPT_Sim::Mesh::UpdateNodeOwningNeighbors(), and SimPT_Sim::Mesh::UpdateNodeOwningWalls().

Here is the caller graph for this function:

template<typename T >
CircularIterator<typename T::iterator> SimPT_Sim::Container::make_circular ( T &  c,
typename T::iterator  i 
)

Helper produces non-const circular iterator whose range corresponds to the begin and end iterators of a container.

Parameters
ccontainer
Returns
CircularIterator pointing to beginning of container

Definition at line 56 of file CircularIterator.h.

template<typename T >
CircularIterator<T> SimPT_Sim::Container::make_circular ( b,
e,
i 
)

Helper produces non-const circular iterator with specified range and initial value.

Parameters
biterator pointing to beginning of range
eiterator pointing to end of range
iinitial position of the iterator

Definition at line 70 of file CircularIterator.h.

template<typename T >
CircularIterator<T> SimPT_Sim::Container::make_circular ( b,
e 
)

Helper produces non-const circular iterator with specified range with initial value at start of the range.

Parameters
biterator pointing to beginning of range
eiterator pointing to end of range

Definition at line 82 of file CircularIterator.h.

template<typename T >
ConstCircularIterator<typename T::const_iterator> SimPT_Sim::Container::make_const_circular ( const T &  c,
typename T::const_iterator  i 
)

Helper produces const circular iterator whose range corresponds to the begin and end iterators of a container.

Parameters
ccontainer
Returns
CircularIterator pointing to beginning of container

Definition at line 59 of file ConstCircularIterator.h.

template<typename T >
ConstCircularIterator<T> SimPT_Sim::Container::make_const_circular ( b,
e,
i 
)

Helper produces non-const circular iterator with specified range and initial value.

Parameters
biterator pointing to beginning of range
eiterator pointing to end of range
iinitial position of the iterator

Definition at line 72 of file ConstCircularIterator.h.

template<typename T >
ConstCircularIterator<T> SimPT_Sim::Container::make_const_circular ( b,
e 
)

Helper produces non-const circular iterator with specified range, with initial value at the start of the range.

Parameters
biterator pointing to beginning of range
eiterator pointing to end of range

Definition at line 84 of file ConstCircularIterator.h.

template<typename T >
CircularIterator<T> SimPT_Sim::Container::next ( CircularIterator< T >  i)
template<typename T >
ConstCircularIterator<T> SimPT_Sim::Container::next ( ConstCircularIterator< T >  c)

Helper yields the position the iterator would have if moved forward (in circular fashion) by 1 position.

Parameters
icurrent iterator position
Returns
one position forward

Definition at line 96 of file ConstCircularIterator.h.

template<typename T >
CircularIterator<T> SimPT_Sim::Container::prev ( CircularIterator< T >  i)

Helper yields the position the iterator would have if moved backward (in circular fashion) by 1 position.

Parameters
icurrent iterator position
Returns
one position backward

Definition at line 107 of file CircularIterator.h.

Referenced by SimPT_Default::Hamiltonian::HHelper::BendingTerm(), SimPT_Sim::MeshCheck::CheckNodeOwningNeighbors(), SimPT_Editor::PolygonUtils::ClipPolygon(), SimPT_Editor::EditableMesh::CreateCell(), SimPT_Editor::EditableMesh::DeleteCells(), SimPT_Sim::Cell::MoveSelfIntersects(), SimPT_Editor::UndoStack::Push(), SimPT_Editor::PolygonUtils::SlicePolygon(), and SimPT_Sim::Mesh::UpdateNodeOwningNeighbors().

Here is the caller graph for this function:

template<typename T >
ConstCircularIterator<T> SimPT_Sim::Container::prev ( ConstCircularIterator< T >  c)

Helper yields the position the iterator would have if moved backward (in circular fashion) by 1 position.

Parameters
icurrent iterator position
Returns
one position backward

Definition at line 109 of file ConstCircularIterator.h.