AgentState.GetValue<T>(String, Func<T>) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Get a property value.
public T GetValue<T>(string name, Func<T> defaultValueFactory = default);
abstract member GetValue : string * Func<'T> -> 'T
override this.GetValue : string * Func<'T> -> 'T
Public Function GetValue(Of T) (name As String, Optional defaultValueFactory As Func(Of T) = Nothing) As T
Type Parameters
- T
Parameters
- name
- String
The name of the property.
- defaultValueFactory
- Func<T>
Defines the default value. Invoked when no value been set for the requested state property. If defaultValueFactory is defined as null in that case, the method returns null.