libDAI
Public Member Functions | List of all members
dai::fo_divides0< T > Struct Template Reference

Function object similar to std::divides(), but different in that dividing by zero results in zero. More...

#include <dai/prob.h>

Inherits binary_function< T, T, T >.

Public Member Functions

operator() (const T &x, const T &y) const
 Returns (y == 0 ? 0 : (x / y)) More...
 

Detailed Description

template<typename T>
struct dai::fo_divides0< T >

Function object similar to std::divides(), but different in that dividing by zero results in zero.

Member Function Documentation

template<typename T >
T dai::fo_divides0< T >::operator() ( const T &  x,
const T &  y 
) const
inline

Returns (y == 0 ? 0 : (x / y))


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