NullableExtension Class
Implements a markup extension that returns an instance of Nullable<T> using the specified Type.
public class NullableExtension : MarkupExtension
- Inheritance:
- object MarkupExtension object
Remarks
This class is a markup extension implementation. Markup extension classes exist mainly to provide infrastructure support for some aspect of the WPF XAML processor implementation.
Constructors
NullableExtension(Type)
Initializes a new instance of the NullableExtension class using the specified Type.
public NullableExtension(Type typeArgument)
Parameter | Type | Description |
---|---|---|
typeArgument | Type | The Type used as a parameter to create an instance of Nullable<T>. |
Properties
TypeArgument
Gets the Type used as a parameter to create an instance of Nullable<T>.
public Type TypeArgument { get; }
Property Value
- Type:
The Type used as a parameter to create an instance of Nullable<T>.
Methods
ProvideValue(IServiceProvider)
Creates and returns a nullable Type based on the current state of this object. extension.
public override object ProvideValue(IServiceProvider serviceProvider)
Parameter | Type | Description |
---|---|---|
serviceProvider | IServiceProvider | Object that can provide services for the markup extension. |