次の方法で共有


ModelingEnumerationConverter.CanConvertTo Method (ITypeDescriptorContext, Type)

Indicates whether this converter can convert the domain enumeration object to the specified type by using the specified context.

Namespace:  Microsoft.VisualStudio.Modeling.Design
Assembly:  Microsoft.VisualStudio.Modeling.Sdk.10.0 (in Microsoft.VisualStudio.Modeling.Sdk.10.0.dll)

Syntax

'宣言
Public Overrides Function CanConvertTo ( _
    context As ITypeDescriptorContext, _
    destinationType As Type _
) As Boolean
public override bool CanConvertTo(
    ITypeDescriptorContext context,
    Type destinationType
)
public:
virtual bool CanConvertTo(
    ITypeDescriptorContext^ context, 
    Type^ destinationType
) override
abstract CanConvertTo : 
        context:ITypeDescriptorContext * 
        destinationType:Type -> bool 
override CanConvertTo : 
        context:ITypeDescriptorContext * 
        destinationType:Type -> bool 
public override function CanConvertTo(
    context : ITypeDescriptorContext, 
    destinationType : Type
) : boolean

Parameters

  • destinationType
    Type: System.Type
    The type to convert to.

Return Value

Type: System.Boolean
true if this converter can perform the conversion; otherwise, false.

Remarks

This converter can only convert an enumeration object to and from a string.

By default, the culture parameter is ignored.

Notes to Inheritors

Override this method to provide your own conversion restrictions.

.NET Framework Security

See Also

Reference

ModelingEnumerationConverter Class

CanConvertTo Overload

Microsoft.VisualStudio.Modeling.Design Namespace