UltEvent<T0, T1, T2> Class

Summary

A serializable event with 3 parameters which can be viewed and configured in the inspector.
Assembly
UltEvents.dll
Namespace
UltEvents
Interfaces
Base Types
graph BT Type-->Base0["UltEventBase"] click Base0 "/ultevents/api/UltEvents/UltEventBase" Base0-->Base1["Object"] Type-.->Interface0["IUltEvent<T0, T1, T2>"] Type-.->Interface1["IUltEventBase"] click Interface1 "/ultevents/api/UltEvents/IUltEventBase" Type["UltEvent<T0, T1, T2>"] class Type type-node

Syntax

[Serializable]
public class UltEvent<T0, T1, T2> : UltEventBase, IUltEvent<T0, T1, T2>, IUltEventBase

Remarks

This is a more versatile and user friendly implementation than UnityEvent<T0, T1, T2>.

Attributes

Type Description
SerializableAttribute

Type Parameters

Name Description
T0
T1
T2

Events

Name Type Summary
DynamicCalls Action<T0, T1, T2>
Delegates registered here are invoked by UltEvents.UltEvent`3.Invoke(`0,`1,`2) after all UltEvents.UltEvent`3.PersistentCalls.
PersistentCalls Action<T0, T1, T2>
Delegates registered to this event are serialized as UltEvents.PersistentCalls and are invoked by UltEvents.UltEvent`3.Invoke(`0,`1,`2) before all UltEvents.UltEvent`3.DynamicCalls.

Properties

Name Value Summary
DynamicCallsBase Delegate
The non-serialized method and parameter details of this event. Delegates registered here are called by UltEvents.UltEvent`3.Invoke(`0,`1,`2) after all UltEvents.UltEvent`3.PersistentCalls.
HasCalls bool
Returns true if this event has any UltEvents.UltEventBase.PersistentCallsList or UltEvents.UltEventBase.DynamicCallsBase registered.
Inherited from UltEventBase
ParameterCount int
The number of parameters this event takes.
ParameterTypes Type[]
[Editor-Only] The types of each of this event's parameters.
PersistentCallsList List<PersistentCall>
The serialized method and parameter details of this event.
Inherited from UltEventBase

Methods

Name Value Summary
AddDynamicCall(UltEvent<T0, T1, T2>, Action<T0, T1, T2>) void
Ensures that `ultEvent` isn't null and adds `method` to its UltEvents.UltEvent`3.DynamicCalls.
static
AddPersistentCall(Delegate) PersistentCall
Adds the specified `method` to the persistent call list.
Inherited from UltEventBase
AddPersistentCall<T>(T, Action) PersistentCall
Ensures that `ultEvent` isn't null and adds `method` to its UltEvents.UltEventBase.PersistentCallsList.
Inherited from UltEventBase
static
AddPersistentCall<T>(T, Delegate) PersistentCall
Ensures that `ultEvent` isn't null and adds `method` to its UltEvents.UltEventBase.PersistentCallsList.
Inherited from UltEventBase
static
CacheParameter(Object) void
Stores the `parameter` so it can be accessed by UltEvents.PersistentCalls.
Inherited from UltEventBase
static
CacheParameters(Object[]) void
Stores the `parameters` so they can be accessed by UltEvents.PersistentCalls.
Inherited from UltEventBase
static
Clear() void
Clears all UltEvents.UltEventBase.PersistentCallsList and UltEvents.UltEventBase.DynamicCallsBase registered to this event.
Inherited from UltEventBase
CopyFrom(UltEventBase) void
Copies the contents of this the `target` event to this event.
Inherited from UltEventBase
DynamicInvoke(Object[]) void
Invokes all PersistentCalls then all DynamicCalls.
Inherited from UltEventBase
Invoke(T0, T1, T2) void
Invokes all UltEvents.UltEvent.PersistentCalls then all UltEvents.IUltEvent`3.DynamicCalls.
InvokePersistentCalls() void
Invokes all UltEvents.PersistentCalls registered to this event.
Inherited from UltEventBase
InvokeSafe(T0, T1, T2) void
Invokes all UltEvents.UltEvent`3.PersistentCalls then all UltEvents.UltEvent`3.DynamicCalls inside a try/catch block which logs any exceptions that are thrown.
OnDynamicCallsChanged() void
Clears the cached invocation list of UltEvents.UltEventBase.DynamicCallsBase.
Inherited from UltEventBase
RemoveDynamicCall(UltEvent<T0, T1, T2>, Action<T0, T1, T2>) void
If `ultEvent` isn't null, this method removes `method` from its UltEvents.UltEvent`3.DynamicCalls.
static
RemovePersistentCall(Delegate) void
Removes the specified `method` from the persistent call list.
Inherited from UltEventBase
RemovePersistentCall(UltEventBase, Action) void
If `ultEvent` isn't null, this method removes `method` from its UltEvents.UltEventBase.PersistentCallsList.
Inherited from UltEventBase
static
RemovePersistentCall(UltEventBase, Delegate) void
If `ultEvent` isn't null, this method removes `method` from its UltEvents.UltEventBase.PersistentCallsList.
Inherited from UltEventBase
static
ToString() string
Returns a description of this event.
Inherited from UltEventBase
ToString(StringBuilder) void
Appends a description of this event.
Inherited from UltEventBase

Operators

Name Value Summary
implicit operator UltEvent<T0, T1, T2>(Action<T0, T1, T2>) UltEvent<T0, T1, T2>
operator -(UltEvent<T0, T1, T2>, Action<T0, T1, T2>) UltEvent<T0, T1, T2>
operator +(UltEvent<T0, T1, T2>, Action<T0, T1, T2>) UltEvent<T0, T1, T2>