Options
All
  • Public
  • Public/Protected
  • All
Menu

Class DoublyLinkedList

Doubly LinkedList data structure

Hierarchy

  • DoublyLinkedList

Constructors

constructor

  • Parameters

    Returns DoublyLinkedList

Properties

compare

compare: Comparator
property

A comparator instance

head

property

head of the linked list

tail

property

tail of the linked list

Methods

append

  • Parameters

    • value: any

    Returns DoublyLinkedList

delete

  • Parameters

    • value: any

    Returns null | DoublyLinkedListNode

deleteHead

  • Returns null | DoublyLinkedListNode

deleteTail

  • Returns null | DoublyLinkedListNode

find

  • Parameters

    • __namedParameters: findArg

    Returns null | DoublyLinkedListNode

fromArray

  • Parameters

    • values: any[]

    Returns DoublyLinkedList

prepend

  • Parameters

    • value: any

    Returns DoublyLinkedList

reverse

  • Returns DoublyLinkedList

toArray

  • toArray(): any[]
  • Returns any[]

toArrayRev

  • toArrayRev(): any[]
  • Returns any[]

toString

  • toString(callback?: function): string
  • Parameters

    • Optional callback: function
        • (value: any): string
        • Parameters

          • value: any

          Returns string

    Returns string

toStringRev

  • toStringRev(callback?: function): string
  • Parameters

    • Optional callback: function
        • (value: any): string
        • Parameters

          • value: any

          Returns string

    Returns string