STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Types | Public Member Functions | List of all members
function< _Fty > Class Template Reference
Inheritance diagram for function< _Fty >:

Public Types

typedef function< _Fty > _Myt
 
typedef _Get_function_impl< _Fty >::type _Mybase
 

Public Member Functions

 function () _NOEXCEPT
 
 function (nullptr_t) _NOEXCEPT
 
 function (const _Myt &_Right)
 
 function (_Myt &_Right)
 
template<class _Fx >
 function (const _Fx &_Func)
 
template<class _Fx , class _Alloc >
 function (_Fx _Func, const _Alloc &_Ax)
 
template<class _Alloc >
 function (allocator_arg_t, const _Alloc &) _NOEXCEPT
 
template<class _Alloc >
 function (allocator_arg_t, const _Alloc &, nullptr_t) _NOEXCEPT
 
template<class _Alloc >
 function (allocator_arg_t, const _Alloc &_Ax, const _Myt &_Right)
 
template<class _Fx , class _Alloc >
 function (allocator_arg_t, const _Alloc &_Ax, _Fx _Func)
 
template<class _Fx >
 function (reference_wrapper< _Fx > _Func)
 
template<class _Fx , class _Alloc >
 function (reference_wrapper< _Fx > _Func, const _Alloc &_Ax)
 
 ~function () _NOEXCEPT
 
_Mytoperator= (const _Myt &_Right)
 
_Mytoperator= (_Myt &_Right)
 
 function (const _Myt &&_Right)
 
 function (_Myt &&_Right)
 
template<class _Alloc >
 function (allocator_arg_t, const _Alloc &_Al, _Myt &&_Right)
 
template<class _Fx >
 function (_Fx &&_Func)
 
_Mytoperator= (_Myt &&_Right)
 
template<class _Fx >
_Mytoperator= (_Fx &&_Func)
 
template<class _Fx , class _Alloc >
void assign (_Fx &&_Func, const _Alloc &_Ax)
 
functionoperator= (nullptr_t)
 
template<class _Fx >
_Mytoperator= (reference_wrapper< _Fx > _Func) _NOEXCEPT
 
template<class _Fx , class _Alloc >
void assign (reference_wrapper< _Fx > _Func, const _Alloc &_Ax)
 
void swap (_Myt &_Right) _NOEXCEPT
 
 operator bool () const _NOEXCEPT
 
const _XSTD2 type_infotarget_type () const _NOEXCEPT
 
template<class _Fty2 >
_Fty2 * target () _NOEXCEPT
 
template<class _Fty2 >
const _Fty2 * target () const _NOEXCEPT
 

Member Typedef Documentation

template<class _Fty>
typedef _Get_function_impl<_Fty>::type function< _Fty >::_Mybase
template<class _Fty>
typedef function<_Fty> function< _Fty >::_Myt

Constructor & Destructor Documentation

template<class _Fty>
function< _Fty >::function ( )
inline
557  { // construct empty function wrapper
558  this->_Reset();
559  }
template<class _Fty>
function< _Fty >::function ( nullptr_t  )
inline
562  { // construct empty function wrapper from null pointer
563  this->_Reset();
564  }
template<class _Fty>
function< _Fty >::function ( const _Myt _Right)
inline
567  { // construct holding copy of _Right
568  this->_Reset((const _Mybase&)_Right);
569  }
const _Ty & _Right
Definition: algorithm:4087
_Get_function_impl< _Fty >::type _Mybase
Definition: functional:554
template<class _Fty>
function< _Fty >::function ( _Myt _Right)
inline
572  { // construct holding copy of _Right
573  this->_Reset((const _Mybase&)_Right);
574  }
const _Ty & _Right
Definition: algorithm:4087
_Get_function_impl< _Fty >::type _Mybase
Definition: functional:554
template<class _Fty>
template<class _Fx >
function< _Fty >::function ( const _Fx &  _Func)
inline
578  { // construct wrapper holding copy of _Func
579  this->_Reset(_Func);
580  }
template<class _Fty>
template<class _Fx , class _Alloc >
function< _Fty >::function ( _Fx  _Func,
const _Alloc &  _Ax 
)
inline
585  { // construct wrapper holding copy of _Func, allocator (old style)
586  this->_Reset_alloc(_Func, _Ax);
587  }
template<class _Fty>
template<class _Alloc >
function< _Fty >::function ( allocator_arg_t  ,
const _Alloc &   
)
inline
591  { // construct empty function wrapper, allocator
592  this->_Reset();
593  }
template<class _Fty>
template<class _Alloc >
function< _Fty >::function ( allocator_arg_t  ,
const _Alloc &  ,
nullptr_t   
)
inline
597  { // construct empty function wrapper from null pointer, allocator
598  this->_Reset();
599  }
template<class _Fty>
template<class _Alloc >
function< _Fty >::function ( allocator_arg_t  ,
const _Alloc &  _Ax,
const _Myt _Right 
)
inline
603  { // construct wrapper holding copy of _Right, allocator
604  this->_Reset_alloc(_Right, _Ax);
605  }
const _Ty & _Right
Definition: algorithm:4087
template<class _Fty>
template<class _Fx , class _Alloc >
function< _Fty >::function ( allocator_arg_t  ,
const _Alloc &  _Ax,
_Fx  _Func 
)
inline
610  { // construct wrapper holding copy of _Func, allocator (new style)
611  this->_Reset_alloc(_Func, _Ax);
612  }
template<class _Fty>
template<class _Fx >
function< _Fty >::function ( reference_wrapper< _Fx >  _Func)
inline
616  { // construct wrapper holding reference to _Func
617  this->_Reset(_Func);
618  }
template<class _Fty>
template<class _Fx , class _Alloc >
function< _Fty >::function ( reference_wrapper< _Fx >  _Func,
const _Alloc &  _Ax 
)
inline
623  { // construct wrapper holding reference to _Func
624  this->_Reset_alloc(_Func, _Ax);
625  }
template<class _Fty>
function< _Fty >::~function ( )
inline
628  { // destroy the object
629  this->_Tidy();
630  }
template<class _Fty>
function< _Fty >::function ( const _Myt &&  _Right)
inline
653  { // construct holding copy of _Right
654  this->_Reset((const _Mybase&)_Right);
655  }
const _Ty & _Right
Definition: algorithm:4087
_Get_function_impl< _Fty >::type _Mybase
Definition: functional:554
template<class _Fty>
function< _Fty >::function ( _Myt &&  _Right)
inline
658  { // construct holding moved copy of _Right
659  this->_Resetm(_STD forward<_Myt>(_Right));
660  }
const _Ty & _Right
Definition: algorithm:4087
template<class _Fty>
template<class _Alloc >
function< _Fty >::function ( allocator_arg_t  ,
const _Alloc &  _Al,
_Myt &&  _Right 
)
inline
664  { // construct wrapper holding moved copy of _Right, allocator
665  this->_Resetm(_STD forward<_Myt>(_Right));
666  }
const _Ty & _Right
Definition: algorithm:4087
template<class _Fty>
template<class _Fx >
function< _Fty >::function ( _Fx &&  _Func)
inline
670  { // construct wrapper holding moved _Func
671  this->_Reset(_STD forward<_Fx>(_Func));
672  }

