[]
Represents a collection of elements derived from SvgElement.
public class SvgElementCollection : IList<SvgElement>, ICollection<SvgElement>, IEnumerable<SvgElement>, IEnumerable
Gets the total number of elements the internal data structure can hold without resizing.
public int Capacity { get; }
Gets the number of elements contained in the SvgElementCollection.
public int Count { get; }
Gets or sets the element at the specified index.
public SvgElement this[int index] { get; set; }
index intGets the owner SvgElement.
public SvgElement Owner { get; }
Adds the specified element to the end of the SvgElementCollection.
public void Add(SvgElement element)
element SvgElementAdds the elements to the end of the SvgElementCollection.
public void AddRange(params SvgElement[] elements)
elements SvgElement[]Adds the elements of the specified collection to the end of the SvgElementCollection.
public void AddRange(IEnumerable<SvgElement> collection)
collection System.Collections.Generic.IEnumerable<T><SvgElement>Removes all elements from the SvgElementCollection.
public void Clear()
Determines whether an element is in the SvgElementCollection.
public bool Contains(SvgElement element)
element SvgElementCopies the entire SvgElementCollection to a compatible one-dimensional array, starting at the specified index of the target array.
public void CopyTo(SvgElement[] array, int arrayIndex)
array SvgElement[]The one-dimensional Array that is the destination of the elements.
arrayIndex intThe zero-based index in array at which copying begins.
Ensures that the capacity of this collection is at least the specified capacity.
public int EnsureCapacity(int capacity)
capacity intThe minimum capacity to ensure.
The new capacity of the SvgElementCollection.
Returns an enumerator that iterates through the SvgElementCollection.
public IEnumerator<SvgElement> GetEnumerator()
Searches for the specified element and returns the zero-based index.
public int IndexOf(SvgElement element)
element SvgElementThe element to locate.
The zero-based index of the element, if found; otherwise, -1.
Inserts an element into the SvgElementCollection at the specified index.
public void Insert(int index, SvgElement element)
index intThe zero-based index at which element should be inserted.
element SvgElementThe object to insert.
Moves the element at the fromIndex to the position of the toIndex.
public void Move(int fromIndex, int toIndex)
fromIndex inttoIndex intRemoves the specific element from the SvgElementCollection.
public bool Remove(SvgElement element)
element SvgElementThe element to remove.
true if element is successfully removed. false if element was not found.
Removes the element at the specified index of the SvgElementCollection.
public void RemoveAt(int index)
index intThe zero-based index of the element to remove.
Removes a range of elements from the SvgElementCollection.
public void RemoveRange(int index, int count)
index intThe zero-based starting index of the range of elements to remove.
count intThe number of elements to remove.
Swaps two elements at the index1 and index2.
public void Swap(int index1, int index2)
index1 intindex2 intSets the capacity to the actual number of elements in the SvgElementCollection.
public void TrimExcess()