FlashGraph-ng
A new frontier in large-scale graph analysis and data mining
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
Public Member Functions | List of all members
safs::page_byte_array::const_iterator< T > Class Template Reference

#include <cache.h>

Inherits iterator< std::random_access_iterator_tag, T >.

Public Member Functions

operator* () const
 
difference_type operator- (const const_iterator< T > &it) const
 
const_iterator< T > operator+ (size_t num) const
 
const_iterator< T > & operator++ ()
 
bool operator== (const const_iterator< T > &it) const
 
bool operator!= (const const_iterator< T > &it) const
 
const_iterator< T > & operator+= (size_t num)
 

Detailed Description

template<class T>
class safs::page_byte_array::const_iterator< T >

This is a STL-compatile iterator. Users can redefine the type of elements in the byte array and iterate the elements stored in the byte array. It overrides *, -, +, ++, ==, !=, += operators. It supports random access in the byte array.

Member Function Documentation

template<class T>
bool safs::page_byte_array::const_iterator< T >::operator!= ( const const_iterator< T > &  it) const
inline

Test whether the current iterator isn't the same as the other iterator.

Parameters
itthe other iterator.
Returns
true if they aren't the same.
template<class T>
T safs::page_byte_array::const_iterator< T >::operator* ( ) const
inline

This method gets the current element.

Returns
the current element.
template<class T>
const_iterator<T> safs::page_byte_array::const_iterator< T >::operator+ ( size_t  num) const
inline

This method creates a new iterator that points to a location the specified number of elements after the current iterator. The current iterator isn't changed.

Parameters
numthe number of elements after the current location.
Returns
the new iterator points to the new location.
template<class T>
const_iterator<T>& safs::page_byte_array::const_iterator< T >::operator++ ( )
inline

Move the current iterator forward by 1. This is prefix ++.

Returns
the reference to the current iterator.
template<class T>
const_iterator<T>& safs::page_byte_array::const_iterator< T >::operator+= ( size_t  num)
inline

This method moves the current iterator forward by the specified number.

Parameters
numthe number of elements that the current iterator is moved.
Returns
the reference to the current iterator.
template<class T>
difference_type safs::page_byte_array::const_iterator< T >::operator- ( const const_iterator< T > &  it) const
inline

This method calculates the distance between this iterator and another iterator.

Parameters
itthe other iterator.
Returns
the distance between the two iterators.
template<class T>
bool safs::page_byte_array::const_iterator< T >::operator== ( const const_iterator< T > &  it) const
inline

Test whether the current iterator is the same as the other iterator.

Parameters
itthe other iterator.
Returns
true if they are the same.

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