RVLAlg::CountTerminator Class Reference

This terminator contains an internal integer which it increments when called. More...

#include <scalarterm.hh>

Inheritance diagram for RVLAlg::CountTerminator:

RVLAlg::Terminator RVLAlg::CountingNormTable< Scalar > RVLAlg::CountingThresholdIterationTable< Scalar > RVLAlg::GradientThresholdIterationTable< Scalar > RVLAlg::VectorCountingThresholdIterationTable< Scalar > List of all members.

Public Member Functions

 CountTerminator (int maxcount)
 Initializes count to zero.
 CountTerminator (int init, int maxcount, int inc)
 Initializes count to init.
 ~CountTerminator ()
virtual bool query ()
int getCount ()

Protected Attributes

int mc
int count
int i

Detailed Description

This terminator contains an internal integer which it increments when called.

After incrementing, the integer is compared to a maximum value. Stops when $count \geq maxcount$.

Definition at line 52 of file scalarterm.hh.


Constructor & Destructor Documentation

RVLAlg::CountTerminator::CountTerminator ( int  maxcount  ) 

Initializes count to zero.

When query is called, increments count by 1 and then tests to see if maxcount has been reached.

returns true when count == maxcount

false when count < maxcount

Definition at line 63 of file scalarterm.hh.

RVLAlg::CountTerminator::CountTerminator ( int  init,
int  maxcount,
int  inc 
)

Initializes count to init.

When query is called, increments count by inc and then tests to see if maxcount has been reached.

returns true when count >= maxcount

false when count < maxcount

throws an error if inc is moving count away from maxcount

Definition at line 75 of file scalarterm.hh.

RVLAlg::CountTerminator::~CountTerminator (  ) 

Definition at line 83 of file scalarterm.hh.


Member Function Documentation

virtual bool RVLAlg::CountTerminator::query (  )  [virtual]

Implements RVLAlg::Terminator.

Reimplemented in RVLAlg::GradientThresholdIterationTable< Scalar >, RVLAlg::CountingThresholdIterationTable< Scalar >, RVLAlg::VectorCountingThresholdIterationTable< Scalar >, and RVLAlg::CountingNormTable< Scalar >.

Definition at line 85 of file scalarterm.hh.

References count, i, and mc.

Referenced by RVLAlg::CountingNormTable< Scalar >::query(), RVLAlg::VectorCountingThresholdIterationTable< Scalar >::query(), RVLAlg::CountingThresholdIterationTable< Scalar >::query(), and RVLAlg::GradientThresholdIterationTable< Scalar >::query().

int RVLAlg::CountTerminator::getCount (  ) 

Definition at line 90 of file scalarterm.hh.

References count.

Referenced by RVLAlg::CountingNormTable< Scalar >::query(), RVLAlg::VectorCountingThresholdIterationTable< Scalar >::query(), RVLAlg::CountingThresholdIterationTable< Scalar >::query(), and RVLAlg::GradientThresholdIterationTable< Scalar >::query().


Member Data Documentation

int RVLAlg::CountTerminator::mc [protected]

Definition at line 93 of file scalarterm.hh.

Referenced by query().

int RVLAlg::CountTerminator::count [protected]

Definition at line 94 of file scalarterm.hh.

Referenced by getCount(), and query().

int RVLAlg::CountTerminator::i [protected]

Definition at line 95 of file scalarterm.hh.

Referenced by RVLAlg::VectorCountingThresholdIterationTable< Scalar >::init(), query(), and RVLAlg::VectorCountingThresholdIterationTable< Scalar >::query().


The documentation for this class was generated from the following file:
Generated on 5 Jan 2017 for RvlAlg by  doxygen 1.4.7