Class PinCollection
public abstract class PinCollection : CorePropertyChanged, IPinCollection, IEnumerable<IPin>, IEnumerable
- Inheritance
-
objectCorePropertyChangedPinCollection
- Implements
- Derived
Constructors
PinCollection(INode, string)
Creates a new instance of the PinCollection class
protected PinCollection(INode node, string name)
Parameters
Properties
Direction
Gets the direction of the pin collection and all its pins
public abstract PinDirection Direction { get; }
Property Value
Name
Gets the name of the pin collection
public string Name { get; }
Property Value
Node
Gets the node the pin collection belongs to
public INode Node { get; }
Property Value
Pins
Gets a read only observable collection of the pins
public ReadOnlyCollection<IPin> Pins { get; }
Property Value
Type
Gets the type of values the pin collection and all its pins holds
public abstract Type Type { get; }
Property Value
Methods
Add(IPin)
Adds the provided pin to the collection
public void Add(IPin pin)
Parameters
pinIPin
CreatePin()
Creates a new pin compatible with this collection
public abstract IPin CreatePin()
Returns
- IPin
The newly created pin
GetEnumerator()
Returns an enumerator that iterates through the collection.
public IEnumerator<IPin> GetEnumerator()
Returns
- IEnumerator<IPin>
An enumerator that can be used to iterate through the collection.
Remove(IPin)
Removes the provided pin from the collection
public bool Remove(IPin pin)
Parameters
pinIPinThe pin to remove
Returns
Reset()
Resets the pin collection, causing its pins to re-evaluate the next time its value is requested
public void Reset()
Events
PinAdded
Occurs when a pin was added to the collection
public event EventHandler<SingleValueEventArgs<IPin>>? PinAdded
Event Type
PinRemoved
Occurs when a pin was removed from the collection
public event EventHandler<SingleValueEventArgs<IPin>>? PinRemoved