An implementation of a doubly linked list that provides direct access to the cells that store the elements.

Namespace: yWorks.yFiles.Algorithms
Assembly: yWorks.yFilesSilverlight.Algorithms (in yWorks.yFilesSilverlight.Algorithms.dll) Version: 2.4.0.0

Syntax

C#
public class YList : IList, ICollection, IList, ICollection, IList<Object>, ICollection<Object>, IEnumerable<Object>, IEnumerable
Visual Basic
Public Class YList _ Implements IList, ICollection, IList, ICollection, _ IList(Of Object), ICollection(Of Object), IEnumerable(Of Object), _ IEnumerable

Remarks

An implementation of a doubly linked list that provides direct access to the cells that store the elements. The cells are represented by class ListCell .

This class supports fast access and removal operations, specifically, it is possible to remove an element in constant time (i.e. O(1)) given a reference to its list cell.

Class YList supports iteration over the elements either by using the list cells directly (methods FirstCell / LastCell together with SuccCell(ListCell) / PredCell(ListCell) , respectively) or by means of a cursor ( Cursor()()()() ).

Furthermore, YList offers its own Sort()()()() method. Note that this class also provides all relevant methods to use the list like a stack data type.

This implementation permits nullNothingnullptra null reference (Nothing in Visual Basic) as values. It implements the IList interface but does not support the SubList(Int32, Int32) method. The implementation of this method will throw an NotSupportedException if invoked. The Iterator()()()() s returned by instances of this class are fail fast, however the Cursor()()()() implementation is not.

Inheritance Hierarchy

System..::..Object
  yWorks.yFiles.Algorithms..::..YList
    yWorks.yFiles.Algorithms..::..EdgeList
    yWorks.yFiles.Algorithms..::..NodeList

See Also