This is an old version of the documentation. View the latest version here.
 Control Surface  1.0.0 MIDI Control Surface library for Arduino
Incrementor< T, V > Class Template Reference

Utility class that acts as a functor to return incremental values. More...

#include <ArrayHelpers.hpp>

Collaboration diagram for Incrementor< T, V >:

## Public Member Functions

Incrementor (T start=0, V increment=1)

operator() ()

## Private Attributes

value

const V increment

## Detailed Description

### template<class T, class V> class Incrementor< T, V >

Utility class that acts as a functor to return incremental values.

Template Parameters
 T The type that will be returned by the functor, as well as the type of the initial value. V The type of the object that is added to the value on each call.

Definition at line 31 of file ArrayHelpers.hpp.

## ◆ Incrementor()

template<class T, class V>
 Incrementor< T, V >::Incrementor ( T start = 0, V increment = 1 )
inline

Definition at line 33 of file ArrayHelpers.hpp.

## ◆ operator()()

template<class T, class V>
 T Incrementor< T, V >::operator() ( )
inline

Definition at line 35 of file ArrayHelpers.hpp.

## ◆ value

template<class T, class V>
 T Incrementor< T, V >::value
private

Definition at line 42 of file ArrayHelpers.hpp.

## ◆ increment

template<class T, class V>
 const V Incrementor< T, V >::increment
private

Definition at line 43 of file ArrayHelpers.hpp.

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