X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FDeque.html;fp=docs%2Fclasses%2FQueue.html;h=b0c57010e5f00c2ca5e59424699d4bf6f51c9ea1;hb=31542ddfe8297d3bd0f9cf97a3de06a03dafc15d;hp=68883fdbf19329d5c516207745cc8ac2dcf5cd45;hpb=c55c9b5d98761c0d49691c2550dc1de7dca53c3a;p=poolifier.git diff --git a/docs/classes/Queue.html b/docs/classes/Deque.html similarity index 64% rename from docs/classes/Queue.html rename to docs/classes/Deque.html index 68883fdb..b0c57010 100644 --- a/docs/classes/Queue.html +++ b/docs/classes/Deque.html @@ -1,4 +1,4 @@ -Queue | poolifier - v2.6.31
+Deque | poolifier - v2.6.32
  • Preparing search index...
  • -
  • The search index is not available
poolifier - v2.6.31
+
  • The search index is not available
  • poolifier - v2.6.32
    -

    Class Queue<T>

    +
  • Deque
  • +

    Class Deque<T>

    -

    Queue

    +

    Deque. +Implemented with a doubly linked list.

    @@ -24,15 +25,15 @@
    • T

      -

      Type of queue items.

      +

      Type of deque values.

    Hierarchy

      -
    • Queue
    @@ -40,66 +41,71 @@

    Constructors

    +
  • Defined in src/deque.ts:27
  • Properties

    -
    - -
    items: T[]
    maxSize: number
    -

    The maximum size of the queue.

    +

    The maximum size of the deque.

    -
    - -
    offset: number
    +
  • Defined in src/deque.ts:25
  • size: number
    -

    The size of the queue.

    +

    The size of the deque.

    +
  • Defined in src/deque.ts:23
  • +
    + +
    tail?: Node<T>

    Methods

    @@ -107,70 +113,136 @@
    +
    + +
    +
  • Defined in src/deque.ts:163
    • -

      Clears the queue.

      +

      Clears the deque.

      Returns void

    -
    - +
  • Defined in src/deque.ts:124
  • +
    + +
    +
    +
      - +
    • -

      Dequeue an item.

      +

      Peeks at the first value.

      -

      Returns undefined | T

      The dequeued item or undefined if the queue is empty.

      +

      Returns undefined | T

      The first value or undefined if the deque is empty.

    -
    - +
  • Defined in src/deque.ts:109
  • +
    +
      - +
    • -

      Enqueue an item.

      +

      Peeks at the last value.

      +
      +

      Returns undefined | T

      The last value or undefined if the deque is empty.

      + +
    +
    + +
      + +
    • +

      Pops a value from the deque.

      +
      +

      Returns undefined | T

      The popped value or undefined if the deque is empty.

      + +
    +
    + +
      + +
    • +

      Appends a value to the deque.

      Parameters

      • -
        item: T
        -

        Item to enqueue.

        +
        value: T
        +

        Value to append.

      Returns number

      The new size of the queue.

    -
    - +
  • Defined in src/deque.ts:37
  • +
    + +
      + +
    • +

      Shifts a value from the deque.

      +
      +

      Returns undefined | T

      The shifted value or undefined if the deque is empty.

      + +
    +
    +
      - +
    • -

      Peeks at the first item.

      +

      Prepends a value to the deque.

      -

      Returns undefined | T

      The first item or undefined if the queue is empty.

      +
      +

      Parameters

      +
        +
      • +
        value: T
        +

        Value to prepend.

        +
        +
      +

      Returns number

      The new size of the queue.

    +
  • Defined in src/deque.ts:54