EditorOptionValue<T>.IEditorOptionValue.ValueOrDefault<TInterface> 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.
Gets the value converted to the type T
, if the retrieval and the conversion to T
are successful.
Returns defaultValue
otherwise.
TInterface IEditorOptionValue.ValueOrDefault<TInterface> (TInterface defaultValue);
abstract member Microsoft.VisualStudio.Extensibility.Editor.IEditorOptionValue.ValueOrDefault : 'Interface -> 'Interface
override this.Microsoft.VisualStudio.Extensibility.Editor.IEditorOptionValue.ValueOrDefault : 'Interface -> 'Interface
Function ValueOrDefault(Of TInterface) (defaultValue As TInterface) As TInterface Implements IEditorOptionValue.ValueOrDefault
Type Parameters
- TInterface
Parameters
- defaultValue
- TInterface
The value to return in case of error reading the editor option's value.
Returns
TInterface
The value converted to the type T
.