DGtal  0.9.3beta
Public Types | Public Member Functions | Private Attributes
DGtal::functors::ConstValueCell< TQuantity, TCell > Class Template Reference

#include <DGtal/base/BasicFunctors.h>

Inheritance diagram for DGtal::functors::ConstValueCell< TQuantity, TCell >:
[legend]
Collaboration diagram for DGtal::functors::ConstValueCell< TQuantity, TCell >:
[legend]

Public Types

typedef TCell Cell
 
typedef TQuantity Quantity
 

Public Member Functions

 ConstValueCell (const Quantity &aQuantity=0)
 
Quantity operator() (const Cell &) const
 

Private Attributes

Quantity myQuantity
 

Detailed Description

template<typename TQuantity, typename TCell>
class DGtal::functors::ConstValueCell< TQuantity, TCell >

Aim: Define a simple functor that returns a constant quantity (0 by default).

Description of template class 'ConstValueCell'

Template Parameters
TQuantitytype of the quantity
TCelltype of the cell

Definition at line 220 of file BasicFunctors.h.

Member Typedef Documentation

template<typename TQuantity , typename TCell >
typedef TCell DGtal::functors::ConstValueCell< TQuantity, TCell >::Cell

Definition at line 223 of file BasicFunctors.h.

template<typename TQuantity , typename TCell >
typedef TQuantity DGtal::functors::ConstValueCell< TQuantity, TCell >::Quantity

Definition at line 224 of file BasicFunctors.h.

Constructor & Destructor Documentation

template<typename TQuantity , typename TCell >
DGtal::functors::ConstValueCell< TQuantity, TCell >::ConstValueCell ( const Quantity aQuantity = 0)
inline

Constructor.

Parameters
aQuantitythe constant quantity.

Definition at line 230 of file BasicFunctors.h.

231  :myQuantity(aQuantity) {}

Member Function Documentation

template<typename TQuantity , typename TCell >
Quantity DGtal::functors::ConstValueCell< TQuantity, TCell >::operator() ( const Cell ) const
inline

Operator

Returns
the constant value.

Definition at line 239 of file BasicFunctors.h.

References DGtal::functors::ConstValueCell< TQuantity, TCell >::myQuantity.

240  {
241  return myQuantity;
242  }

Field Documentation

template<typename TQuantity , typename TCell >
Quantity DGtal::functors::ConstValueCell< TQuantity, TCell >::myQuantity
private

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