![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
Delegate registration class. A function can expose this base class to users to let them bind against, but without letting them execute. This gives us the benefit of C# events.
Example:
struct FInterestingThing { public: TDelegateRegistration<void()>& OnInterestingThing() const { return OnInterestingThingDelegate; }
private: mutable TDelegate<void()> OnInterestingThingDelegate; };
void Func(const FInterestingThing& Thing) { // Binding and unbinding are allowed Thing.OnInterestingThing().BindLambda([](){ RespondToInterestingThing(); }); Thing.OnInterestingThing().Unbind();
// Execute is not Thing.OnInterestingThing().Execute(); // error: Execute is deleted }