In This Article

StatusBarPanelCollection Class

Represents a collection of StatusBarPanel objects.

public class StatusBarPanelCollection : UIElementCollection, IDisposable, IList, ICollection, IEnumerable
Inheritance:
Object MarshalByRefObject DisposableObject LogicalTreeNodeCollection UIElementCollection Object
Implements:
IDisposable

Remarks

This class is a zero-based indexed collection.

Constructors

StatusBarPanelCollection(IUIElement)

Initializes a new instance of the StatusBarPanelCollection class.

public StatusBarPanelCollection(IUIElement owner)
Parameter Type Description
owner IUIElement

The owner of the collection.

Properties

IsReadOnly

Gets a value indicating whether the collection is read-only.

public override bool IsReadOnly { get; }

Property Value

Boolean:

true if the collection is read-only; otherwise, false.

Item[Int32]

Gets or sets the StatusBarPanel at the specified index.

[C#] In C#, this property is the indexer for the StatusBarPanelCollection class.

public StatusBarPanel this[int index] { get; set; }
Parameter Type Description
index Int32

The index of the StatusBarPanel to return.

Property Value

StatusBarPanel:

The StatusBarPanel at the specified index.

Item[String]

Gets the StatusBarPanel with the specified key.

public StatusBarPanel this[string key] { get; }
Parameter Type Description
key String

The key of the StatusBarPanel to return.

Property Value

StatusBarPanel:

The StatusBarPanel with the specified key.

SingularElementName

Gets the short, singular name of the type of child elements in the collection.

protected override string SingularElementName { get; }

Property Value

String:

The short, singular name of the type of child elements in the collection.

Remarks

This value is used within the design-time environment when indicating the count of elements in the collection.

See Also

Methods

Add(StatusBarPanel)

Adds the specified item to the collection.

public int Add(StatusBarPanel item)
Parameter Type Description
item StatusBarPanel

The StatusBarPanel to add to the collection.

Returns

Int32:

The position into which the new item was inserted.

AddRange(StatusBarPanel[])

Adds multiple items to the collection.

public void AddRange(StatusBarPanel[] items)
Parameter Type Description
items StatusBarPanel[]

The array of StatusBarPanel objects to add.

Clear()

Removes all items from the collection.

public void Clear()

Contains(String)

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

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

The key of the StatusBarPanel to look for.

Returns

Boolean:

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

IndexOf(String)

Returns the index of the StatusBarPanel with the specified key in the collection.

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

The key of the StatusBarPanel to look for.

Returns

Int32:

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

Insert(Int32, StatusBarPanel)

Inserts a StatusBarPanel into the collection at the specified index.

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

The zero-based index at which the StatusBarPanel should be inserted.

item StatusBarPanel

The StatusBarPanelto insert.

OnObjectAdded(Int32, ILogicalTreeNode)

Performs additional custom processes after an object is added to the collection.

protected override void OnObjectAdded(int index, ILogicalTreeNode value)
Parameter Type Description
index Int32

The zero-based index at which the object was inserted.

value ILogicalTreeNode

The object that was inserted.

Remarks

The default implementation of this method is intended to be overridden by a derived class to perform some action after the specified object is added.

OnObjectRemoving(Int32, ILogicalTreeNode)

Performs additional custom processes before an object is removed from the collection.

protected override void OnObjectRemoving(int index, ILogicalTreeNode value)
Parameter Type Description
index Int32

The zero-based index from which the object was removed.

value ILogicalTreeNode

The object that was removed.

Remarks

The default implementation of this method is intended to be overridden by a derived class to perform some action before the specified object is removed.

Remove(StatusBarPanel)

Removes the specified StatusBarPanel from the collection.

public void Remove(StatusBarPanel pane)
Parameter Type Description
pane StatusBarPanel

The StatusBarPanel to remove.

RemoveAt(Int32)

Removes the StatusBarPanel at the specified index from the collection.

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

The index of the StatusBarPanel to remove.

ToArray()

Copies the items of the collection to a new StatusBarPanel array.

public StatusBarPanel[] ToArray()

Returns

StatusBarPanel[]:

An array of StatusBarPanel items.

Inherited Members

See Also