ICustomTypeDescriptor Interface
Provides an interface that supplies dynamic custom type information for an object.
Assembly: System (in System.dll)
The ICustomTypeDescriptor type exposes the following members.
Name | Description | |
---|---|---|
![]() ![]() | GetAttributes | Returns a collection of custom attributes for this instance of a component. |
![]() ![]() | GetClassName | Returns the class name of this instance of a component. |
![]() ![]() | GetComponentName | Returns the name of this instance of a component. |
![]() ![]() | GetConverter | Returns a type converter for this instance of a component. |
![]() ![]() | GetDefaultEvent | Returns the default event for this instance of a component. |
![]() ![]() | GetDefaultProperty | Returns the default property for this instance of a component. |
![]() ![]() | GetEditor | Returns an editor of the specified type for this instance of a component. |
![]() ![]() | GetEvents | Returns the events for this instance of a component. |
![]() ![]() | GetEvents(Attribute()) | Returns the events for this instance of a component using the specified attribute array as a filter. |
![]() ![]() | GetProperties | Returns the properties for this instance of a component. |
![]() ![]() | GetProperties(Attribute()) | Returns the properties for this instance of a component using the attribute array as a filter. |
![]() ![]() | GetPropertyOwner | Returns an object that contains the property described by the specified property descriptor. |
The ICustomTypeDescriptor interface allows an object to provide type information about itself. Typically, this interface is used when an object needs dynamic type information. In contrast, the TypeDescriptor class provides static type information that is obtained from metadata.
For example, ICustomTypeDescriptor is used in the .NET Framework to provide type information for COM objects. COM objects do not support properties or attributes. Therefore, the .NET Framework uses ICustomTypeDescriptor to implement properties and attributes for COM objects.
To provide dynamic custom type information, a class can implement ICustomTypeDescriptor or derive from the CustomTypeDescriptor class, which provides a simple implementation of this interface.
![]() |
---|
There is no design-time support for data binding to objects that implement the ICustomTypeDescriptor interface. In addition, when binding to a runtime instance of ICustomTypeDescriptor, the public properties of the underlying type are ignored. |
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.