Partager via


EditorOptionValue<T>.ValueOrDefault(T) Method

Definition

Gets the value, if the retrieval was successful. Returns defaultValue otherwise.

public T? ValueOrDefault (T? defaultValue);
member this.ValueOrDefault : 'T -> 'T
Public Function ValueOrDefault (defaultValue As T) As T

Parameters

defaultValue
T

The value to return in case of error reading the editor option's value.

Returns

T

The value converted to the type T.

Applies to