@devexperts/dxcharts-lite
Version:
29 lines (28 loc) • 916 B
TypeScript
/*
* Copyright (C) 2019 - 2025 Devexperts Solutions IE Limited
* This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
* If a copy of the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
export declare class ListNode<T> {
data: T;
next: ListNode<T> | null;
constructor(data: T);
}
/**
* Implementation of Linked list data structure.
* @param _head
*/
export declare class LinkedList<T> {
private _head;
private _tail;
private length;
constructor(head?: ListNode<T>);
insertAtEnd(data: T): void;
insertAt(position: number, data: T): null | undefined;
removeAt(position: number): null | undefined;
getNodePosition(node: ListNode<T>): number;
size(): number;
get head(): ListNode<T> | null;
get tail(): ListNode<T> | null;
[Symbol.iterator](): Generator<T, void, unknown>;
}