Module |
|
Header |
/Engine/Source/Runtime/Core/Public/Templates/Invoke.h |
Include |
#include "Templates/Invoke.h" |
template<typename FuncType, typename... ArgTypes>
auto Invoke
(
FuncType && Func,
ArgTypes &&... Args
)
Invokes a callable with a set of arguments. Allows the following:
Calling a functor object given a set of arguments.
Calling a function pointer given a set of arguments.
Calling a member function given a reference to an object and a set of arguments.
Calling a member function given a pointer (including smart pointers) to an object and a set of arguments.
Projecting via a data member pointer given a reference to an object.
Projecting via a data member pointer given a pointer (including smart pointers) to an object.
See: http://en.cppreference.com/w/cpp/utility/functional/invoke