public class ChildPropertyTypeDescriptor : CustomTypeDescriptor
Public Class ChildPropertyTypeDescriptor
Inherits CustomTypeDescriptor
public ref class ChildPropertyTypeDescriptor : public CustomTypeDescriptor
type ChildPropertyTypeDescriptor =
class
inherit CustomTypeDescriptor
end
This type descriptor allows child properties to be bound to controls and edited. The type descriptor will scan down up to three levels and goes no further to prevent endless recursion and/or stack overflows. Primitive and String property types are ignored as they have no useful properties for binding purposes.
Properties with a BrowsableAttribute set to false are ignored along with all of their child properties. Properties with a HidePropertyAttribute are ignored but their child properties are added to the list. This allows you to exclude the parent property if it serves no purpose other than to contain the child properties.
Child properties are prefixed with the parent property name followed by an underscore. Use this naming convention when binding to the child properties. (i.e. Address_Street, Address_State where Address is a class and Street and State are two of its properties).
ChildPropertyTypeDescriptor | Constructor |
Equals | Determines whether the specified object is equal to the current object. (Inherited from Object) |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object) |
GetAttributes | Returns a collection of custom attributes for the type represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetClassName | Returns the fully qualified name of the class represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetComponentName | Returns the name of the class represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetConverter | Returns a type converter for the type represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetDefaultEvent | Returns the event descriptor for the default event of the object represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetDefaultProperty | Returns the property descriptor for the default property of the object represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetEditor | Returns an editor of the specified type that is to be associated with the class represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetEvents | Returns a collection of event descriptors for the object represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetEvents(Attribute) | Returns a filtered collection of event descriptors for the object represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetHashCode | Serves as the default hash function. (Inherited from Object) |
GetProperties | Returns a collection of property descriptors for the object represented by this type descriptor. (Inherited from CustomTypeDescriptor) |
GetProperties(Attribute) |
This is overridden to return a property descriptors for the object represented by this type
descriptor along with extra property descriptors for its child properties.
(Overrides CustomTypeDescriptorGetProperties(Attribute)) |
GetPropertyOwner | Returns an object that contains the property described by the specified property descriptor. (Inherited from CustomTypeDescriptor) |
GetType | Gets the Type of the current instance. (Inherited from Object) |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object) |
ToString | Returns a string that represents the current object. (Inherited from Object) |