Public Member Functions | Private Types
utilmm::identity< Ty > Struct Template Reference

Identity functor. More...

#include <utils.hh>

List of all members.

Public Member Functions

arg_type operator() (arg_type x) const
 Identity call.

Private Types

typedef arg_traits< Ty >::type arg_type

Detailed Description

template<typename Ty>
struct utilmm::identity< Ty >

Identity functor.

This functor correspond to the identity function. It is a function that will return exactly the same value as passed as argument. It also uses arg_traits to improve performances avoiding the copy of complex objects

Parameters:
Tythe type of arguments
Author:
Frédéric Py <fpy@laas.fr>

Definition at line 24 of file utils.hh.


Member Typedef Documentation

template<typename Ty >
typedef arg_traits<Ty>::type utilmm::identity< Ty >::arg_type [private]

Definition at line 26 of file utils.hh.


Member Function Documentation

template<typename Ty >
arg_type utilmm::identity< Ty >::operator() ( arg_type  x) const [inline]

Identity call.

Parameters:
xThe argument
Returns:
x without modification

Definition at line 33 of file utils.hh.


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


utilmm
Author(s): Sylvain Joyeux/sylvain.joyeux@m4x.org
autogenerated on Mon Oct 6 2014 03:17:01