libsigc++  3.6.0
Public Member Functions | Public Attributes | List of all members
sigc::bind_functor< I_location, T_functor, T_bound > Struct Template Reference

Adaptor that binds arguments to the wrapped functor. More...

#include <sigc++/adaptors/bind.h>

Inheritance diagram for sigc::bind_functor< I_location, T_functor, T_bound >:
Inheritance graph
[legend]

Public Member Functions

 bind_functor (type_trait_take_t< T_functor > func, type_trait_take_t< T_bound >... bound)
 Constructs a bind_functor object that binds an argument to the passed functor. More...
 
template<typename... T_arg>
decltype(auto) operator() (T_arg &&... arg)
 Invokes the wrapped functor passing on the arguments. More...
 
- Public Member Functions inherited from sigc::adapts< T_functor >
 adapts (const T_functor & functor)
 Constructs an adaptor that wraps the passed functor. More...
 

Public Attributes

std::tuple< bound_argument< T_bound >... > bound_
 The arguments bound to the functor. More...
 
- Public Attributes inherited from sigc::adapts< T_functor >
adaptor_type functor_
 Adaptor that is invoked from operator()(). More...
 

Detailed Description

template<int I_location, typename T_functor, typename... T_bound>
struct sigc::bind_functor< I_location, T_functor, T_bound >

Adaptor that binds arguments to the wrapped functor.

Use the convenience function sigc::bind() to create an instance of sigc::bind_functor.

The following template arguments are used:

Constructor & Destructor Documentation

◆ bind_functor()

template <int I_location, typename T_functor , typename... T_bound>
sigc::bind_functor< I_location, T_functor, T_bound >::bind_functor ( type_trait_take_t< T_functor >  func,
type_trait_take_t< T_bound >...  bound 
)
inline

Constructs a bind_functor object that binds an argument to the passed functor.

Parameters
funcFunctor to invoke from operator()().
boundArgument to bind to the functor.

Member Function Documentation

◆ operator()()

template <int I_location, typename T_functor , typename... T_bound>
template <typename... T_arg>
decltype(auto) sigc::bind_functor< I_location, T_functor, T_bound >::operator() ( T_arg &&...  arg)
inline

Invokes the wrapped functor passing on the arguments.

bound_ is passed as the next argument.

Parameters
argArguments to be passed on to the functor.
Returns
The return value of the functor invocation.

Member Data Documentation

◆ bound_

template <int I_location, typename T_functor , typename... T_bound>
std::tuple<bound_argument<T_bound>...> sigc::bind_functor< I_location, T_functor, T_bound >::bound_

The arguments bound to the functor.