Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Templates > API/Runtime/Core/Templates/Invoke
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Templates/Invoke.h |
| Include | #include "Templates/Invoke.h" |
template<typename FuncType, typename... ArgTypes>
decltype< FuncType >< ArgTypes >...)) Invoke
(
FuncType && Func,
ArgTypes &&... Args
)
Remarks
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