Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Friends

SparseVector< Value >::SparseVectorIterator Class Reference

random access iterator for SparseVector including the hop() function to jump to the next non-sparse element More...

#include <OpenMS/DATASTRUCTURES/SparseVector.h>

List of all members.

Public Member Functions

 SparseVectorIterator (const SparseVectorIterator &source)
 copy constructor
virtual ~SparseVectorIterator ()
 destructor
SparseVectorIteratoroperator= (const SparseVectorIterator &source)
 assignment operator
SparseVectorIteratoroperator++ ()
 prefix increment
SparseVectorIterator operator++ (int)
 postfix increment
SparseVectorIteratoroperator-- ()
 prefix decrement
SparseVectorIterator operator-- (int)
 postfix decrement
ValueProxy operator* ()
 dereference operator
const Value operator* () const
 const dereference operator
ValueProxy operator[] (size_type n)
 indexing
SparseVectorIteratoroperator+= (const size_type rhs)
 compound assignment +
SparseVectorIteratoroperator-= (const size_type rhs)
 compound assignment -
SparseVectorIterator operator+ (const size_type rhs) const
 binary arithmetic +
difference_type operator+ (const SparseVectorIterator rhs) const
 binary arithmetic +
SparseVectorIterator operator- (const size_type rhs) const
 binary arithmetic -
difference_type operator- (const SparseVectorIterator rhs) const
 binary arithmetic -
bool operator!= (const SparseVectorIterator &other)
 inequality operator
bool operator== (const SparseVectorIterator &other)
 equality operator
bool operator< (const SparseVectorIterator &other)
 less than operator
bool operator> (const SparseVectorIterator &other)
 greater than operator
bool operator<= (const SparseVectorIterator &other)
 less or equal than operator
bool operator>= (const SparseVectorIterator &other)
 greater or equal than operator
SparseVectorIteratorhop ()
 go to the next nonempty position
size_type position () const
 find out at what position the iterator is; useful in combination with hop()

Protected Member Functions

 SparseVectorIterator (SparseVector &vector, size_type position)

Protected Attributes

size_type position_
 the position in the referred SparseVector
SparseVectorvector_
 the referred SparseVector
map_const_iterator valit_
 the position in the underlying map of SparseVector

Private Member Functions

 SparseVectorIterator ()
 Not implemented => private.

Friends

class SparseVector< Value >
class SparseVectorConstIterator

Detailed Description

template<typename Value>
class OpenMS::SparseVector< Value >::SparseVectorIterator

random access iterator for SparseVector including the hop() function to jump to the next non-sparse element


Constructor & Destructor Documentation

SparseVectorIterator ( const SparseVectorIterator source  )  [inline]

copy constructor

virtual ~SparseVectorIterator (  )  [inline, virtual]

destructor

SparseVectorIterator ( SparseVector vector,
size_type  position 
) [inline, protected]
SparseVectorIterator (  )  [private]

Member Function Documentation

SparseVectorIterator& hop (  )  [inline]
bool operator!= ( const SparseVectorIterator other  )  [inline]
ValueProxy operator* (  )  [inline]
const Value operator* (  )  const [inline]
SparseVectorIterator operator+ ( const size_type  rhs  )  const [inline]
difference_type operator+ ( const SparseVectorIterator  rhs  )  const [inline]
SparseVectorIterator operator++ ( int   )  [inline]
SparseVectorIterator& operator++ (  )  [inline]
SparseVectorIterator& operator+= ( const size_type  rhs  )  [inline]

compound assignment +

References SparseVector< Value >::SparseVectorIterator::position_.

SparseVectorIterator operator- ( const size_type  rhs  )  const [inline]
difference_type operator- ( const SparseVectorIterator  rhs  )  const [inline]
SparseVectorIterator& operator-- (  )  [inline]
SparseVectorIterator operator-- ( int   )  [inline]
SparseVectorIterator& operator-= ( const size_type  rhs  )  [inline]

compound assignment -

References SparseVector< Value >::SparseVectorIterator::position_.

bool operator< ( const SparseVectorIterator other  )  [inline]
bool operator<= ( const SparseVectorIterator other  )  [inline]
SparseVectorIterator& operator= ( const SparseVectorIterator source  )  [inline]
bool operator== ( const SparseVectorIterator other  )  [inline]

equality operator

bool operator> ( const SparseVectorIterator other  )  [inline]
bool operator>= ( const SparseVectorIterator other  )  [inline]
ValueProxy operator[] ( size_type  n  )  [inline]
size_type position (  )  const [inline]

Friends And Related Function Documentation

friend class SparseVector< Value > [friend]
friend class SparseVectorConstIterator [friend]

Member Data Documentation

size_type position_ [protected]
SparseVector& vector_ [protected]

OpenMS / TOPP release 1.10.0 Documentation generated on Thu Mar 7 2013 09:42:53 using doxygen 1.7.1