TScriptDelegate

Script delegate base class.

Windows
MacOS
Linux

Inheritance Hierarchy

TScriptDelegate

TBaseDynamicDelegate

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/UObject/ScriptDelegates.h

Include

#include "UObject/ScriptDelegates.h"

Syntax

template<typename TWeakPtr>
class TScriptDelegate

Remarks

Script delegate base class.

Variables

Name Description

Protected variable

FName

 

FunctionName

Name of the function to call on the bound object

Protected variable

TWeakPtr

 

Object

The object bound to this delegate, or nullptr if no object is bound

Constructors

Name Description

Public function

TScriptDelegate()

Although templated, the parameter is not intended to be anything other than the default, and is only a template for module organization reasons.

Functions

Name Description

Public function

void

 

BindUFunction

(
    UObject * InObject,
    const FName & InFunctionName
)

Binds a UFunction to this delegate.

Public function

void

 

Clear()

Unbinds this delegate (another name to provide a similar interface to TMulticastScriptDelegate )

Public function Const

FName

 

GetFunctionName()

Gets the name of the function to call on the bound object

Public function Const

const UObjec ...

 

GetUObject()

Gets the object bound to this delegate (const)

Public function

UObject *...

 

GetUObject()

Gets the object bound to this delegate

Public function

UObject *...

 

GetUObjectEvenIfUnreachable()

Gets the object bound to this delegate, even if the object is unreachable

Public function Const

const UObjec ...

 

GetUObjectEvenIfUnreachable()

Gets the object bound to this delegate (const), even if the object is unreachable

Public function Const

bool

 

IsBound()

Checks to see if the user object bound to this delegate is still valid

Public function Const

bool

 

IsBoundToObject

(
    void const* InUserObject
)

Checks to see if this delegate is bound to the given user object.

Public function Const

bool

 

IsBoundToObjectEvenIfUnreachable

(
    void const* InUserObject
)

Checks to see if this delegate is bound to the given user object, even if the object is unreachable.

Public function Const

bool

 

IsCompactable()

Checks to see if the user object bound to this delegate will ever be valid again

Public function Const

void

 

ProcessDelegate

(
    void * Parameters
)

Void ProcessDelegate(void* Parameters) const ;

Public function Const

FString

 

ToString()

Converts this delegate to a string representation

Public function

void

 

Unbind()

Unbinds this delegate

Operators

Name Description

Public function Const

bool

 

operator!=

(
    const TScriptDelegate & Other
)

Public function

void

 

operator=

(
    const TScriptDelegate & Other
)

Public function Const

bool

 

operator==

(
    const TScriptDelegate & Other
)

Comparison operators

Select Skin
Light
Dark

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback