PortCollection Class

A type-safe collection of ICapePort objects.

Definition

Namespace: CapeOpen
Assembly: CapeOpen (in CapeOpen.dll) Version: 1.0.0.0 (1.0.0.0)
[SerializableAttribute]
[ComVisibleAttribute(true)]
[GuidAttribute("1C5F7CC3-31B4-4d81-829F-3EB5D692F7BD")]
[ClassInterfaceAttribute(ClassInterfaceType.None)]
public class PortCollection : BindingList<UnitPort>, 
	ICapeCollection, ICustomTypeDescriptor, ICloneable, ICapeIdentification
Inheritance
Object    CollectionUnitPort    BindingListUnitPort    PortCollection
Implements
ICapeCollection, ICapeIdentification, ICustomTypeDescriptor, ICloneable

Remarks

This collection uses the BindingList generic collection to create a collection that only objects that implement the interface. This class also implements the ICustomTypeDescriptor to provide dynamic infomation about the collection.

Since this class utilizes a generic collection class, .Net based objects can obtain the Port objects directly by using the index of the object. The .Net collection is 0-index, that is, the index of the first Port is 0, and the nth Port has an index of n-1.

In addition, the collection can be accessed through the ICapeCollection interface. The ICapeCollection members are implemented privately, making them available only available through the interface.

Constructors

PortCollection Initailizes a new instance of the PortCollection collection class.

Properties

ComponentDescription Gets and sets the description of the component.
ComponentName Gets and sets the name of the component.

Methods

OnComponentDescriptionChanged Occurs when the user changes of the description of a component.
OnComponentNameChanged Occurs when the user changes of the description of a component.

Events

ComponentDescriptionChanged Occurs when the user changes of the description of a component.
ComponentNameChanged Occurs when the user changes of the name of a component.

Fields

Extension Methods

GetEnumNames
(Defined by General)
IsValidDouble
(Defined by General)

Explicit Interface Implementations

ICapeCollectionCount Gets the number of items currently stored in the collection.
ICapeCollectionItem Gets the specific item stored within the collection, identified by its ICapeIdentification.ComponentName or 1-based index passed as an argument to the method.
ICloneableClone Creates a copy of the collection.
ICustomTypeDescriptorGetAttributesReturns a collection of custom attributes for this instance of a component.
ICustomTypeDescriptorGetClassNameReturns the class name of this instance of a component.
ICustomTypeDescriptorGetComponentNameReturns the name of this instance of a component.
ICustomTypeDescriptorGetConverterReturns a type converter for this instance of a component.
ICustomTypeDescriptorGetDefaultEventReturns the default event for this instance of a component.
ICustomTypeDescriptorGetDefaultPropertyReturns the default property for this instance of a component.
ICustomTypeDescriptorGetEditorReturns an editor of the specified type for this instance of a component.
ICustomTypeDescriptorGetEventsReturns the events for this instance of a component.
ICustomTypeDescriptorGetEvents(Attribute)Returns the events for this instance of a component using the specified attribute array as a filter.
ICustomTypeDescriptorGetPropertiesReturns the properties for this instance of a component.
ICustomTypeDescriptorGetProperties(Attribute)Returns the properties for this instance of a component using the attribute array as a filter.
ICustomTypeDescriptorGetPropertyOwnerReturns an object that contains the property described by the specified property descriptor.

See Also