unary function


unary_function<Arg, Result> unary_function<Arg, Result> Category: functors Component type: type Description Unary_function is an empty base class: it contains no member functions or member variables, but only type information. The only reason it exists is to make it more convenient to define types that are models of the concept Adaptable Unary Function. Specifically, any model of Adaptable Unary Function must define nested typedefs. Those typedefs are provided by the base class unary_function. Example struct sine : public unary_function<double, double> { double operator()(double x) { return sin(x); } }; Definition Defined in the standard header functional, and in the nonstandard backward-compatibility header function.h. Template parameters Parameter Description Default Arg The function object's argument type   Result The function object's result type   Model of Assignable, Default Constructible Type requirements Public base classes None. Members Member Where defined Description argument_type unary_function See below. result_type unary_function See below. New members These members are not defined in the Assignable and Default Constructible requirements, but are specific to unary_function. Member Description argument_type The function object's argument type. This is a typedef for the template parameter Arg. result_type The function object's result type. This is a typedef for the template parameter Result. Notes See also The Function Object overview, Adaptable Unary Function, binary_function Copyright © 1999 Silicon Graphics, Inc. All Rights Reserved. TrademarkInformation

Wyszukiwarka

Podobne podstrony:
pointer to unary function
function fdf next field name
function ccvs void
function mysql error
function mcal event set end
function mcrypt cbc
Functional Origins of Religious Concepts Ontological and Strategic Selection in Evolved Minds
function domnode get content
function mcrypt module get algo key size
function pdf execute image
function nl2br

więcej podobnych podstron