LinkedListNode<T>
A node in a doubly linked list.
Constructors
| Overload | Description |
|---|---|
| new LinkedListNode(value: T, _list: LinkedList<T>, _next: null | LinkedListNode<T>, _prev: null | LinkedListNode<T>, _listId: null | Symbol): LinkedListNode<T> |
Properties
| Name | Description |
|---|---|
| list | |
| next | The next node in the list. |
| prev | The previous node in the list. |
Methods
| Name | Description |
|---|---|
| attachNext(node: LinkedListNode<T>): void | Attaches a node to the next position. |
| attachPrev(node: LinkedListNode<T>): void | Attaches a node to the previous position. |
| detach(): void | Detaches the node from its list. |
| hasEqualList(id: Symbol): boolean | checks if node is in the same list with provided id. |
| hasList(): boolean | checks if node is in a list. |
| isEqual(node: LinkedListNode<any>): boolean | checks if the node is equal to another node. |
TSDS