Class ComputedValueOptions<T>
Options class for the Constructor of ComputedValue<T> class.
Inheritance
System.Object
ComputedValueOptions<T>
Namespace: Cortex.Net
Assembly: Cortex.Net.dll
Syntax
public class ComputedValueOptions<T> : object
Type Parameters
Name | Description |
---|---|
T | The type of the getter / setter. |
Constructors
| Improve this Doc View SourceComputedValueOptions(Func<T>, String)
Initializes a new instance of the ComputedValueOptions<T> class.
Declaration
public ComputedValueOptions(Func<T> getter, string name)
Parameters
Type | Name | Description |
---|---|---|
Func<T> | getter | The getter for the computed value. |
System.String | name | The name of the computed value. |
Properties
| Improve this Doc View SourceContext
Gets or sets the context where the computed value operates on (If Any).
Declaration
public object Context { get; set; }
Property Value
Type | Description |
---|---|
System.Object |
EqualityComparer
Gets or sets an optional equality comparer for type T
.
Declaration
public IEqualityComparer<T> EqualityComparer { get; set; }
Property Value
Type | Description |
---|---|
IEqualityComparer<T> |
Getter
Gets the getter function.
Declaration
public Func<T> Getter { get; }
Property Value
Type | Description |
---|---|
Func<T> |
KeepAlive
Gets or sets a value indicating whether the computed value keeps calculating, even when it is not observed.
Declaration
public bool KeepAlive { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Name
Gets or sets the name of the computed value.
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String |
RequiresReaction
Gets or sets a value indicating whether the ComputedValue<T> requires a reactive context.
Declaration
public bool RequiresReaction { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Setter
Gets or sets setter function.
Declaration
public Action<T> Setter { get; set; }
Property Value
Type | Description |
---|---|
Action<T> |