1 | import { Collection } from "../Collection";
|
2 | import CycleLinkList from "../cyclelinklist/CycleLinkList";
|
3 | import DoubleLinkList from "../doublelinklist/DoubleLinkList";
|
4 | import { LinkNode } from "./LinkNode";
|
5 | export declare class LinkList<T> extends Collection<LinkNode<T>> {
|
6 | private headNode;
|
7 | private tailNode;
|
8 | private size;
|
9 | constructor();
|
10 | readonly Size: number;
|
11 | append(value: T): LinkNode<T>;
|
12 | prepend(value: T): LinkNode<T>;
|
13 | private emptyList;
|
14 | clear(): void;
|
15 | deleteNode(arg: any): boolean;
|
16 | findNode(arg: any): LinkNode<T>;
|
17 | insertAfter(value: T, oriNode: LinkNode<T>): boolean;
|
18 | getHeadNode(): LinkNode<T>;
|
19 | getTailNode(): LinkNode<T>;
|
20 | shift(): LinkNode<T>;
|
21 | pop(): LinkNode<T>;
|
22 | protected __iterate(fn: (item: LinkNode<T>, index: number) => void): void;
|
23 | toString(): string;
|
24 | static fromArray<K>(arr: Array<K>): LinkList<K>;
|
25 | toDoubleLinkList(): DoubleLinkList<T>;
|
26 | toCycleLinkList(): CycleLinkList<T>;
|
27 | }
|
28 | export default LinkList;
|