Vowpal Wabbit
Public Member Functions | Private Attributes | List of all members
example_predict::iterator Class Reference

#include <example_predict.h>

Public Member Functions

 iterator (features *feature_space, namespace_index *index)
 
featuresoperator* ()
 
iteratoroperator++ ()
 
namespace_index index ()
 
bool operator== (const iterator &rhs)
 
bool operator!= (const iterator &rhs)
 

Private Attributes

features_feature_space
 
namespace_index_index
 

Detailed Description

Definition at line 18 of file example_predict.h.

Constructor & Destructor Documentation

◆ iterator()

example_predict::iterator::iterator ( features feature_space,
namespace_index index 
)
inline

Definition at line 24 of file example_predict.h.

Referenced by example_predict::begin(), and example_predict::end().

24 : _feature_space(feature_space), _index(index) {}
namespace_index * _index
namespace_index index()

Member Function Documentation

◆ index()

namespace_index example_predict::iterator::index ( )
inline

Definition at line 34 of file example_predict.h.

References _index.

34 { return *_index; }
namespace_index * _index

◆ operator!=()

bool example_predict::iterator::operator!= ( const iterator rhs)
inline

Definition at line 37 of file example_predict.h.

References _index.

37 { return _index != rhs._index; }
namespace_index * _index

◆ operator*()

features& example_predict::iterator::operator* ( )
inline

Definition at line 26 of file example_predict.h.

References _index.

26 { return _feature_space[*_index]; }
namespace_index * _index

◆ operator++()

iterator& example_predict::iterator::operator++ ( )
inline

Definition at line 28 of file example_predict.h.

29  {
30  _index++;
31  return *this;
32  }
namespace_index * _index

◆ operator==()

bool example_predict::iterator::operator== ( const iterator rhs)
inline

Definition at line 36 of file example_predict.h.

References _index.

36 { return _index == rhs._index; }
namespace_index * _index

Member Data Documentation

◆ _feature_space

features* example_predict::iterator::_feature_space
private

Definition at line 20 of file example_predict.h.

◆ _index

namespace_index* example_predict::iterator::_index
private

Definition at line 21 of file example_predict.h.

Referenced by index(), operator!=(), operator*(), and operator==().


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