GetValueOrDefault<TResult>(TResult) Method
Gets the value of the binding value if present, otherwise a default value.
Definition
Namespace: Avalonia.Data
Assembly: Avalonia.Base (in Avalonia.Base.dll)
- C#
- VB
- F#
public TResult GetValueOrDefault<TResult>(
TResult defaultValue
)
Public Function GetValueOrDefault(Of TResult) (
defaultValue As TResult
) As TResult
member GetValueOrDefault :
defaultValue : 'TResult -> 'TResult
Parameters
- TResult
- The default value.
Type Parameters
Return Value
TResult
The value if present and of the correct type, default(TResult)
if the value is present but not of the correct type or null, or defaultValue if the value is not present.
See Also
Reference
BindingValue(T) Structure
GetValueOrDefault Overload
Avalonia.Data Namespace