Class ContextualizedAction<T>
Represents an Action with a context used by Threads.
Implements
Inherited Members
Namespace: TriLibCore.General
Assembly: TriLibCore.dll
Syntax
public class ContextualizedAction<T> : IContextualizedAction
Type Parameters
Name | Description |
---|---|
T | Context type. |
Constructors
ContextualizedAction(Action<T>, T)
Initializes the Contextualized Action using the given Action and Context.
Declaration
public ContextualizedAction(Action<T> action, T context)
Parameters
Type | Name | Description |
---|---|---|
Action<T> | action | The Action to be executed. |
T | context | The Context which has been passed to the Action. |
Fields
Action
Action to call on the new Thread.
Declaration
public readonly Action<T> Action
Field Value
Type | Description |
---|---|
Action<T> |
Context
Context Object passed to the Action.
Declaration
public readonly T Context
Field Value
Type | Description |
---|---|
T |
Properties
Completed
Indicates whether this Action is completed.
Declaration
public bool Completed { get; }
Property Value
Type | Description |
---|---|
bool |
Methods
GetContext()
Returns the Context used in this Action.
Declaration
public AssetLoaderContext GetContext()
Returns
Type | Description |
---|---|
AssetLoaderContext |
Invoke()
Invokes the Action on the new Thread with the Context as the argument.
Declaration
public void Invoke()
ToString()
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string |