In This Article

NavigationPaneCollection Class

Encapsulates a collection of NavigationPane components.

[TypeConverter(typeof(NavigationPaneCollectionConverter))]
public class NavigationPaneCollection
Inheritance:
object object

Remarks

This class is a zero-based indexed collection.

Constructors

NavigationPaneCollection(ControlCollection)

Initializes an instance of the class.

public NavigationPaneCollection(Control.ControlCollection navigationBarControls)
Parameter Type Description
navigationBarControls Control.ControlCollection

The control collection to link to.

See Also

Properties

Count

Gets the number of elements contained in the ICollection.

public int Count { get; }

Property Value

int:

The number of elements contained in the ICollection.

See Also

this[int]

The NavigationPane at the specified index.

public NavigationPane this[int index] { get; }
Parameter Type Description
index int

The index of the NavigationPane to return.

Property Value

NavigationPane

See Also

this[string]

The first NavigationPane with the specified key.

public NavigationPane? this[string key] { get; }
Parameter Type Description
key string

The key of the NavigationPane to return.

Property Value

NavigationPane

See Also

Methods

Add(NavigationPane)

Adds an item to the ICollection<T>.

public void Add(NavigationPane item)
Parameter Type Description
item NavigationPane

The object to add to the ICollection<T>.

Exceptions

Type Condition
NotSupportedException

The ICollection<T> is read-only.

See Also

AddRange(IEnumerable<NavigationPane>)

Adds the NavigationPane control instances to the collection.

public void AddRange(IEnumerable<NavigationPane> panes)
Parameter Type Description
panes IEnumerable<NavigationPane>

An enumerable of NavigationPane controls to add.

See Also

Clear()

Removes all items from the IList.

public void Clear()

Exceptions

Type Condition
NotSupportedException

The IList is read-only.

See Also

Contains(NavigationPane)

Determines whether the specified NavigationPane is in the collection.

public bool Contains(NavigationPane item)
Parameter Type Description
item NavigationPane

The NavigationPane to look for.

Returns

bool:

true if the collection contains the NavigationPane; otherwise, false.

See Also

Contains(string)

Determines whether the a NavigationPane with the specified key is in the collection.

public bool Contains(string key)
Parameter Type Description
key string

The key of the NavigationPane to look for.

Returns

bool:

true if the collection contains a NavigationPane with the specified key; otherwise, false.

See Also

CopyTo(NavigationPane[], int)

Copies the elements of the ICollection<T> to an Array, starting at a particular Array index.

public void CopyTo(NavigationPane[] array, int arrayIndex)
Parameter Type Description
array NavigationPane[]

The one-dimensional Array that is the destination of the elements copied from ICollection<T>. The Array must have zero-based indexing.

arrayIndex int

The zero-based index in array at which copying begins.

Exceptions

Type Condition
ArgumentNullException

array is null.

ArgumentOutOfRangeException

arrayIndex is less than 0.

ArgumentException

The number of elements in the source ICollection<T> is greater than the available space from arrayIndex to the end of the destination array.

See Also

IndexOf(NavigationPane)

Returns the index of the specified NavigationPane in the collection.

public int IndexOf(NavigationPane item)
Parameter Type Description
item NavigationPane

The NavigationPane to look for.

Returns

int:

If found, the index where the NavigationPane is in the collection; otherwise, -1.

See Also

IndexOf(string)

Returns the index of the first NavigationPane with the specified key in the collection.

public int IndexOf(string key)
Parameter Type Description
key string

The key of the NavigationPane to look for.

Returns

int:

If found, the index where the first NavigationPane is in the collection; otherwise, -1.

See Also

Insert(int, NavigationPane)

Inserts an item to the IList<T> at the specified index.

public void Insert(int index, NavigationPane item)
Parameter Type Description
index int

The zero-based index at which item should be inserted.

item NavigationPane

The object to insert into the IList<T>.

Exceptions

Type Condition
ArgumentOutOfRangeException

index is not a valid index in the IList<T>.

NotSupportedException

The IList<T> is read-only.

See Also

MoveTo(NavigationPane, int)

Moves a NavigationPane to the specified index.

public void MoveTo(NavigationPane pane, int newIndex)
Parameter Type Description
pane NavigationPane

The NavigationPane to move.

newIndex int

The new index.

See Also

Remove(NavigationPane)

Removes the first occurrence of a specific object from the ICollection<T>.

public bool Remove(NavigationPane item)
Parameter Type Description
item NavigationPane

The object to remove from the ICollection<T>.

Returns

bool:

true if item was successfully removed from the ICollection<T>; otherwise, false. This method also returns false if item is not found in the original ICollection<T>.

Exceptions

Type Condition
NotSupportedException

The ICollection<T> is read-only.

See Also

RemoveAt(int)

Removes the NavigationPane at the specified index from the collection.

public void RemoveAt(int index)
Parameter Type Description
index int

The index of the NavigationPane to remove.

See Also

Inherited Members

Extension Methods

See Also