Adaptors for pointers to members


Classes

class  mem_fun_t
 One of the adaptors for member pointers. More...

class  const_mem_fun_t
 One of the adaptors for member pointers. More...

class  mem_fun_ref_t
 One of the adaptors for member pointers. More...

class  const_mem_fun_ref_t
 One of the adaptors for member pointers. More...

class  mem_fun1_t
 One of the adaptors for member pointers. More...

class  const_mem_fun1_t
 One of the adaptors for member pointers. More...

class  mem_fun1_ref_t
 One of the adaptors for member pointers. More...

class  const_mem_fun1_ref_t
 One of the adaptors for member pointers. More...

class  mem_fun_t< void, _Tp >
 One of the adaptors for member pointers. More...

class  const_mem_fun_t< void, _Tp >
 One of the adaptors for member pointers. More...

class  mem_fun_ref_t< void, _Tp >
 One of the adaptors for member pointers. More...

class  const_mem_fun_ref_t< void, _Tp >
 One of the adaptors for member pointers. More...

class  mem_fun1_t< void, _Tp, _Arg >
 One of the adaptors for member pointers. More...

class  const_mem_fun1_t< void, _Tp, _Arg >
 One of the adaptors for member pointers. More...

class  mem_fun1_ref_t< void, _Tp, _Arg >
 One of the adaptors for member pointers. More...

class  const_mem_fun1_ref_t< void, _Tp, _Arg >
 One of the adaptors for member pointers. More...


Functions

template<class _Ret, class _Tp> mem_fun_t< _Ret, _Tp > std::mem_fun (_Ret(_Tp::*__f)())
template<class _Ret, class _Tp> mem_fun_ref_t< _Ret, _Tp > std::mem_fun_ref (_Ret(_Tp::*__f)())
template<class _Ret, class _Tp, class _Arg> mem_fun1_t< _Ret, _Tp, _Arg > std::mem_fun (_Ret(_Tp::*__f)(_Arg))
template<class _Ret, class _Tp, class _Arg> mem_fun1_ref_t< _Ret, _Tp,
_Arg > 
std::mem_fun_ref (_Ret(_Tp::*__f)(_Arg))

Detailed Description

There are a total of 16 = 2^4 function objects in this family. (1) Member functions taking no arguments vs member functions taking one argument. (2) Call through pointer vs call through reference. (3) Member function with void return type vs member function with non-void return type. (4) Const vs non-const member function.

Note that choice (3) is nothing more than a workaround: according to the draft, compilers should handle void and non-void the same way. This feature is not yet widely implemented, though. You can only use member functions returning void if your compiler supports partial specialization.

All of this complexity is in the function objects themselves. You can ignore it by using the helper function mem_fun and mem_fun_ref, which create whichever type of adaptor is appropriate.


Function Documentation

template<class _Ret, class _Tp, class _Arg>
const_mem_fun1_t< _Ret, _Tp, _Arg > std::mem_fun _Ret(_Tp::*  __f)(_Arg)  )  [inline]
 

Definition at line 872 of file stl_function.h.

template<class _Ret, class _Tp>
const_mem_fun_t< _Ret, _Tp > std::mem_fun _Ret(_Tp::*  __f)()  )  [inline]
 

Definition at line 852 of file stl_function.h.

template<class _Ret, class _Tp, class _Arg>
const_mem_fun1_ref_t< _Ret, _Tp, _Arg > std::mem_fun_ref _Ret(_Tp::*  __f)(_Arg)  )  [inline]
 

Definition at line 882 of file stl_function.h.

template<class _Ret, class _Tp>
const_mem_fun_ref_t< _Ret, _Tp > std::mem_fun_ref _Ret(_Tp::*  __f)()  )  [inline]
 

Definition at line 862 of file stl_function.h.


Generated on Tue Jan 30 17:31:58 2007 for GNU C++ STL by doxygen 1.3.6