3.6.0
Freundlich's C++ toolkit
Public Types | Public Member Functions
fcppt::signal::object< T, Base, Enable > Class Template Reference

Detailed Description

template<typename T, template< typename > class Base, typename Enable>
class fcppt::signal::object< T, Base, Enable >

Represents a signal with a non-void return value.

Template Parameters
TThe signal's function type
BaseThe signal's base class (determines the existence of unregister functions)
EnableDummy for SFINAE operations

See fcppt.signal for more information.

Inheritance diagram for fcppt::signal::object< T, Base, Enable >:

Public Types

using base = Base< T >
 A typedef for the signal's base class. More...
 
using result_type = fcppt::type_traits::function_result< T >
 A typedef for the function's return type. More...
 
using function = typename base::function
 
using combiner_function = fcppt::function< result_type(result_type, result_type) >
 Typedef to the combiner function. More...
 
using initial_value = fcppt::strong_typedef< result_type,_ >
 

Public Member Functions

 object (combiner_function &&)
 Construct a signal with a combiner. More...
 
 object (object &&) noexcept
 
objectoperator= (object &&) noexcept
 
 ~object ()
 
template<typename... Args>
result_type operator() (initial_value &&, Args &&...)
 Call the signal. More...
 

Member Typedef Documentation

◆ base

template<typename T , template< typename > class Base, typename Enable >
using fcppt::signal::object< T, Base, Enable >::base = Base< T >

A typedef for the signal's base class.

◆ combiner_function

template<typename T , template< typename > class Base, typename Enable >
using fcppt::signal::object< T, Base, Enable >::combiner_function = fcppt::function< result_type ( result_type, result_type ) >

Typedef to the combiner function.

◆ function

template<typename T , template< typename > class Base, typename Enable >
using fcppt::signal::object< T, Base, Enable >::function = typename base::function

◆ initial_value

template<typename T , template< typename > class Base, typename Enable >
using fcppt::signal::object< T, Base, Enable >::initial_value = fcppt::strong_typedef< result_type ,_>

◆ result_type

template<typename T , template< typename > class Base, typename Enable >
using fcppt::signal::object< T, Base, Enable >::result_type = fcppt::type_traits::function_result< T >

A typedef for the function's return type.

Constructor & Destructor Documentation

◆ object() [1/2]

template<typename T , template< typename > class Base, typename Enable >
fcppt::signal::object< T, Base, Enable >::object ( combiner_function &&  )
explicit

Construct a signal with a combiner.

◆ object() [2/2]

template<typename T , template< typename > class Base, typename Enable >
fcppt::signal::object< T, Base, Enable >::object ( object< T, Base, Enable > &&  )
noexcept

◆ ~object()

template<typename T , template< typename > class Base, typename Enable >
fcppt::signal::object< T, Base, Enable >::~object ( )

Member Function Documentation

◆ operator()()

template<typename T , template< typename > class Base, typename Enable >
template<typename... Args>
result_type fcppt::signal::object< T, Base, Enable >::operator() ( initial_value &&  ,
Args &&  ... 
)

Call the signal.

◆ operator=()

template<typename T , template< typename > class Base, typename Enable >
object& fcppt::signal::object< T, Base, Enable >::operator= ( object< T, Base, Enable > &&  )
noexcept