Member Function Documentation

template<class _Fty>
template<class _Fx , class _Alloc >
void function< _Fty >::assign ( _Fx &&  _Func,
const _Alloc &  _Ax 
)
inline
695  { // construct wrapper holding copy of _Func
696  this->_Tidy();
697  this->_Reset_alloc(_STD forward<_Fx>(_Func), _Ax);
698  }
template<class _Fty>
template<class _Fx , class _Alloc >
void function< _Fty >::assign ( reference_wrapper< _Fx >  _Func,
const _Alloc &  _Ax 
)
inline
718  { // construct wrapper holding reference to _Func
719  this->_Tidy();
720  this->_Reset_alloc(_Func, _Ax);
721  }
template<class _Fty>
function< _Fty >::operator bool ( ) const
inlineexplicit
729  { // test if wrapper holds null function pointer
730  return (!this->_Empty());
731  }
template<class _Fty>
_Myt& function< _Fty >::operator= ( const _Myt _Right)
inline
633  { // assign _Right
634  if (this != &_Right)
635  { // clean up and copy
636  this->_Tidy();
637  this->_Reset((const _Mybase&)_Right);
638  }
639  return (*this);
640  }
const _Ty & _Right
Definition: algorithm:4087
_Get_function_impl< _Fty >::type _Mybase
Definition: functional:554
template<class _Fty>
_Myt& function< _Fty >::operator= ( _Myt _Right)
inline
643  { // assign _Right
644  if (this != &_Right)
645  { // clean up and copy
646  this->_Tidy();
647  this->_Reset((const _Mybase&)_Right);
648  }
649  return (*this);
650  }
const _Ty & _Right
Definition: algorithm:4087
_Get_function_impl< _Fty >::type _Mybase
Definition: functional:554
template<class _Fty>
_Myt& function< _Fty >::operator= ( _Myt &&  _Right)
inline
675  { // assign by moving _Right
676  if (this != &_Right)
677  { // clean up and copy
678  this->_Tidy();
679  this->_Resetm(_STD forward<_Myt>(_Right));
680  }
681  return (*this);
682  }
const _Ty & _Right
Definition: algorithm:4087
template<class _Fty>
template<class _Fx >
_Myt& function< _Fty >::operator= ( _Fx &&  _Func)
inline
686  { // move function object _Func
687  this->_Tidy();
688  this->_Reset(_STD forward<_Fx>(_Func));
689  return (*this);
690  }
template<class _Fty>
function& function< _Fty >::operator= ( nullptr_t  )
inline
701  { // clear function object
702  this->_Tidy();
703  this->_Reset();
704  return (*this);
705  }
template<class _Fty>
template<class _Fx >
_Myt& function< _Fty >::operator= ( reference_wrapper< _Fx >  _Func)
inline
709  { // assign wrapper holding reference to _Func
710  this->_Tidy();
711  this->_Reset(_Func);
712  return (*this);
713  }
template<class _Fty>
void function< _Fty >::swap ( _Myt _Right)
inline
724  { // swap with _Right
725  this->_Swap(_Right);
726  }
const _Ty & _Right
Definition: algorithm:4087
template<class _Fty>
template<class _Fty2 >
_Fty2* function< _Fty >::target ( )
inline
740  { // return pointer to target object
741  return ((_Fty2*)this->_Target(typeid(_Fty2)));
742  }
template<class _Fty>
template<class _Fty2 >
const _Fty2* function< _Fty >::target ( ) const
inline
746  { // return pointer to target object
747  return ((const _Fty2*)this->_Target(typeid(_Fty2)));
748  }
template<class _Fty>
const _XSTD2 type_info& function< _Fty >::target_type ( ) const
inline
734  { // return type_info object for target type
735  return (this->_Target_type());
736  }

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