Class InvokeContext
- Namespace
- Dynamitey
- Assembly
- Dynamitey.Community.dll
Object that stores a context with a target for dynamic invocation
public class InvokeContext
- Inheritance
-
InvokeContext
- Derived
- Inherited Members
Constructors
InvokeContext(object, object?)
Initializes a new instance of the InvokeContext class.
public InvokeContext(object target, object? context)
Parameters
targetobjectThe target.
contextobjectThe context. Passing null defaults Context from
target's own type, the same as the (target, staticContext, context) overload defaults it totargetitself when given a null context.
InvokeContext(Type, bool, object?)
Initializes a new instance of the InvokeContext class.
public InvokeContext(Type target, bool staticContext, object? context)
Parameters
targetTypeThe target.
staticContextboolif set to
true[static context].contextobjectThe context.
Fields
CreateContext
Create Function can set to variable to make cleaner syntax;
public static readonly Func<object, object?, InvokeContext> CreateContext
Field Value
CreateStatic
Create Function can set to variable to make cleaner syntax;
public static readonly Func<Type, InvokeContext> CreateStatic
Field Value
CreateStaticWithContext
Create Function can set to variable to make cleaner syntax;
public static readonly Func<Type, object?, InvokeContext> CreateStaticWithContext
Field Value
Properties
Context
Gets or sets the context.
public Type Context { get; protected set; }
Property Value
- Type
The context.
StaticContext
Gets or sets a value indicating whether [static context].
public bool StaticContext { get; protected set; }
Property Value
- bool
trueif [static context]; otherwise,false.
Target
Gets or sets the target.
public object Target { get; protected set; }
Property Value
- object
The target.