Table of Contents

Class OperationOwnedRuleCollection

Namespace
NMF.Interop.Legacy.Cmof
Assembly
NMF.UMLInterop.dll

The collection class to implement the refined ownedRule reference for the Operation class

public class OperationOwnedRuleCollection : IListExpression<IConstraint>, ICollectionExpression<IConstraint>, IEnumerableExpression<IConstraint>, IEnumerableExpression, IList<IConstraint>, ICollection<IConstraint>, IEnumerable<IConstraint>, IEnumerable
Inheritance
OperationOwnedRuleCollection
Implements
Inherited Members

Constructors

OperationOwnedRuleCollection(IOperation)

Creates a new instance

public OperationOwnedRuleCollection(IOperation parent)

Parameters

parent IOperation

Properties

Count

Gets the amount of elements contained in this collection

public virtual int Count { get; }

Property Value

int

IsAttached

Returns that this composed collection is always attached.

public bool IsAttached { get; }

Property Value

bool

IsReadOnly

Gets a value indicating that the collection is not read-only

public virtual bool IsReadOnly { get; }

Property Value

bool

this[int]

Gets or sets the item at the given position

public virtual IConstraint this[int index] { get; set; }

Parameters

index int

Property Value

IConstraint

Methods

Add(IConstraint)

Adds the given element to the collection

public virtual void Add(IConstraint item)

Parameters

item IConstraint

The item to add

AsNotifiable()

Gets an observable version of this collection

public virtual INotifyCollection<IConstraint> AsNotifiable()

Returns

INotifyCollection<IConstraint>

Attach()

Attaches this collection class

public void Attach()

Clear()

Clears the collection and resets all references that implement it.

public virtual void Clear()

Contains(IConstraint)

Gets a value indicating whether the given element is contained in the collection

public virtual bool Contains(IConstraint item)

Parameters

item IConstraint

The item that should be looked out for

Returns

bool

True, if it is contained, otherwise False

CopyTo(IConstraint[], int)

Copies the contents of the collection to the given array starting from the given array index

public virtual void CopyTo(IConstraint[] array, int arrayIndex)

Parameters

array IConstraint[]

The array in which the elements should be copied

arrayIndex int

The starting index

Detach()

Detaches this collection class

public void Detach()

GetEnumerator()

Gets an enumerator that enumerates the collection

public virtual IEnumerator<IConstraint> GetEnumerator()

Returns

IEnumerator<IConstraint>

A generic enumerator

IndexOf(IConstraint)

Gets the index of the given element

public virtual int IndexOf(IConstraint item)

Parameters

item IConstraint

The item that should be looked for

Returns

int

The index of the given element or -1 if it was not found

Insert(int, IConstraint)

Inserts the given item at the given index of the collection

public virtual void Insert(int index, IConstraint item)

Parameters

index int

The index where to add the item

item IConstraint

The item that should be added

OnCollectionChanged(NotifyCollectionChangedEventArgs)

Fires the CollectionChanged event

protected virtual void OnCollectionChanged(NotifyCollectionChangedEventArgs eventArgs)

Parameters

eventArgs NotifyCollectionChangedEventArgs

Remove(IConstraint)

Removes the given item from the collection

public virtual bool Remove(IConstraint item)

Parameters

item IConstraint

The item that should be removed

Returns

bool

True, if the item was removed, otherwise False

RemoveAt(int)

Removes the item at the given position

public virtual void RemoveAt(int index)

Parameters

index int

The index where to remove the item

Events

CollectionChanged

Gets fired when the contents of this collection changes

public event NotifyCollectionChangedEventHandler CollectionChanged

Event Type

NotifyCollectionChangedEventHandler