TSparseDynamicDelegate

Sparse version of [TBaseDynamicDelegate](API\Runtime\Core\Delegates\TBaseDynamicDelegate)

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

CoreUObject

Header

/Engine/Source/Runtime/CoreUObject/Public/UObject/SparseDelegate.h

Include

#include "UObject/SparseDelegate.h"

Syntax

template<typename MulticastDelegate, typename OwningClass, typename DelegateInfoClass>
struct TSparseDynamicDelegate : public FSparseDelegate

Remarks

Sparse version of TBaseDynamicDelegate

Functions

Name Description

Public function

void

 

__Internal_AddDynamic

(
    UserClass* InUserObject,
    typename FDelegate::template TMetho...,
    FName InFunctionName
)

Binds a UObject instance and a UObject method address to this multi-cast delegate.

Public function

void

 

__Internal_AddUniqueDynamic

(
    UserClass* InUserObject,
    typename FDelegate::template TMetho...,
    FName InFunctionName
)

Binds a UObject instance and a UObject method address to this multi-cast delegate, but only if it hasn't been bound before.

Public function Const

bool

 

__Internal_IsAlreadyBound

(
    UserClass* InUserObject,
    typename FDelegate::template TMetho...,
    FName InFunctionName
)

Tests if a UObject instance and a UObject method address pair are already bound to this multi-cast delegate.

Public function

void

 

__Internal_RemoveDynamic

(
    UserClass* InUserObject,
    typename FDelegate::template TMetho...,
    FName InFunctionName
)

Unbinds a UObject instance and a UObject method address from this multi-cast delegate.

Public function

void

 

Add

(
    FScriptDelegate InDelegate
)

Adds a function delegate to this multi-cast delegate's invocation list

Public function

void

 

AddUnique

(
    FScriptDelegate InDelegate
)

Adds a function delegate to this multi-cast delegate's invocation list if a delegate with the same signature doesn't already exist in the invocation list

Public function

void

 

Broadcast

(
    ParamTypes... Params
)

Broadcasts this delegate to all bound objects, except to those that may have expired.

Public function

void

 

Clear()

Removes all functions from this delegate's invocation list

Public function Const

bool

 

Contains

(
    const FScriptDelegate& InDelegate
)

Checks whether a function delegate is already a member of this multi-cast delegate's invocation list

Public function Const

bool

 

Contains

(
    const UObject* InObject,
    FName InFunctionName
)

Checks whether a function delegate is already a member of this multi-cast delegate's invocation list

Protected function Const

FName

 

GetDelegateName()

Public function Const

TSharedPtr< ...

 

GetShared()

Returns the multicast delegate if any delegates are bound to the sparse delegate

Public function

void

 

Remove

(
    const FScriptDelegate& InDelegate
)

Removes a function from this multi-cast delegate's invocation list (performance is O(N)).

Public function

void

 

Remove

(
    const UObject* InObject,
    FName InFunctionName
)

Removes a function from this multi-cast delegate's invocation list (performance is O(N)).

Public function

void

 

RemoveAll

(
    const UObject* Object
)

Removes all delegate bindings from this multicast delegate's invocation list that are bound to the specified object.

Typedefs

Name

Description

FDelegate

Deprecated Functions

Name Description

Public function Const

MulticastDel...

 

Get()

This function has been deprecated - please use GetShared() instead

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss