Class NamedTalesValueProvider
A chain of responsibility class which detects when the object from which to get a value is an implementation of IGetsNamedTalesValue. If it is, then its built-in functionality is used to get the value.
Inheritance
System.Object
NamedTalesValueProvider
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ZptSharp.Expressions.PathExpressions
Assembly: ZptSharp.dll
Syntax
public class NamedTalesValueProvider : IGetsValueFromObject
Constructors
| Improve this Doc View SourceNamedTalesValueProvider(IGetsValueFromObject)
Initializes a new instance of the NamedTalesValueProvider class.
Declaration
public NamedTalesValueProvider(IGetsValueFromObject wrapped)
Parameters
Type | Name | Description |
---|---|---|
IGetsValueFromObject | wrapped | Wrapped. |
Methods
| Improve this Doc View SourceTryGetValueAsync(String, Object, CancellationToken)
Attempts to get a value for a named reference, from the specified object. If that object is an implementation of IGetsNamedTalesValue then TryGetValueAsync(String, CancellationToken) is used to get the result. Otherwise, the call is delegated to the wrapped service.
Declaration
public Task<GetValueResult> TryGetValueAsync(string name, object object, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The value name. |
System.Object | object | The object from which to retrieve the value. |
System.Threading.CancellationToken | cancellationToken | An optional cancellation token. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<GetValueResult> | An object indicating whether a value was successfully retrieved or not, along with the retrieved value (if applicable). |