Class ListNode<T>
Node that contains a read-only value and links to other nodes in a list.
Namespace: GGL.Collections
Assembly: GGL.dll
Syntax
[Serializable]
public class ListNode<T>
Type Parameters
Name | Description |
---|---|
T |
Constructors
| Edit this page View SourceListNode(T)
Create a node with its read-only value.
Declaration
public ListNode(T value)
Parameters
Type | Name | Description |
---|---|---|
T | value | Value of the node |
Properties
| Edit this page View SourceNext
Declaration
public ListNode<T> Next { get; }
Property Value
Type | Description |
---|---|
ListNode<T> | Link to the next node in list. |
Previous
Declaration
public ListNode<T> Previous { get; }
Property Value
Type | Description |
---|---|
ListNode<T> | Link to the previous node in list. |
Value
Declaration
public T Value { get; }
Property Value
Type | Description |
---|---|
T | Read-only value of the node. |
Methods
| Edit this page View SourceLink(ListNode<T>, ListNode<T>)
Link this node to other nodes in a list.
Declaration
public void Link(ListNode<T> previous, ListNode<T> next)
Parameters
Type | Name | Description |
---|---|---|
ListNode<T> | previous | Node that contains a read-only value and links to other nodes in a list. |
ListNode<T> | next | Node that contains a read-only value and links to other nodes in a list. |
Purge()
Delete the value and all links to other nodes.
Declaration
public void Purge()
Operators
| Edit this page View Sourceimplicit operator T(ListNode<T>)
Declaration
public static implicit operator T(ListNode<T> listNode)
Parameters
Type | Name | Description |
---|---|---|
ListNode<T> | listNode | Node that contains a read-only value and links to other nodes in a list. |
Returns
Type | Description |
---|---|
T | Node that contains a read-only value and links to other nodes in a list. |