BNM 2.4.0
 
Loading...
Searching...
No Matches
BNM::Delegate< Ret > Struct Template Reference

Typed wrapper of Il2CppDelegate. More...

#include <Delegates.hpp>

Public Member Functions

template<typename ... Parameters>
Ret Invoke (Parameters ...parameters)
 Invoke delegate.
 
template<typename ... Parameters>
Ret operator() (Parameters ...parameters)
 
- Public Member Functions inherited from BNM::DelegateBase
IL2CPP::Il2CppObject * GetInstance () const
 Get instance of delegate.
 
MethodBase GetMethod () const
 Get method of delegate.
 
bool IsValid () const noexcept
 Check if delegate is valid.
 
 operator bool () const noexcept
 Check if delegate is valid.
 
template<typename NewRet>
Delegate< NewRet > & cast () const
 Cast delegate to be able to invoke it.
 

Detailed Description

template<typename Ret>
struct BNM::Delegate< Ret >

Typed wrapper of Il2CppDelegate.

Template Parameters
RetReturn type

Member Function Documentation

◆ Invoke()

template<typename Ret>
template<typename ... Parameters>
Ret BNM::Delegate< Ret >::Invoke ( Parameters ... parameters)
inline

Invoke delegate.

Template Parameters
RetReturn type
ParametersDelegate parameter types
Parameters
parametersDelegate parameters