Base module
FunctionDelegate
The
FunctionDelegate contains a std::function.FunctionDelegate
#include <icy/delegate.h>template<typename RT, typename... Args>
struct FunctionDelegateDefined in src/base/include/icy/delegate.h:48
Inherits:
AbstractDelegate< RT, Args... >
The [FunctionDelegate](#functiondelegate) contains a std::function.
List of all members
| Name | Kind | Owner |
|---|---|---|
func | variable | Declared here |
FunctionDelegate | function | Declared here |
operator() | function | Declared here |
operator== | function | Declared here |
~AbstractDelegate | function | Inherited from AbstractDelegate |
operator() | function | Inherited from AbstractDelegate |
operator== | function | Inherited from AbstractDelegate |
Inherited from AbstractDelegate
| Kind | Name | Description |
|---|---|---|
function | ~AbstractDelegate virtual inline | |
function | operator() virtual const | Invokes the underlying callable with the supplied arguments. |
function | operator== virtual const | Compares two delegates for equality (same target function and instance). |
Public Attributes
| Return | Name | Description |
|---|---|---|
std::function< RT(Args...)> | func |
func
std::function< RT(Args...)> funcDefined in src/base/include/icy/delegate.h:50
Public Methods
| Return | Name | Description |
|---|---|---|
FunctionDelegate inline | ||
RT | operator() virtual const inline override | Calls the wrapped std::function. |
bool | operator== virtual const inline override | Always returns false; std::function targets cannot be compared for equality. |
FunctionDelegate
inline
inline FunctionDelegate(std::function< RT(Args...)> func)Defined in src/base/include/icy/delegate.h:53
Parameters
funcstd::functionto wrap.
operator()
virtual const inline override
virtual inline RT operator()(Args... args) const overrideDefined in src/base/include/icy/delegate.h:61
Calls the wrapped std::function.
Parameters
argsArguments forwarded to the function.
Returns
Function result.
Reimplements
operator==
virtual const inline override
virtual inline bool operator==(const AbstractDelegate< RT, Args... > &) const overrideDefined in src/base/include/icy/delegate.h:67
Always returns false; std::function targets cannot be compared for equality.
