collect-your-stuff 1.1.9 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (76) hide show
  1. package/README.md +1265 -232
  2. package/browser/collect-your-stuff.js +131 -149
  3. package/browser/collect-your-stuff.min.js +1 -1
  4. package/dist/collections/arrayable/ArrayElement.d.ts +2 -3
  5. package/dist/collections/arrayable/ArrayElement.js +2 -2
  6. package/dist/collections/arrayable/ArrayElement.min.js +1 -1
  7. package/dist/collections/arrayable/Arrayable.d.ts +4 -5
  8. package/dist/collections/arrayable/Arrayable.js +7 -8
  9. package/dist/collections/arrayable/Arrayable.min.js +1 -1
  10. package/dist/collections/doubly-linked-list/DoubleLinker.d.ts +2 -3
  11. package/dist/collections/doubly-linked-list/DoubleLinker.js +4 -5
  12. package/dist/collections/doubly-linked-list/DoubleLinker.min.js +1 -1
  13. package/dist/collections/doubly-linked-list/DoublyLinkedList.d.ts +4 -5
  14. package/dist/collections/doubly-linked-list/DoublyLinkedList.js +11 -12
  15. package/dist/collections/doubly-linked-list/DoublyLinkedList.min.js +1 -1
  16. package/dist/collections/linked-list/LinkedList.d.ts +4 -5
  17. package/dist/collections/linked-list/LinkedList.js +9 -10
  18. package/dist/collections/linked-list/LinkedList.min.js +1 -1
  19. package/dist/collections/linked-list/Linker.d.ts +2 -3
  20. package/dist/collections/linked-list/Linker.js +4 -5
  21. package/dist/collections/linked-list/Linker.min.js +1 -1
  22. package/dist/collections/linked-tree-list/LinkedTreeList.d.ts +4 -5
  23. package/dist/collections/linked-tree-list/LinkedTreeList.js +15 -16
  24. package/dist/collections/linked-tree-list/LinkedTreeList.min.js +1 -1
  25. package/dist/collections/linked-tree-list/TreeLinker.d.ts +4 -5
  26. package/dist/collections/linked-tree-list/TreeLinker.js +8 -9
  27. package/dist/collections/linked-tree-list/TreeLinker.min.js +1 -1
  28. package/dist/collections/queue/Queue.d.ts +4 -5
  29. package/dist/collections/queue/Queue.js +8 -9
  30. package/dist/collections/queue/Queue.min.js +1 -1
  31. package/dist/collections/queue/Queueable.d.ts +2 -3
  32. package/dist/collections/queue/Queueable.js +4 -5
  33. package/dist/collections/queue/Queueable.min.js +1 -1
  34. package/dist/collections/stack/Stack.d.ts +4 -5
  35. package/dist/collections/stack/Stack.js +8 -9
  36. package/dist/collections/stack/Stack.min.js +1 -1
  37. package/dist/collections/stack/Stackable.d.ts +2 -3
  38. package/dist/collections/stack/Stackable.js +4 -5
  39. package/dist/collections/stack/Stackable.min.js +1 -1
  40. package/dist/main.d.ts +10 -10
  41. package/dist/main.js +16 -17
  42. package/dist/main.min.js +1 -1
  43. package/dist/recipes/ArrayIterator.d.ts +2 -3
  44. package/dist/recipes/ArrayIterator.js +2 -2
  45. package/dist/recipes/ArrayIterator.min.js +1 -1
  46. package/dist/recipes/DoubleLinkerIterator.d.ts +2 -3
  47. package/dist/recipes/DoubleLinkerIterator.js +2 -2
  48. package/dist/recipes/DoubleLinkerIterator.min.js +1 -1
  49. package/dist/recipes/IsArrayable.d.ts +2 -2
  50. package/dist/recipes/IsDoubleLinker.d.ts +2 -2
  51. package/dist/recipes/IsElement.d.ts +1 -1
  52. package/dist/recipes/IsLinker.d.ts +2 -2
  53. package/dist/recipes/IsTree.d.ts +3 -3
  54. package/dist/recipes/IsTreeNode.d.ts +4 -4
  55. package/dist/recipes/LinkerIterator.d.ts +2 -3
  56. package/dist/recipes/LinkerIterator.js +2 -2
  57. package/dist/recipes/LinkerIterator.min.js +1 -1
  58. package/dist/recipes/Runnable.d.ts +1 -1
  59. package/dist/recipes/Runnable.js +2 -2
  60. package/dist/recipes/Runnable.min.js +1 -1
  61. package/dist/recipes/TreeLinkerIterator.d.ts +2 -3
  62. package/dist/recipes/TreeLinkerIterator.js +4 -5
  63. package/dist/recipes/TreeLinkerIterator.min.js +1 -1
  64. package/dist/recipes/recipes.d.ts +3 -4
  65. package/dist/recipes/recipes.js +6 -8
  66. package/dist/recipes/recipes.min.js +1 -1
  67. package/dist/services/parseTree.d.ts +2 -3
  68. package/dist/services/parseTree.js +4 -5
  69. package/dist/services/parseTree.min.js +1 -1
  70. package/dist/services/parseTreeNext.d.ts +2 -3
  71. package/dist/services/parseTreeNext.js +2 -2
  72. package/dist/services/parseTreeNext.min.js +1 -1
  73. package/dist/services/services.d.ts +3 -4
  74. package/dist/services/services.js +6 -8
  75. package/dist/services/services.min.js +1 -1
  76. package/package.json +1 -1
package/README.md CHANGED
@@ -66,6 +66,47 @@ Data allocation and manipulation.
66
66
  </dd>
67
67
  </dl>
68
68
 
69
+ ## Members
70
+
71
+ <dl>
72
+ <dt><a href="#Stackable">Stackable</a> ⇒ <code><a href="#Stackable">Stackable</a></code></dt>
73
+ <dd><p>Make a new Stackable from the data given if it is not already a valid Stackable.</p>
74
+ </dd>
75
+ <dt><a href="#Stack">Stack</a> ⇒ <code><a href="#Stack">Stack</a></code></dt>
76
+ <dd><p>Convert an array to a Stack.</p>
77
+ </dd>
78
+ <dt><a href="#Queueable">Queueable</a> ⇒ <code><a href="#Queueable">Queueable</a></code></dt>
79
+ <dd><p>Make a new Queueable from the data given if it is not already a valid Queueable.</p>
80
+ </dd>
81
+ <dt><a href="#Queue">Queue</a> ⇒ <code><a href="#Queue">Queue</a></code></dt>
82
+ <dd><p>Convert an array to a Queue.</p>
83
+ </dd>
84
+ <dt><a href="#TreeLinker">TreeLinker</a> ⇒ <code><a href="#TreeLinker">TreeLinker</a></code></dt>
85
+ <dd><p>Make a new DoubleLinker from the data given if it is not already a valid Linker.</p>
86
+ </dd>
87
+ <dt><a href="#LinkedTreeList">LinkedTreeList</a> ⇒ <code><a href="#LinkedTreeList">LinkedTreeList</a></code></dt>
88
+ <dd><p>Convert an array into a LinkedTreeList instance, return the new instance.</p>
89
+ </dd>
90
+ <dt><a href="#Linker">Linker</a> ⇒ <code><a href="#Linker">Linker</a></code></dt>
91
+ <dd><p>Make a new Linker from the data given if it is not already a valid Linker.</p>
92
+ </dd>
93
+ <dt><a href="#LinkedList">LinkedList</a> ⇒ <code><a href="#LinkedList">LinkedList</a></code></dt>
94
+ <dd><p>Convert an array to a LinkedList.</p>
95
+ </dd>
96
+ <dt><a href="#DoublyLinkedList">DoublyLinkedList</a> ⇒ <code><a href="#DoublyLinkedList">DoublyLinkedList</a></code></dt>
97
+ <dd><p>Convert an array into a DoublyLinkedList instance, return the new instance.</p>
98
+ </dd>
99
+ <dt><a href="#DoubleLinker">DoubleLinker</a> ⇒ <code><a href="#DoubleLinker">DoubleLinker</a></code></dt>
100
+ <dd><p>Make a new DoubleLinker from the data given if it is not already a valid Linker.</p>
101
+ </dd>
102
+ <dt><a href="#Arrayable">Arrayable</a> ⇒ <code><a href="#Arrayable">Arrayable</a></code></dt>
103
+ <dd><p>Convert an array to an Arrayable.</p>
104
+ </dd>
105
+ <dt><a href="#ArrayElement">ArrayElement</a> ⇒ <code><a href="#ArrayElement">ArrayElement</a></code></dt>
106
+ <dd><p>Make a new Element from the data given if it is not already a valid Element.</p>
107
+ </dd>
108
+ </dl>
109
+
69
110
  ## Constants
70
111
 
71
112
  <dl>
@@ -196,7 +237,6 @@ Stackable represents a runnable entry in stack.
196
237
  * [.task](#Stackable+task) ⇒ <code>\*</code>
197
238
  * [.run()](#Stackable+run) ⇒ <code>\*</code>
198
239
  * _static_
199
- * [.make(stackable, [classType])](#Stackable.make) ⇒ [<code>Stackable</code>](#Stackable)
200
240
  * [.fromArray([values], [classType])](#Stackable.fromArray) ⇒ <code>Object</code>
201
241
 
202
242
  <a name="new_Stackable_new"></a>
@@ -224,18 +264,6 @@ Retrieve the data which should be formed as a task.
224
264
  Run the stacked task.
225
265
 
226
266
  **Kind**: instance method of [<code>Stackable</code>](#Stackable)
227
- <a name="Stackable.make"></a>
228
-
229
- ### Stackable.make(stackable, [classType]) ⇒ [<code>Stackable</code>](#Stackable)
230
- Make a new Stackable from the data given if it is not already a valid Stackable.
231
-
232
- **Kind**: static method of [<code>Stackable</code>](#Stackable)
233
-
234
- | Param | Type | Default | Description |
235
- | --- | --- | --- | --- |
236
- | stackable | [<code>Stackable</code>](#Stackable) \| <code>\*</code> | | Return a valid Stackable instance from given data, or even an already valid one. |
237
- | [classType] | <code>IsLinker</code> | <code>Stackable</code> | Provide the type of IsLinker to use. |
238
-
239
267
  <a name="Stackable.fromArray"></a>
240
268
 
241
269
  ### Stackable.fromArray([values], [classType]) ⇒ <code>Object</code>
@@ -257,15 +285,12 @@ Store a collection of items which can only be inserted and removed from the top.
257
285
 
258
286
  * [Stack](#Stack)
259
287
  * [new Stack(stackedList, listClass, stackableClass)](#new_Stack_new)
260
- * _instance_
261
- * [.empty()](#Stack+empty) ⇒ <code>boolean</code>
262
- * [.top()](#Stack+top) ⇒ [<code>Stackable</code>](#Stackable)
263
- * [.pop()](#Stack+pop) ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
264
- * [.push(stackable)](#Stack+push)
265
- * [.remove()](#Stack+remove) ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
266
- * [.size()](#Stack+size) ⇒ <code>number</code>
267
- * _static_
268
- * [.fromArray(values, stackableClass, listClass)](#Stack.fromArray) ⇒ [<code>Stack</code>](#Stack)
288
+ * [.empty()](#Stack+empty) ⇒ <code>boolean</code>
289
+ * [.top()](#Stack+top) ⇒ [<code>Stackable</code>](#Stackable)
290
+ * [.pop()](#Stack+pop) ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
291
+ * [.push(stackable)](#Stack+push)
292
+ * [.remove()](#Stack+remove) ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
293
+ * [.size()](#Stack+size) ⇒ <code>number</code>
269
294
 
270
295
  <a name="new_Stack_new"></a>
271
296
 
@@ -320,19 +345,6 @@ Remove the next stacked task and return it.
320
345
  Get the size of the current stack.
321
346
 
322
347
  **Kind**: instance method of [<code>Stack</code>](#Stack)
323
- <a name="Stack.fromArray"></a>
324
-
325
- ### Stack.fromArray(values, stackableClass, listClass) ⇒ [<code>Stack</code>](#Stack)
326
- Convert an array to a Stack.
327
-
328
- **Kind**: static method of [<code>Stack</code>](#Stack)
329
-
330
- | Param | Type | Description |
331
- | --- | --- | --- |
332
- | values | <code>Array</code> | An array of values which will be converted to stackables in this queue |
333
- | stackableClass | [<code>Stackable</code>](#Stackable) | The class to use for each stackable |
334
- | listClass | [<code>Stack</code>](#Stack) \| <code>Iterable</code> | The class to use to manage the stackables |
335
-
336
348
  <a name="Queueable"></a>
337
349
 
338
350
  ## Queueable ⇐ [<code>Linker</code>](#Linker)
@@ -349,7 +361,6 @@ Queueable represents a runnable entry in a queue.
349
361
  * [.markCompleted(completeResponse)](#Queueable+markCompleted) ⇒ <code>completeResponse</code>
350
362
  * [.run()](#Queueable+run) ⇒ <code>completeResponse</code>
351
363
  * _static_
352
- * [.make(queueable, [classType])](#Queueable.make) ⇒ [<code>Queueable</code>](#Queueable)
353
364
  * [.fromArray(values, [classType])](#Queueable.fromArray) ⇒ <code>Object</code>
354
365
 
355
366
  <a name="new_Queueable_new"></a>
@@ -397,18 +408,6 @@ Set this queueable as completed.
397
408
  Intend to run the queued task when it is ready. If ready, mark this task as running and run the task.
398
409
 
399
410
  **Kind**: instance method of [<code>Queueable</code>](#Queueable)
400
- <a name="Queueable.make"></a>
401
-
402
- ### Queueable.make(queueable, [classType]) ⇒ [<code>Queueable</code>](#Queueable)
403
- Make a new Queueable from the data given if it is not already a valid Queueable.
404
-
405
- **Kind**: static method of [<code>Queueable</code>](#Queueable)
406
-
407
- | Param | Type | Default | Description |
408
- | --- | --- | --- | --- |
409
- | queueable | [<code>Queueable</code>](#Queueable) \| <code>\*</code> | | Return a valid Queueable instance from given data, or even an already valid one. |
410
- | [classType] | <code>IsLinker</code> | <code>Queueable</code> | Provide the type of IsLinker to use. |
411
-
412
411
  <a name="Queueable.fromArray"></a>
413
412
 
414
413
  ### Queueable.fromArray(values, [classType]) ⇒ <code>Object</code>
@@ -430,15 +429,12 @@ Maintain a series of queued items.
430
429
 
431
430
  * [Queue](#Queue)
432
431
  * [new Queue(queuedList, listClass, queueableClass)](#new_Queue_new)
433
- * _instance_
434
- * [.dequeue()](#Queue+dequeue) ⇒ <code>completeResponse</code> \| <code>\*</code>
435
- * [.empty()](#Queue+empty) ⇒ <code>boolean</code>
436
- * [.enqueue(queueable)](#Queue+enqueue)
437
- * [.peek()](#Queue+peek) ⇒ [<code>Queueable</code>](#Queueable)
438
- * [.remove()](#Queue+remove) ⇒ [<code>Queueable</code>](#Queueable) \| <code>null</code>
439
- * [.size()](#Queue+size) ⇒ <code>number</code>
440
- * _static_
441
- * [.fromArray(values, queueableClass, listClass)](#Queue.fromArray) ⇒ [<code>Queue</code>](#Queue)
432
+ * [.dequeue()](#Queue+dequeue) ⇒ <code>completeResponse</code> \| <code>\*</code>
433
+ * [.empty()](#Queue+empty) ⇒ <code>boolean</code>
434
+ * [.enqueue(queueable)](#Queue+enqueue)
435
+ * [.peek()](#Queue+peek) ⇒ [<code>Queueable</code>](#Queueable)
436
+ * [.remove()](#Queue+remove) ⇒ [<code>Queueable</code>](#Queueable) \| <code>null</code>
437
+ * [.size()](#Queue+size) ⇒ <code>number</code>
442
438
 
443
439
  <a name="new_Queue_new"></a>
444
440
 
@@ -493,19 +489,6 @@ Remove the next queued item and return it.
493
489
  Get the length of the current queue.
494
490
 
495
491
  **Kind**: instance method of [<code>Queue</code>](#Queue)
496
- <a name="Queue.fromArray"></a>
497
-
498
- ### Queue.fromArray(values, queueableClass, listClass) ⇒ [<code>Queue</code>](#Queue)
499
- Convert an array to a Queue.
500
-
501
- **Kind**: static method of [<code>Queue</code>](#Queue)
502
-
503
- | Param | Type | Description |
504
- | --- | --- | --- |
505
- | values | <code>Array</code> | An array of values which will be converted to queueables in this queue |
506
- | queueableClass | [<code>Queueable</code>](#Queueable) | The class to use for each queueable |
507
- | listClass | [<code>Queue</code>](#Queue) \| <code>Iterable</code> | The class to use to manage the queueables |
508
-
509
492
  <a name="TreeLinker"></a>
510
493
 
511
494
  ## TreeLinker ⇐ [<code>DoubleLinker</code>](#DoubleLinker)
@@ -519,7 +502,6 @@ TreeLinker represents a node in a LinkedTreeList having a parent (or root) and c
519
502
  * _instance_
520
503
  * [.childrenFromArray(children, listClass)](#TreeLinker+childrenFromArray) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList) \| <code>null</code>
521
504
  * _static_
522
- * [.make(linker, [classType])](#TreeLinker.make) ⇒ [<code>TreeLinker</code>](#TreeLinker)
523
505
  * [.fromArray([values], [classType])](#TreeLinker.fromArray) ⇒ <code>Object</code>
524
506
 
525
507
  <a name="new_TreeLinker_new"></a>
@@ -550,18 +532,6 @@ Create the children for this tree from an array.
550
532
  | children | <code>Array</code> \| <code>null</code> | Provide an array of data / linker references to be children of this tree node. |
551
533
  | listClass | <code>IsArrayable.&lt;IsTreeNode&gt;</code> | Give the type of list to use for storing the children |
552
534
 
553
- <a name="TreeLinker.make"></a>
554
-
555
- ### TreeLinker.make(linker, [classType]) ⇒ [<code>TreeLinker</code>](#TreeLinker)
556
- Make a new DoubleLinker from the data given if it is not already a valid Linker.
557
-
558
- **Kind**: static method of [<code>TreeLinker</code>](#TreeLinker)
559
-
560
- | Param | Type | Default | Description |
561
- | --- | --- | --- | --- |
562
- | linker | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | | Return a valid TreeLinker instance from given data, or even an already valid one. |
563
- | [classType] | <code>IsTreeNode</code> | <code>TreeLinker</code> | Provide the type of IsTreeNode to use. |
564
-
565
535
  <a name="TreeLinker.fromArray"></a>
566
536
 
567
537
  ### TreeLinker.fromArray([values], [classType]) ⇒ <code>Object</code>
@@ -584,26 +554,23 @@ LinkedTreeList represents a collection stored with a root and spreading in branc
584
554
 
585
555
  * [LinkedTreeList](#LinkedTreeList) ⇐ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
586
556
  * [new LinkedTreeList()](#new_LinkedTreeList_new)
587
- * _instance_
588
- * [.list](#LinkedTreeList+list) ⇒ [<code>TreeLinker</code>](#TreeLinker)
589
- * [.first](#LinkedTreeList+first) ⇒ [<code>TreeLinker</code>](#TreeLinker)
590
- * [.last](#LinkedTreeList+last) ⇒ [<code>TreeLinker</code>](#TreeLinker)
591
- * [.length](#LinkedTreeList+length) ⇒ <code>number</code>
592
- * [.parent](#LinkedTreeList+parent) ⇒ [<code>TreeLinker</code>](#TreeLinker)
593
- * [.parent](#LinkedTreeList+parent)
594
- * [.rootParent](#LinkedTreeList+rootParent) ⇒ [<code>TreeLinker</code>](#TreeLinker)
595
- * [.initialize(initialList)](#LinkedTreeList+initialize) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
596
- * [.setChildren(item, children)](#LinkedTreeList+setChildren)
597
- * [.insertAfter(node, newNode)](#LinkedTreeList+insertAfter) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
598
- * [.insertBefore(node, newNode)](#LinkedTreeList+insertBefore) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
599
- * [.append(node, after)](#LinkedTreeList+append) ⇒ [<code>TreeLinker</code>](#TreeLinker)
600
- * [.prepend(node, before)](#LinkedTreeList+prepend) ⇒ [<code>TreeLinker</code>](#TreeLinker)
601
- * [.remove(node)](#LinkedTreeList+remove) ⇒ [<code>TreeLinker</code>](#TreeLinker)
602
- * [.reset()](#LinkedTreeList+reset) ⇒ [<code>TreeLinker</code>](#TreeLinker)
603
- * [.item(index)](#LinkedTreeList+item) ⇒ [<code>TreeLinker</code>](#TreeLinker) \| <code>null</code>
604
- * [.forEach(callback, thisArg)](#LinkedTreeList+forEach)
605
- * _static_
606
- * [.fromArray([values], [linkerClass], [classType])](#LinkedTreeList.fromArray) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
557
+ * [.list](#LinkedTreeList+list) ⇒ [<code>TreeLinker</code>](#TreeLinker)
558
+ * [.first](#LinkedTreeList+first) ⇒ [<code>TreeLinker</code>](#TreeLinker)
559
+ * [.last](#LinkedTreeList+last) ⇒ [<code>TreeLinker</code>](#TreeLinker)
560
+ * [.length](#LinkedTreeList+length) ⇒ <code>number</code>
561
+ * [.parent](#LinkedTreeList+parent) ⇒ [<code>TreeLinker</code>](#TreeLinker)
562
+ * [.parent](#LinkedTreeList+parent)
563
+ * [.rootParent](#LinkedTreeList+rootParent) ⇒ [<code>TreeLinker</code>](#TreeLinker)
564
+ * [.initialize(initialList)](#LinkedTreeList+initialize) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
565
+ * [.setChildren(item, children)](#LinkedTreeList+setChildren)
566
+ * [.insertAfter(node, newNode)](#LinkedTreeList+insertAfter) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
567
+ * [.insertBefore(node, newNode)](#LinkedTreeList+insertBefore) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
568
+ * [.append(node, after)](#LinkedTreeList+append) ⇒ [<code>TreeLinker</code>](#TreeLinker)
569
+ * [.prepend(node, before)](#LinkedTreeList+prepend) ⇒ [<code>TreeLinker</code>](#TreeLinker)
570
+ * [.remove(node)](#LinkedTreeList+remove) ⇒ [<code>TreeLinker</code>](#TreeLinker)
571
+ * [.reset()](#LinkedTreeList+reset) ⇒ [<code>TreeLinker</code>](#TreeLinker)
572
+ * [.item(index)](#LinkedTreeList+item) ⇒ [<code>TreeLinker</code>](#TreeLinker) \| <code>null</code>
573
+ * [.forEach(callback, thisArg)](#LinkedTreeList+forEach)
607
574
 
608
575
  <a name="new_LinkedTreeList_new"></a>
609
576
 
@@ -781,19 +748,6 @@ Be able to run forEach on this LinkedTreeList to iterate over the TreeLinker Ite
781
748
  | callback | <code>forEachCallback</code> | The function to call for-each tree node |
782
749
  | thisArg | [<code>LinkedTreeList</code>](#LinkedTreeList) | Optional, 'this' reference |
783
750
 
784
- <a name="LinkedTreeList.fromArray"></a>
785
-
786
- ### LinkedTreeList.fromArray([values], [linkerClass], [classType]) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
787
- Convert an array into a LinkedTreeList instance, return the new instance.
788
-
789
- **Kind**: static method of [<code>LinkedTreeList</code>](#LinkedTreeList)
790
-
791
- | Param | Type | Default | Description |
792
- | --- | --- | --- | --- |
793
- | [values] | <code>Array</code> | <code>[]</code> | An array of values which will be converted to nodes in this tree-list |
794
- | [linkerClass] | [<code>TreeLinker</code>](#TreeLinker) | <code>TreeLinker</code> | The class to use for each node |
795
- | [classType] | [<code>IsArrayable.&lt;TreeLinker&gt;</code>](#TreeLinker) | <code>LinkedTreeList</code> | Provide the type of IsArrayable to use. |
796
-
797
751
  <a name="Linker"></a>
798
752
 
799
753
  ## Linker ⇐ [<code>ArrayElement</code>](#ArrayElement)
@@ -804,7 +758,6 @@ Linker represents a node in a LinkedList.
804
758
 
805
759
  * [Linker](#Linker) ⇐ [<code>ArrayElement</code>](#ArrayElement)
806
760
  * [new Linker([nodeData])](#new_Linker_new)
807
- * [.make(linker, [classType])](#Linker.make) ⇒ [<code>Linker</code>](#Linker)
808
761
  * [.fromArray([values], [classType])](#Linker.fromArray) ⇒ <code>Object</code>
809
762
 
810
763
  <a name="new_Linker_new"></a>
@@ -819,18 +772,6 @@ Create the new Linker instance, provide the data and optionally give the next Li
819
772
  | [nodeData.data] | <code>\*</code> | <code></code> | The data to be stored in this linker |
820
773
  | [nodeData.next] | [<code>Linker</code>](#Linker) \| <code>null</code> | <code></code> | The reference to the next linker if any |
821
774
 
822
- <a name="Linker.make"></a>
823
-
824
- ### Linker.make(linker, [classType]) ⇒ [<code>Linker</code>](#Linker)
825
- Make a new Linker from the data given if it is not already a valid Linker.
826
-
827
- **Kind**: static method of [<code>Linker</code>](#Linker)
828
-
829
- | Param | Type | Default | Description |
830
- | --- | --- | --- | --- |
831
- | linker | [<code>Linker</code>](#Linker) \| <code>\*</code> | | Return a valid Linker instance from given data, or even an already valid one. |
832
- | [classType] | <code>IsLinker</code> | <code>Linker</code> | Provide the type of IsLinker to use. |
833
-
834
775
  <a name="Linker.fromArray"></a>
835
776
 
836
777
  ### Linker.fromArray([values], [classType]) ⇒ <code>Object</code>
@@ -853,21 +794,18 @@ LinkedList represents a collection stored as a LinkedList with next references.
853
794
 
854
795
  * [LinkedList](#LinkedList) ⇐ [<code>Arrayable</code>](#Arrayable)
855
796
  * [new LinkedList()](#new_LinkedList_new)
856
- * _instance_
857
- * [.list](#LinkedList+list) ⇒ [<code>Linker</code>](#Linker)
858
- * [.first](#LinkedList+first) ⇒ [<code>Linker</code>](#Linker)
859
- * [.last](#LinkedList+last) ⇒ [<code>Linker</code>](#Linker)
860
- * [.length](#LinkedList+length) ⇒ <code>number</code>
861
- * [.initialize(initialList)](#LinkedList+initialize) ⇒ [<code>LinkedList</code>](#LinkedList)
862
- * [.insertAfter(node, newNode)](#LinkedList+insertAfter) ⇒ [<code>LinkedList</code>](#LinkedList)
863
- * [.insertBefore(node, newNode)](#LinkedList+insertBefore) ⇒ [<code>LinkedList</code>](#LinkedList)
864
- * [.append(node, after)](#LinkedList+append) ⇒ [<code>Linker</code>](#Linker)
865
- * [.prepend(node, before)](#LinkedList+prepend) ⇒ [<code>Linker</code>](#Linker)
866
- * [.remove(node)](#LinkedList+remove) ⇒ [<code>Linker</code>](#Linker)
867
- * [.item(index)](#LinkedList+item) ⇒ [<code>Linker</code>](#Linker) \| <code>null</code>
868
- * [.forEach(callback, thisArg)](#LinkedList+forEach) ⇒ [<code>LinkedList</code>](#LinkedList)
869
- * _static_
870
- * [.fromArray(values, linkerClass, [classType])](#LinkedList.fromArray) ⇒ [<code>LinkedList</code>](#LinkedList)
797
+ * [.list](#LinkedList+list) ⇒ [<code>Linker</code>](#Linker)
798
+ * [.first](#LinkedList+first) ⇒ [<code>Linker</code>](#Linker)
799
+ * [.last](#LinkedList+last) ⇒ [<code>Linker</code>](#Linker)
800
+ * [.length](#LinkedList+length) ⇒ <code>number</code>
801
+ * [.initialize(initialList)](#LinkedList+initialize) ⇒ [<code>LinkedList</code>](#LinkedList)
802
+ * [.insertAfter(node, newNode)](#LinkedList+insertAfter) ⇒ [<code>LinkedList</code>](#LinkedList)
803
+ * [.insertBefore(node, newNode)](#LinkedList+insertBefore) ⇒ [<code>LinkedList</code>](#LinkedList)
804
+ * [.append(node, after)](#LinkedList+append) ⇒ [<code>Linker</code>](#Linker)
805
+ * [.prepend(node, before)](#LinkedList+prepend) ⇒ [<code>Linker</code>](#Linker)
806
+ * [.remove(node)](#LinkedList+remove) ⇒ [<code>Linker</code>](#Linker)
807
+ * [.item(index)](#LinkedList+item) ⇒ [<code>Linker</code>](#Linker) \| <code>null</code>
808
+ * [.forEach(callback, thisArg)](#LinkedList+forEach) ⇒ [<code>LinkedList</code>](#LinkedList)
871
809
 
872
810
  <a name="new_LinkedList_new"></a>
873
811
 
@@ -1003,19 +941,6 @@ Be able to run forEach on this LinkedList to iterate over the linkers.
1003
941
  | callback | <code>forEachCallback</code> | The function to call for-each linker |
1004
942
  | thisArg | [<code>LinkedList</code>](#LinkedList) | Optional, 'this' reference |
1005
943
 
1006
- <a name="LinkedList.fromArray"></a>
1007
-
1008
- ### LinkedList.fromArray(values, linkerClass, [classType]) ⇒ [<code>LinkedList</code>](#LinkedList)
1009
- Convert an array to a LinkedList.
1010
-
1011
- **Kind**: static method of [<code>LinkedList</code>](#LinkedList)
1012
-
1013
- | Param | Type | Default | Description |
1014
- | --- | --- | --- | --- |
1015
- | values | <code>Array</code> | | An array of values which will be converted to linkers in this linked-list |
1016
- | linkerClass | <code>IsLinker</code> | | The class to use for each linker |
1017
- | [classType] | [<code>IsArrayable.&lt;Linker&gt;</code>](#Linker) | <code>LinkedList</code> | Provide the type of IsArrayable to use. |
1018
-
1019
944
  <a name="DoublyLinkedList"></a>
1020
945
 
1021
946
  ## DoublyLinkedList ⇐ [<code>LinkedList</code>](#LinkedList)
@@ -1026,22 +951,19 @@ DoublyLinkedList represents a collection stored as a LinkedList with prev and ne
1026
951
 
1027
952
  * [DoublyLinkedList](#DoublyLinkedList) ⇐ [<code>LinkedList</code>](#LinkedList)
1028
953
  * [new DoublyLinkedList()](#new_DoublyLinkedList_new)
1029
- * _instance_
1030
- * [.list](#DoublyLinkedList+list) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1031
- * [.first](#DoublyLinkedList+first) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1032
- * [.last](#DoublyLinkedList+last) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1033
- * [.length](#DoublyLinkedList+length) ⇒ <code>number</code>
1034
- * [.initialize(initialList)](#DoublyLinkedList+initialize) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
1035
- * [.insertAfter(node, newNode)](#DoublyLinkedList+insertAfter) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
1036
- * [.insertBefore(node, newNode)](#DoublyLinkedList+insertBefore) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
1037
- * [.append(node, after)](#DoublyLinkedList+append) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1038
- * [.prepend(node, before)](#DoublyLinkedList+prepend) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1039
- * [.remove(node)](#DoublyLinkedList+remove) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1040
- * [.reset()](#DoublyLinkedList+reset) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1041
- * [.item(index)](#DoublyLinkedList+item) ⇒ [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code>
1042
- * [.forEach(callback, thisArg)](#DoublyLinkedList+forEach)
1043
- * _static_
1044
- * [.fromArray([values], [linkerClass], [classType])](#DoublyLinkedList.fromArray) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
954
+ * [.list](#DoublyLinkedList+list) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
955
+ * [.first](#DoublyLinkedList+first) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
956
+ * [.last](#DoublyLinkedList+last) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
957
+ * [.length](#DoublyLinkedList+length) ⇒ <code>number</code>
958
+ * [.initialize(initialList)](#DoublyLinkedList+initialize) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
959
+ * [.insertAfter(node, newNode)](#DoublyLinkedList+insertAfter) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
960
+ * [.insertBefore(node, newNode)](#DoublyLinkedList+insertBefore) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
961
+ * [.append(node, after)](#DoublyLinkedList+append) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
962
+ * [.prepend(node, before)](#DoublyLinkedList+prepend) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
963
+ * [.remove(node)](#DoublyLinkedList+remove) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
964
+ * [.reset()](#DoublyLinkedList+reset) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
965
+ * [.item(index)](#DoublyLinkedList+item) ⇒ [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code>
966
+ * [.forEach(callback, thisArg)](#DoublyLinkedList+forEach)
1045
967
 
1046
968
  <a name="new_DoublyLinkedList_new"></a>
1047
969
 
@@ -1183,19 +1105,6 @@ Be able to run forEach on this DoublyLinkedList to iterate over the DoubleLinker
1183
1105
  | callback | <code>forEachCallback</code> | The function to call for-each double linker |
1184
1106
  | thisArg | [<code>DoublyLinkedList</code>](#DoublyLinkedList) | Optional, 'this' reference |
1185
1107
 
1186
- <a name="DoublyLinkedList.fromArray"></a>
1187
-
1188
- ### DoublyLinkedList.fromArray([values], [linkerClass], [classType]) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
1189
- Convert an array into a DoublyLinkedList instance, return the new instance.
1190
-
1191
- **Kind**: static method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
1192
-
1193
- | Param | Type | Default | Description |
1194
- | --- | --- | --- | --- |
1195
- | [values] | <code>Array</code> | <code>[]</code> | An array of values which will be converted to linkers in this doubly-linked-list |
1196
- | [linkerClass] | <code>IsDoubleLinker</code> | <code>DoubleLinker</code> | The class to use for each linker |
1197
- | [classType] | <code>IsArrayable.&lt;IsDoubleLinker&gt;</code> | <code>LinkedList</code> | Provide the type of IsArrayable to use. |
1198
-
1199
1108
  <a name="DoubleLinker"></a>
1200
1109
 
1201
1110
  ## DoubleLinker ⇐ [<code>Linker</code>](#Linker)
@@ -1206,7 +1115,6 @@ DoubleLinker represents a node in a DoublyLinkedList which is chained by next an
1206
1115
 
1207
1116
  * [DoubleLinker](#DoubleLinker) ⇐ [<code>Linker</code>](#Linker)
1208
1117
  * [new DoubleLinker([nodeData])](#new_DoubleLinker_new)
1209
- * [.make(linker, [classType])](#DoubleLinker.make) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1210
1118
  * [.fromArray([values], [classType])](#DoubleLinker.fromArray) ⇒ <code>Object</code>
1211
1119
 
1212
1120
  <a name="new_DoubleLinker_new"></a>
@@ -1222,18 +1130,6 @@ Create the new DoubleLinker instance, provide the data and optionally the next a
1222
1130
  | [nodeData.next] | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code> | <code></code> | The reference to the next linker if any |
1223
1131
  | [nodeData.prev] | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code> | <code></code> | The reference to the previous linker if any |
1224
1132
 
1225
- <a name="DoubleLinker.make"></a>
1226
-
1227
- ### DoubleLinker.make(linker, [classType]) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
1228
- Make a new DoubleLinker from the data given if it is not already a valid Linker.
1229
-
1230
- **Kind**: static method of [<code>DoubleLinker</code>](#DoubleLinker)
1231
-
1232
- | Param | Type | Default | Description |
1233
- | --- | --- | --- | --- |
1234
- | linker | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | | Return a valid Linker instance from given data, or even an already valid one. |
1235
- | [classType] | <code>IsDoubleLinker</code> | <code>DoubleLinker</code> | Provide the type of IsDoubleLinker to use. |
1236
-
1237
1133
  <a name="DoubleLinker.fromArray"></a>
1238
1134
 
1239
1135
  ### DoubleLinker.fromArray([values], [classType]) ⇒ <code>Object</code>
@@ -1255,21 +1151,18 @@ Arrayable represents a collection stored as an array.
1255
1151
 
1256
1152
  * [Arrayable](#Arrayable)
1257
1153
  * [new Arrayable()](#new_Arrayable_new)
1258
- * _instance_
1259
- * [.list](#Arrayable+list) ⇒ [<code>Array.&lt;ArrayElement&gt;</code>](#ArrayElement)
1260
- * [.first](#Arrayable+first) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1261
- * [.last](#Arrayable+last) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1262
- * [.length](#Arrayable+length) ⇒ <code>number</code>
1263
- * [.initialize(initialList)](#Arrayable+initialize) ⇒ [<code>Arrayable</code>](#Arrayable)
1264
- * [.insertAfter(node, newNode)](#Arrayable+insertAfter) ⇒ [<code>Arrayable</code>](#Arrayable)
1265
- * [.insertBefore(node, newNode)](#Arrayable+insertBefore) ⇒ [<code>Arrayable</code>](#Arrayable)
1266
- * [.append(node, after)](#Arrayable+append) ⇒ [<code>Arrayable</code>](#Arrayable)
1267
- * [.prepend(node, before)](#Arrayable+prepend) ⇒ [<code>Arrayable</code>](#Arrayable)
1268
- * [.remove(node)](#Arrayable+remove) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1269
- * [.item(index)](#Arrayable+item) ⇒ [<code>ArrayElement</code>](#ArrayElement) \| <code>null</code>
1270
- * [.forEach(callback, thisArg)](#Arrayable+forEach) ⇒ [<code>Arrayable</code>](#Arrayable)
1271
- * _static_
1272
- * [.fromArray(values, [elementClass], [classType])](#Arrayable.fromArray) ⇒ [<code>Arrayable</code>](#Arrayable)
1154
+ * [.list](#Arrayable+list) ⇒ [<code>Array.&lt;ArrayElement&gt;</code>](#ArrayElement)
1155
+ * [.first](#Arrayable+first) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1156
+ * [.last](#Arrayable+last) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1157
+ * [.length](#Arrayable+length) ⇒ <code>number</code>
1158
+ * [.initialize(initialList)](#Arrayable+initialize) ⇒ [<code>Arrayable</code>](#Arrayable)
1159
+ * [.insertAfter(node, newNode)](#Arrayable+insertAfter) ⇒ [<code>Arrayable</code>](#Arrayable)
1160
+ * [.insertBefore(node, newNode)](#Arrayable+insertBefore) ⇒ [<code>Arrayable</code>](#Arrayable)
1161
+ * [.append(node, after)](#Arrayable+append) ⇒ [<code>Arrayable</code>](#Arrayable)
1162
+ * [.prepend(node, before)](#Arrayable+prepend) ⇒ [<code>Arrayable</code>](#Arrayable)
1163
+ * [.remove(node)](#Arrayable+remove) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1164
+ * [.item(index)](#Arrayable+item) ⇒ [<code>ArrayElement</code>](#ArrayElement) \| <code>null</code>
1165
+ * [.forEach(callback, thisArg)](#Arrayable+forEach) ⇒ [<code>Arrayable</code>](#Arrayable)
1273
1166
 
1274
1167
  <a name="new_Arrayable_new"></a>
1275
1168
 
@@ -1393,19 +1286,6 @@ Be able to run forEach on this Arrayable to iterate over the elements.
1393
1286
  | callback | <code>forEachCallback</code> | The function to call for-each element |
1394
1287
  | thisArg | [<code>Arrayable</code>](#Arrayable) | Optional, 'this' reference |
1395
1288
 
1396
- <a name="Arrayable.fromArray"></a>
1397
-
1398
- ### Arrayable.fromArray(values, [elementClass], [classType]) ⇒ [<code>Arrayable</code>](#Arrayable)
1399
- Convert an array to an Arrayable.
1400
-
1401
- **Kind**: static method of [<code>Arrayable</code>](#Arrayable)
1402
-
1403
- | Param | Type | Default | Description |
1404
- | --- | --- | --- | --- |
1405
- | values | <code>Array</code> | | An array of values which will be converted to elements in this arrayable |
1406
- | [elementClass] | <code>IsElement</code> | <code>ArrayElement</code> | The class to use for each element |
1407
- | [classType] | [<code>IsArrayable.&lt;ArrayElement&gt;</code>](#ArrayElement) | <code>Arrayable</code> | Provide the type of IsArrayable to use. |
1408
-
1409
1289
  <a name="ArrayElement"></a>
1410
1290
 
1411
1291
  ## ArrayElement
@@ -1415,7 +1295,6 @@ Element represents a node in an Arrayable.
1415
1295
 
1416
1296
  * [ArrayElement](#ArrayElement)
1417
1297
  * [new ArrayElement([data])](#new_ArrayElement_new)
1418
- * [.make(element, [classType])](#ArrayElement.make) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1419
1298
  * [.fromArray([values], [classType])](#ArrayElement.fromArray) ⇒ <code>Object</code>
1420
1299
 
1421
1300
  <a name="new_ArrayElement_new"></a>
@@ -1428,18 +1307,1172 @@ Create the new Element instance, provide the data and optionally configure the t
1428
1307
  | --- | --- | --- | --- |
1429
1308
  | [data] | <code>\*</code> | <code></code> | The data to be stored in this element. |
1430
1309
 
1431
- <a name="ArrayElement.make"></a>
1310
+ <a name="ArrayElement.fromArray"></a>
1432
1311
 
1433
- ### ArrayElement.make(element, [classType]) ⇒ [<code>ArrayElement</code>](#ArrayElement)
1434
- Make a new Element from the data given if it is not already a valid Element.
1312
+ ### ArrayElement.fromArray([values], [classType]) ⇒ <code>Object</code>
1313
+ Convert an array into Element instances, return the head and tail Elements.
1435
1314
 
1436
1315
  **Kind**: static method of [<code>ArrayElement</code>](#ArrayElement)
1437
1316
 
1438
1317
  | Param | Type | Default | Description |
1439
1318
  | --- | --- | --- | --- |
1440
- | element | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | | Return a valid ArrayElement instance from given data, or even an already valid one. |
1319
+ | [values] | <code>Array.&lt;IsElement&gt;</code> | <code>[]</code> | Provide an array of data that will be converted to array of elements. |
1441
1320
  | [classType] | <code>IsElement</code> | <code>ArrayElement</code> | Provide the type of IsElement to use. |
1442
1321
 
1322
+ <a name="Stackable"></a>
1323
+
1324
+ ## Stackable ⇒ [<code>Stackable</code>](#Stackable)
1325
+ Make a new Stackable from the data given if it is not already a valid Stackable.
1326
+
1327
+ **Kind**: global variable
1328
+
1329
+ | Param | Type | Default | Description |
1330
+ | --- | --- | --- | --- |
1331
+ | stackable | [<code>Stackable</code>](#Stackable) \| <code>\*</code> | | Return a valid Stackable instance from given data, or even an already valid one. |
1332
+ | [classType] | <code>IsLinker</code> | <code>Stackable</code> | Provide the type of IsLinker to use. |
1333
+
1334
+
1335
+ * [Stackable](#Stackable) ⇒ [<code>Stackable</code>](#Stackable)
1336
+ * [new Stackable([stackData])](#new_Stackable_new)
1337
+ * _instance_
1338
+ * [.task](#Stackable+task) ⇒ <code>\*</code>
1339
+ * [.run()](#Stackable+run) ⇒ <code>\*</code>
1340
+ * _static_
1341
+ * [.fromArray([values], [classType])](#Stackable.fromArray) ⇒ <code>Object</code>
1342
+
1343
+ <a name="new_Stackable_new"></a>
1344
+
1345
+ ### new Stackable([stackData])
1346
+ Create a stackable item that can be used in a stack.
1347
+
1348
+
1349
+ | Param | Type | Default | Description |
1350
+ | --- | --- | --- | --- |
1351
+ | [stackData] | <code>Object</code> | <code>{}</code> | |
1352
+ | [stackData.task] | <code>\*</code> | <code></code> | The data to be stored in this stackable |
1353
+ | [stackData.next] | [<code>Stackable</code>](#Stackable) \| <code>null</code> | <code></code> | The reference to the next stackable if any |
1354
+ | [stackData.ready] | <code>boolean</code> \| <code>function</code> | <code>false</code> | Indicate if the stackable is ready to run |
1355
+
1356
+ <a name="Stackable+task"></a>
1357
+
1358
+ ### stackable.task ⇒ <code>\*</code>
1359
+ Retrieve the data which should be formed as a task.
1360
+
1361
+ **Kind**: instance property of [<code>Stackable</code>](#Stackable)
1362
+ <a name="Stackable+run"></a>
1363
+
1364
+ ### stackable.run() ⇒ <code>\*</code>
1365
+ Run the stacked task.
1366
+
1367
+ **Kind**: instance method of [<code>Stackable</code>](#Stackable)
1368
+ <a name="Stackable.fromArray"></a>
1369
+
1370
+ ### Stackable.fromArray([values], [classType]) ⇒ <code>Object</code>
1371
+ Convert an array into Stackable instances, return the head and tail Stackables.
1372
+
1373
+ **Kind**: static method of [<code>Stackable</code>](#Stackable)
1374
+
1375
+ | Param | Type | Default | Description |
1376
+ | --- | --- | --- | --- |
1377
+ | [values] | <code>Array</code> | <code>[]</code> | Provide an array of data that will be converted to a chain of stackable linkers. |
1378
+ | [classType] | <code>IsLinker</code> | <code>Stackable</code> | Provide the type of IsLinker to use. |
1379
+
1380
+ <a name="Stack"></a>
1381
+
1382
+ ## Stack ⇒ [<code>Stack</code>](#Stack)
1383
+ Convert an array to a Stack.
1384
+
1385
+ **Kind**: global variable
1386
+
1387
+ | Param | Type | Description |
1388
+ | --- | --- | --- |
1389
+ | values | <code>Array</code> | An array of values which will be converted to stackables in this queue |
1390
+ | stackableClass | [<code>Stackable</code>](#Stackable) | The class to use for each stackable |
1391
+ | listClass | [<code>Stack</code>](#Stack) \| <code>Iterable</code> | The class to use to manage the stackables |
1392
+
1393
+
1394
+ * [Stack](#Stack) ⇒ [<code>Stack</code>](#Stack)
1395
+ * [new Stack(stackedList, listClass, stackableClass)](#new_Stack_new)
1396
+ * [.empty()](#Stack+empty) ⇒ <code>boolean</code>
1397
+ * [.top()](#Stack+top) ⇒ [<code>Stackable</code>](#Stackable)
1398
+ * [.pop()](#Stack+pop) ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
1399
+ * [.push(stackable)](#Stack+push)
1400
+ * [.remove()](#Stack+remove) ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
1401
+ * [.size()](#Stack+size) ⇒ <code>number</code>
1402
+
1403
+ <a name="new_Stack_new"></a>
1404
+
1405
+ ### new Stack(stackedList, listClass, stackableClass)
1406
+ Instantiate the state with the starter stacked list.
1407
+
1408
+
1409
+ | Param | Type |
1410
+ | --- | --- |
1411
+ | stackedList | <code>Iterable</code> \| [<code>LinkedList</code>](#LinkedList) |
1412
+ | listClass | <code>IsArrayable</code> |
1413
+ | stackableClass | [<code>Stackable</code>](#Stackable) |
1414
+
1415
+ <a name="Stack+empty"></a>
1416
+
1417
+ ### stack.empty() ⇒ <code>boolean</code>
1418
+ Return true if the stack is empty (there are no tasks in the stacked list)
1419
+
1420
+ **Kind**: instance method of [<code>Stack</code>](#Stack)
1421
+ <a name="Stack+top"></a>
1422
+
1423
+ ### stack.top() ⇒ [<code>Stackable</code>](#Stackable)
1424
+ Take a look at the next stacked task
1425
+
1426
+ **Kind**: instance method of [<code>Stack</code>](#Stack)
1427
+ <a name="Stack+pop"></a>
1428
+
1429
+ ### stack.pop() ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
1430
+ Remove the next stacked task and return it.
1431
+
1432
+ **Kind**: instance method of [<code>Stack</code>](#Stack)
1433
+ <a name="Stack+push"></a>
1434
+
1435
+ ### stack.push(stackable)
1436
+ Push a stackable task to the top of the stack.
1437
+
1438
+ **Kind**: instance method of [<code>Stack</code>](#Stack)
1439
+
1440
+ | Param | Type | Description |
1441
+ | --- | --- | --- |
1442
+ | stackable | [<code>Stackable</code>](#Stackable) \| <code>\*</code> | Add a new stackable to the top of the stack |
1443
+
1444
+ <a name="Stack+remove"></a>
1445
+
1446
+ ### stack.remove() ⇒ [<code>Stackable</code>](#Stackable) \| <code>null</code>
1447
+ Remove the next stacked task and return it.
1448
+
1449
+ **Kind**: instance method of [<code>Stack</code>](#Stack)
1450
+ <a name="Stack+size"></a>
1451
+
1452
+ ### stack.size() ⇒ <code>number</code>
1453
+ Get the size of the current stack.
1454
+
1455
+ **Kind**: instance method of [<code>Stack</code>](#Stack)
1456
+ <a name="Queueable"></a>
1457
+
1458
+ ## Queueable ⇒ [<code>Queueable</code>](#Queueable)
1459
+ Make a new Queueable from the data given if it is not already a valid Queueable.
1460
+
1461
+ **Kind**: global variable
1462
+
1463
+ | Param | Type | Default | Description |
1464
+ | --- | --- | --- | --- |
1465
+ | queueable | [<code>Queueable</code>](#Queueable) \| <code>\*</code> | | Return a valid Queueable instance from given data, or even an already valid one. |
1466
+ | [classType] | <code>IsLinker</code> | <code>Queueable</code> | Provide the type of IsLinker to use. |
1467
+
1468
+
1469
+ * [Queueable](#Queueable) ⇒ [<code>Queueable</code>](#Queueable)
1470
+ * [new Queueable([queueableData])](#new_Queueable_new)
1471
+ * _instance_
1472
+ * [.isReady](#Queueable+isReady) ⇒ <code>boolean</code>
1473
+ * [.task](#Queueable+task) ⇒ <code>\*</code>
1474
+ * [.markCompleted(completeResponse)](#Queueable+markCompleted) ⇒ <code>completeResponse</code>
1475
+ * [.run()](#Queueable+run) ⇒ <code>completeResponse</code>
1476
+ * _static_
1477
+ * [.fromArray(values, [classType])](#Queueable.fromArray) ⇒ <code>Object</code>
1478
+
1479
+ <a name="new_Queueable_new"></a>
1480
+
1481
+ ### new Queueable([queueableData])
1482
+ Create a queueable item that can be used in a queue.
1483
+
1484
+
1485
+ | Param | Type | Default | Description |
1486
+ | --- | --- | --- | --- |
1487
+ | [queueableData] | <code>Object</code> | <code>{}</code> | |
1488
+ | [queueableData.task] | <code>\*</code> | <code></code> | The data to be stored in this queueable |
1489
+ | [queueableData.next] | [<code>Queueable</code>](#Queueable) \| <code>null</code> | <code></code> | The reference to the next queueable if any |
1490
+ | [queueableData.ready] | <code>boolean</code> \| <code>function</code> | <code>false</code> | Indicate if the queueable is ready to run |
1491
+
1492
+ <a name="Queueable+isReady"></a>
1493
+
1494
+ ### queueable.isReady ⇒ <code>boolean</code>
1495
+ Check ready state.
1496
+
1497
+ **Kind**: instance property of [<code>Queueable</code>](#Queueable)
1498
+ <a name="Queueable+task"></a>
1499
+
1500
+ ### queueable.task ⇒ <code>\*</code>
1501
+ Retrieve the data which should be formed as a task.
1502
+
1503
+ **Kind**: instance property of [<code>Queueable</code>](#Queueable)
1504
+ <a name="Queueable+markCompleted"></a>
1505
+
1506
+ ### queueable.markCompleted(completeResponse) ⇒ <code>completeResponse</code>
1507
+ Set this queueable as completed.
1508
+
1509
+ **Kind**: instance method of [<code>Queueable</code>](#Queueable)
1510
+
1511
+ | Param | Type | Default | Description |
1512
+ | --- | --- | --- | --- |
1513
+ | completeResponse | <code>Object</code> | | |
1514
+ | [completeResponse.success] | <code>\*</code> | <code>true</code> | Indicate when the task failed (use false) or give a success message |
1515
+ | [completeResponse.error] | <code>\*</code> | <code>false</code> | Indicate a task was error-free (use false) or give an error message |
1516
+ | [completeResponse.context] | <code>\*</code> | <code></code> | Provide additional data in the response |
1517
+
1518
+ <a name="Queueable+run"></a>
1519
+
1520
+ ### queueable.run() ⇒ <code>completeResponse</code>
1521
+ Intend to run the queued task when it is ready. If ready, mark this task as running and run the task.
1522
+
1523
+ **Kind**: instance method of [<code>Queueable</code>](#Queueable)
1524
+ <a name="Queueable.fromArray"></a>
1525
+
1526
+ ### Queueable.fromArray(values, [classType]) ⇒ <code>Object</code>
1527
+ Convert an array into Queueable instances, return the head and tail Queueables.
1528
+
1529
+ **Kind**: static method of [<code>Queueable</code>](#Queueable)
1530
+
1531
+ | Param | Type | Default | Description |
1532
+ | --- | --- | --- | --- |
1533
+ | values | <code>Array</code> | | Provide an array of data that will be converted to a chain of queueable linkers. |
1534
+ | [classType] | <code>IsLinker</code> | <code>Queueable</code> | Provide the type of IsLinker to use. |
1535
+
1536
+ <a name="Queue"></a>
1537
+
1538
+ ## Queue ⇒ [<code>Queue</code>](#Queue)
1539
+ Convert an array to a Queue.
1540
+
1541
+ **Kind**: global variable
1542
+
1543
+ | Param | Type | Description |
1544
+ | --- | --- | --- |
1545
+ | values | <code>Array</code> | An array of values which will be converted to queueables in this queue |
1546
+ | queueableClass | [<code>Queueable</code>](#Queueable) | The class to use for each queueable |
1547
+ | listClass | [<code>Queue</code>](#Queue) \| <code>Iterable</code> | The class to use to manage the queueables |
1548
+
1549
+
1550
+ * [Queue](#Queue) ⇒ [<code>Queue</code>](#Queue)
1551
+ * [new Queue(queuedList, listClass, queueableClass)](#new_Queue_new)
1552
+ * [.dequeue()](#Queue+dequeue) ⇒ <code>completeResponse</code> \| <code>\*</code>
1553
+ * [.empty()](#Queue+empty) ⇒ <code>boolean</code>
1554
+ * [.enqueue(queueable)](#Queue+enqueue)
1555
+ * [.peek()](#Queue+peek) ⇒ [<code>Queueable</code>](#Queueable)
1556
+ * [.remove()](#Queue+remove) ⇒ [<code>Queueable</code>](#Queueable) \| <code>null</code>
1557
+ * [.size()](#Queue+size) ⇒ <code>number</code>
1558
+
1559
+ <a name="new_Queue_new"></a>
1560
+
1561
+ ### new Queue(queuedList, listClass, queueableClass)
1562
+ Instantiate the queue with the given queue list.
1563
+
1564
+
1565
+ | Param | Type | Description |
1566
+ | --- | --- | --- |
1567
+ | queuedList | <code>Iterable</code> \| [<code>LinkedList</code>](#LinkedList) | Give the list of queueables to start in this queue. |
1568
+ | listClass | <code>IsArrayable</code> | |
1569
+ | queueableClass | [<code>Queueable</code>](#Queueable) | |
1570
+
1571
+ <a name="Queue+dequeue"></a>
1572
+
1573
+ ### queue.dequeue() ⇒ <code>completeResponse</code> \| <code>\*</code>
1574
+ Take a queued task from the front of the queue and run it if ready.
1575
+
1576
+ **Kind**: instance method of [<code>Queue</code>](#Queue)
1577
+ <a name="Queue+empty"></a>
1578
+
1579
+ ### queue.empty() ⇒ <code>boolean</code>
1580
+ Return true if the queue is empty (there are no tasks in the queue list)
1581
+
1582
+ **Kind**: instance method of [<code>Queue</code>](#Queue)
1583
+ <a name="Queue+enqueue"></a>
1584
+
1585
+ ### queue.enqueue(queueable)
1586
+ Add a queued task to the end of the queue
1587
+
1588
+ **Kind**: instance method of [<code>Queue</code>](#Queue)
1589
+
1590
+ | Param | Type | Description |
1591
+ | --- | --- | --- |
1592
+ | queueable | [<code>Queueable</code>](#Queueable) | Add a new queueable to the end of the queue |
1593
+
1594
+ <a name="Queue+peek"></a>
1595
+
1596
+ ### queue.peek() ⇒ [<code>Queueable</code>](#Queueable)
1597
+ Take a look at the next queued task
1598
+
1599
+ **Kind**: instance method of [<code>Queue</code>](#Queue)
1600
+ <a name="Queue+remove"></a>
1601
+
1602
+ ### queue.remove() ⇒ [<code>Queueable</code>](#Queueable) \| <code>null</code>
1603
+ Remove the next queued item and return it.
1604
+
1605
+ **Kind**: instance method of [<code>Queue</code>](#Queue)
1606
+ <a name="Queue+size"></a>
1607
+
1608
+ ### queue.size() ⇒ <code>number</code>
1609
+ Get the length of the current queue.
1610
+
1611
+ **Kind**: instance method of [<code>Queue</code>](#Queue)
1612
+ <a name="TreeLinker"></a>
1613
+
1614
+ ## TreeLinker ⇒ [<code>TreeLinker</code>](#TreeLinker)
1615
+ Make a new DoubleLinker from the data given if it is not already a valid Linker.
1616
+
1617
+ **Kind**: global variable
1618
+
1619
+ | Param | Type | Default | Description |
1620
+ | --- | --- | --- | --- |
1621
+ | linker | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | | Return a valid TreeLinker instance from given data, or even an already valid one. |
1622
+ | [classType] | <code>IsTreeNode</code> | <code>TreeLinker</code> | Provide the type of IsTreeNode to use. |
1623
+
1624
+
1625
+ * [TreeLinker](#TreeLinker) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1626
+ * [new TreeLinker([settings], listClass)](#new_TreeLinker_new)
1627
+ * _instance_
1628
+ * [.childrenFromArray(children, listClass)](#TreeLinker+childrenFromArray) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList) \| <code>null</code>
1629
+ * _static_
1630
+ * [.fromArray([values], [classType])](#TreeLinker.fromArray) ⇒ <code>Object</code>
1631
+
1632
+ <a name="new_TreeLinker_new"></a>
1633
+
1634
+ ### new TreeLinker([settings], listClass)
1635
+ Create the new TreeLinker instance, provide the data and optionally set references for next, prev, parent, or children.
1636
+
1637
+
1638
+ | Param | Type | Default | Description |
1639
+ | --- | --- | --- | --- |
1640
+ | [settings] | <code>Object</code> | <code>{}</code> | |
1641
+ | [settings.data] | <code>\*</code> | <code></code> | The data to be stored in this tree node |
1642
+ | [settings.next] | [<code>TreeLinker</code>](#TreeLinker) | <code></code> | The reference to the next linker if any |
1643
+ | [settings.prev] | [<code>TreeLinker</code>](#TreeLinker) | <code></code> | The reference to the previous linker if any |
1644
+ | [settings.children] | [<code>LinkedTreeList</code>](#LinkedTreeList) | <code></code> | The references to child linkers if any |
1645
+ | [settings.parent] | [<code>TreeLinker</code>](#TreeLinker) | <code></code> | The reference to a parent linker if any |
1646
+ | listClass | <code>IsArrayable.&lt;IsTreeNode&gt;</code> | | Give the type of list to use for storing the children |
1647
+
1648
+ <a name="TreeLinker+childrenFromArray"></a>
1649
+
1650
+ ### treeLinker.childrenFromArray(children, listClass) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList) \| <code>null</code>
1651
+ Create the children for this tree from an array.
1652
+
1653
+ **Kind**: instance method of [<code>TreeLinker</code>](#TreeLinker)
1654
+
1655
+ | Param | Type | Description |
1656
+ | --- | --- | --- |
1657
+ | children | <code>Array</code> \| <code>null</code> | Provide an array of data / linker references to be children of this tree node. |
1658
+ | listClass | <code>IsArrayable.&lt;IsTreeNode&gt;</code> | Give the type of list to use for storing the children |
1659
+
1660
+ <a name="TreeLinker.fromArray"></a>
1661
+
1662
+ ### TreeLinker.fromArray([values], [classType]) ⇒ <code>Object</code>
1663
+ Convert an array into DoubleLinker instances, return the head and tail DoubleLinkers.
1664
+
1665
+ **Kind**: static method of [<code>TreeLinker</code>](#TreeLinker)
1666
+
1667
+ | Param | Type | Default | Description |
1668
+ | --- | --- | --- | --- |
1669
+ | [values] | <code>Array</code> | <code>[]</code> | Provide an array of data that will be converted to a chain of tree-linkers. |
1670
+ | [classType] | <code>IsTreeNode</code> | <code>TreeLinker</code> | Provide the type of IsTreeNode to use. |
1671
+
1672
+ <a name="LinkedTreeList"></a>
1673
+
1674
+ ## LinkedTreeList ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1675
+ Convert an array into a LinkedTreeList instance, return the new instance.
1676
+
1677
+ **Kind**: global variable
1678
+
1679
+ | Param | Type | Default | Description |
1680
+ | --- | --- | --- | --- |
1681
+ | [values] | <code>Array</code> | <code>[]</code> | An array of values which will be converted to nodes in this tree-list |
1682
+ | [linkerClass] | [<code>TreeLinker</code>](#TreeLinker) | <code>TreeLinker</code> | The class to use for each node |
1683
+ | [classType] | [<code>IsArrayable.&lt;TreeLinker&gt;</code>](#TreeLinker) | <code>LinkedTreeList</code> | Provide the type of IsArrayable to use. |
1684
+
1685
+
1686
+ * [LinkedTreeList](#LinkedTreeList) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1687
+ * [new LinkedTreeList()](#new_LinkedTreeList_new)
1688
+ * [.list](#LinkedTreeList+list) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1689
+ * [.first](#LinkedTreeList+first) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1690
+ * [.last](#LinkedTreeList+last) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1691
+ * [.length](#LinkedTreeList+length) ⇒ <code>number</code>
1692
+ * [.parent](#LinkedTreeList+parent) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1693
+ * [.parent](#LinkedTreeList+parent)
1694
+ * [.rootParent](#LinkedTreeList+rootParent) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1695
+ * [.initialize(initialList)](#LinkedTreeList+initialize) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1696
+ * [.setChildren(item, children)](#LinkedTreeList+setChildren)
1697
+ * [.insertAfter(node, newNode)](#LinkedTreeList+insertAfter) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1698
+ * [.insertBefore(node, newNode)](#LinkedTreeList+insertBefore) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1699
+ * [.append(node, after)](#LinkedTreeList+append) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1700
+ * [.prepend(node, before)](#LinkedTreeList+prepend) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1701
+ * [.remove(node)](#LinkedTreeList+remove) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1702
+ * [.reset()](#LinkedTreeList+reset) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1703
+ * [.item(index)](#LinkedTreeList+item) ⇒ [<code>TreeLinker</code>](#TreeLinker) \| <code>null</code>
1704
+ * [.forEach(callback, thisArg)](#LinkedTreeList+forEach)
1705
+
1706
+ <a name="new_LinkedTreeList_new"></a>
1707
+
1708
+ ### new LinkedTreeList()
1709
+ Create the new LinkedTreeList instance, configure the list class.
1710
+
1711
+ <a name="LinkedTreeList+list"></a>
1712
+
1713
+ ### linkedTreeList.list ⇒ [<code>TreeLinker</code>](#TreeLinker)
1714
+ Retrieve a copy of the innerList used.
1715
+
1716
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1717
+ **Overrides**: [<code>list</code>](#DoublyLinkedList+list)
1718
+ <a name="LinkedTreeList+first"></a>
1719
+
1720
+ ### linkedTreeList.first ⇒ [<code>TreeLinker</code>](#TreeLinker)
1721
+ Retrieve the first TreeLinker in the list.
1722
+
1723
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1724
+ **Overrides**: [<code>first</code>](#DoublyLinkedList+first)
1725
+ <a name="LinkedTreeList+last"></a>
1726
+
1727
+ ### linkedTreeList.last ⇒ [<code>TreeLinker</code>](#TreeLinker)
1728
+ Retrieve the last TreeLinker in the list.
1729
+
1730
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1731
+ **Overrides**: [<code>last</code>](#DoublyLinkedList+last)
1732
+ <a name="LinkedTreeList+length"></a>
1733
+
1734
+ ### linkedTreeList.length ⇒ <code>number</code>
1735
+ Return the length of the list.
1736
+
1737
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1738
+ **Overrides**: [<code>length</code>](#DoublyLinkedList+length)
1739
+ <a name="LinkedTreeList+parent"></a>
1740
+
1741
+ ### linkedTreeList.parent ⇒ [<code>TreeLinker</code>](#TreeLinker)
1742
+ Get the parent of this tree list.
1743
+
1744
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1745
+ <a name="LinkedTreeList+parent"></a>
1746
+
1747
+ ### linkedTreeList.parent
1748
+ Set the parent of this tree list
1749
+
1750
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1751
+
1752
+ | Param | Type | Description |
1753
+ | --- | --- | --- |
1754
+ | parent | [<code>TreeLinker</code>](#TreeLinker) | The new node to use as the parent for this group of children |
1755
+
1756
+ <a name="LinkedTreeList+rootParent"></a>
1757
+
1758
+ ### linkedTreeList.rootParent ⇒ [<code>TreeLinker</code>](#TreeLinker)
1759
+ Return the root parent of the entire tree.
1760
+
1761
+ **Kind**: instance property of [<code>LinkedTreeList</code>](#LinkedTreeList)
1762
+ <a name="LinkedTreeList+initialize"></a>
1763
+
1764
+ ### linkedTreeList.initialize(initialList) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1765
+ Initialize the inner list, should only run once.
1766
+
1767
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1768
+ **Overrides**: [<code>initialize</code>](#DoublyLinkedList+initialize)
1769
+
1770
+ | Param | Type | Description |
1771
+ | --- | --- | --- |
1772
+ | initialList | [<code>TreeLinker</code>](#TreeLinker) | Give the list of tree-linkers to start in this linked-tree-list. |
1773
+
1774
+ <a name="LinkedTreeList+setChildren"></a>
1775
+
1776
+ ### linkedTreeList.setChildren(item, children)
1777
+ Set the children on a parent item.
1778
+
1779
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1780
+
1781
+ | Param | Type | Description |
1782
+ | --- | --- | --- |
1783
+ | item | [<code>TreeLinker</code>](#TreeLinker) | The TreeLinker node that will be the parent of the children |
1784
+ | children | [<code>LinkedTreeList</code>](#LinkedTreeList) | The LinkedTreeList which has the child nodes to use |
1785
+
1786
+ <a name="LinkedTreeList+insertAfter"></a>
1787
+
1788
+ ### linkedTreeList.insertAfter(node, newNode) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1789
+ Insert a new node (or data) after a node.
1790
+
1791
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1792
+ **Overrides**: [<code>insertAfter</code>](#DoublyLinkedList+insertAfter)
1793
+
1794
+ | Param | Type | Description |
1795
+ | --- | --- | --- |
1796
+ | node | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | The existing node as reference |
1797
+ | newNode | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | The new node to go after the existing node |
1798
+
1799
+ <a name="LinkedTreeList+insertBefore"></a>
1800
+
1801
+ ### linkedTreeList.insertBefore(node, newNode) ⇒ [<code>LinkedTreeList</code>](#LinkedTreeList)
1802
+ Insert a new node (or data) before a node.
1803
+
1804
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1805
+ **Overrides**: [<code>insertBefore</code>](#DoublyLinkedList+insertBefore)
1806
+
1807
+ | Param | Type | Description |
1808
+ | --- | --- | --- |
1809
+ | node | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | The existing node as reference |
1810
+ | newNode | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | The new node to go before the existing node |
1811
+
1812
+ <a name="LinkedTreeList+append"></a>
1813
+
1814
+ ### linkedTreeList.append(node, after) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1815
+ Add a node (or data) after the given (or last) node in the list.
1816
+
1817
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1818
+ **Overrides**: [<code>append</code>](#DoublyLinkedList+append)
1819
+
1820
+ | Param | Type | Description |
1821
+ | --- | --- | --- |
1822
+ | node | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | The new node to add to the end of the list |
1823
+ | after | [<code>TreeLinker</code>](#TreeLinker) | The existing last node |
1824
+
1825
+ <a name="LinkedTreeList+prepend"></a>
1826
+
1827
+ ### linkedTreeList.prepend(node, before) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1828
+ Add a node (or data) before the given (or first) node in the list.
1829
+
1830
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1831
+ **Overrides**: [<code>prepend</code>](#DoublyLinkedList+prepend)
1832
+
1833
+ | Param | Type | Description |
1834
+ | --- | --- | --- |
1835
+ | node | [<code>TreeLinker</code>](#TreeLinker) \| <code>\*</code> | The new node to add to the start of the list |
1836
+ | before | [<code>TreeLinker</code>](#TreeLinker) | The existing first node |
1837
+
1838
+ <a name="LinkedTreeList+remove"></a>
1839
+
1840
+ ### linkedTreeList.remove(node) ⇒ [<code>TreeLinker</code>](#TreeLinker)
1841
+ Remove a linker from this linked list.
1842
+
1843
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1844
+ **Overrides**: [<code>remove</code>](#DoublyLinkedList+remove)
1845
+
1846
+ | Param | Type | Description |
1847
+ | --- | --- | --- |
1848
+ | node | [<code>TreeLinker</code>](#TreeLinker) | The node we wish to remove (and it will be returned after removal) |
1849
+
1850
+ <a name="LinkedTreeList+reset"></a>
1851
+
1852
+ ### linkedTreeList.reset() ⇒ [<code>TreeLinker</code>](#TreeLinker)
1853
+ Refresh all references and return head reference.
1854
+
1855
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1856
+ **Overrides**: [<code>reset</code>](#DoublyLinkedList+reset)
1857
+ <a name="LinkedTreeList+item"></a>
1858
+
1859
+ ### linkedTreeList.item(index) ⇒ [<code>TreeLinker</code>](#TreeLinker) \| <code>null</code>
1860
+ Retrieve a TreeLinker item from this list by numeric index, otherwise return null.
1861
+
1862
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1863
+ **Overrides**: [<code>item</code>](#DoublyLinkedList+item)
1864
+
1865
+ | Param | Type | Description |
1866
+ | --- | --- | --- |
1867
+ | index | <code>number</code> | The integer number for retrieving a node by position. |
1868
+
1869
+ <a name="LinkedTreeList+forEach"></a>
1870
+
1871
+ ### linkedTreeList.forEach(callback, thisArg)
1872
+ Be able to run forEach on this LinkedTreeList to iterate over the TreeLinker Items.
1873
+
1874
+ **Kind**: instance method of [<code>LinkedTreeList</code>](#LinkedTreeList)
1875
+ **Overrides**: [<code>forEach</code>](#DoublyLinkedList+forEach)
1876
+
1877
+ | Param | Type | Description |
1878
+ | --- | --- | --- |
1879
+ | callback | <code>forEachCallback</code> | The function to call for-each tree node |
1880
+ | thisArg | [<code>LinkedTreeList</code>](#LinkedTreeList) | Optional, 'this' reference |
1881
+
1882
+ <a name="Linker"></a>
1883
+
1884
+ ## Linker ⇒ [<code>Linker</code>](#Linker)
1885
+ Make a new Linker from the data given if it is not already a valid Linker.
1886
+
1887
+ **Kind**: global variable
1888
+
1889
+ | Param | Type | Default | Description |
1890
+ | --- | --- | --- | --- |
1891
+ | linker | [<code>Linker</code>](#Linker) \| <code>\*</code> | | Return a valid Linker instance from given data, or even an already valid one. |
1892
+ | [classType] | <code>IsLinker</code> | <code>Linker</code> | Provide the type of IsLinker to use. |
1893
+
1894
+
1895
+ * [Linker](#Linker) ⇒ [<code>Linker</code>](#Linker)
1896
+ * [new Linker([nodeData])](#new_Linker_new)
1897
+ * [.fromArray([values], [classType])](#Linker.fromArray) ⇒ <code>Object</code>
1898
+
1899
+ <a name="new_Linker_new"></a>
1900
+
1901
+ ### new Linker([nodeData])
1902
+ Create the new Linker instance, provide the data and optionally give the next Linker.
1903
+
1904
+
1905
+ | Param | Type | Default | Description |
1906
+ | --- | --- | --- | --- |
1907
+ | [nodeData] | <code>Object</code> | <code>{}</code> | |
1908
+ | [nodeData.data] | <code>\*</code> | <code></code> | The data to be stored in this linker |
1909
+ | [nodeData.next] | [<code>Linker</code>](#Linker) \| <code>null</code> | <code></code> | The reference to the next linker if any |
1910
+
1911
+ <a name="Linker.fromArray"></a>
1912
+
1913
+ ### Linker.fromArray([values], [classType]) ⇒ <code>Object</code>
1914
+ Convert an array into Linker instances, return the head and tail Linkers.
1915
+
1916
+ **Kind**: static method of [<code>Linker</code>](#Linker)
1917
+
1918
+ | Param | Type | Default | Description |
1919
+ | --- | --- | --- | --- |
1920
+ | [values] | <code>Array</code> | <code>[]</code> | Provide an array of data that will be converted to a chain of linkers. |
1921
+ | [classType] | <code>IsLinker</code> | <code>Linker</code> | Provide the type of IsLinker to use. |
1922
+
1923
+ <a name="LinkedList"></a>
1924
+
1925
+ ## LinkedList ⇒ [<code>LinkedList</code>](#LinkedList)
1926
+ Convert an array to a LinkedList.
1927
+
1928
+ **Kind**: global variable
1929
+
1930
+ | Param | Type | Default | Description |
1931
+ | --- | --- | --- | --- |
1932
+ | values | <code>Array</code> | | An array of values which will be converted to linkers in this linked-list |
1933
+ | linkerClass | <code>IsLinker</code> | | The class to use for each linker |
1934
+ | [classType] | [<code>IsArrayable.&lt;Linker&gt;</code>](#Linker) | <code>LinkedList</code> | Provide the type of IsArrayable to use. |
1935
+
1936
+
1937
+ * [LinkedList](#LinkedList) ⇒ [<code>LinkedList</code>](#LinkedList)
1938
+ * [new LinkedList()](#new_LinkedList_new)
1939
+ * [.list](#LinkedList+list) ⇒ [<code>Linker</code>](#Linker)
1940
+ * [.first](#LinkedList+first) ⇒ [<code>Linker</code>](#Linker)
1941
+ * [.last](#LinkedList+last) ⇒ [<code>Linker</code>](#Linker)
1942
+ * [.length](#LinkedList+length) ⇒ <code>number</code>
1943
+ * [.initialize(initialList)](#LinkedList+initialize) ⇒ [<code>LinkedList</code>](#LinkedList)
1944
+ * [.insertAfter(node, newNode)](#LinkedList+insertAfter) ⇒ [<code>LinkedList</code>](#LinkedList)
1945
+ * [.insertBefore(node, newNode)](#LinkedList+insertBefore) ⇒ [<code>LinkedList</code>](#LinkedList)
1946
+ * [.append(node, after)](#LinkedList+append) ⇒ [<code>Linker</code>](#Linker)
1947
+ * [.prepend(node, before)](#LinkedList+prepend) ⇒ [<code>Linker</code>](#Linker)
1948
+ * [.remove(node)](#LinkedList+remove) ⇒ [<code>Linker</code>](#Linker)
1949
+ * [.item(index)](#LinkedList+item) ⇒ [<code>Linker</code>](#Linker) \| <code>null</code>
1950
+ * [.forEach(callback, thisArg)](#LinkedList+forEach) ⇒ [<code>LinkedList</code>](#LinkedList)
1951
+
1952
+ <a name="new_LinkedList_new"></a>
1953
+
1954
+ ### new LinkedList()
1955
+ Create the new LinkedList instance.
1956
+
1957
+ <a name="LinkedList+list"></a>
1958
+
1959
+ ### linkedList.list ⇒ [<code>Linker</code>](#Linker)
1960
+ Retrieve a copy of the innerList used.
1961
+
1962
+ **Kind**: instance property of [<code>LinkedList</code>](#LinkedList)
1963
+ **Overrides**: [<code>list</code>](#Arrayable+list)
1964
+ <a name="LinkedList+first"></a>
1965
+
1966
+ ### linkedList.first ⇒ [<code>Linker</code>](#Linker)
1967
+ Retrieve the first Linker in the list.
1968
+
1969
+ **Kind**: instance property of [<code>LinkedList</code>](#LinkedList)
1970
+ **Overrides**: [<code>first</code>](#Arrayable+first)
1971
+ <a name="LinkedList+last"></a>
1972
+
1973
+ ### linkedList.last ⇒ [<code>Linker</code>](#Linker)
1974
+ Retrieve the last Linker in the list.
1975
+
1976
+ **Kind**: instance property of [<code>LinkedList</code>](#LinkedList)
1977
+ **Overrides**: [<code>last</code>](#Arrayable+last)
1978
+ <a name="LinkedList+length"></a>
1979
+
1980
+ ### linkedList.length ⇒ <code>number</code>
1981
+ Return the length of the list.
1982
+
1983
+ **Kind**: instance property of [<code>LinkedList</code>](#LinkedList)
1984
+ **Overrides**: [<code>length</code>](#Arrayable+length)
1985
+ <a name="LinkedList+initialize"></a>
1986
+
1987
+ ### linkedList.initialize(initialList) ⇒ [<code>LinkedList</code>](#LinkedList)
1988
+ Initialize the inner list, should only run once.
1989
+
1990
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
1991
+ **Overrides**: [<code>initialize</code>](#Arrayable+initialize)
1992
+
1993
+ | Param | Type | Description |
1994
+ | --- | --- | --- |
1995
+ | initialList | [<code>Linker</code>](#Linker) \| <code>Array</code> | Give the list of linkers to start in this linked-list. |
1996
+
1997
+ <a name="LinkedList+insertAfter"></a>
1998
+
1999
+ ### linkedList.insertAfter(node, newNode) ⇒ [<code>LinkedList</code>](#LinkedList)
2000
+ Insert a new node (or data) after a node.
2001
+
2002
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2003
+ **Overrides**: [<code>insertAfter</code>](#Arrayable+insertAfter)
2004
+
2005
+ | Param | Type | Description |
2006
+ | --- | --- | --- |
2007
+ | node | [<code>Linker</code>](#Linker) \| <code>\*</code> | The existing node as reference |
2008
+ | newNode | [<code>Linker</code>](#Linker) \| <code>\*</code> | The new node to go after the existing node |
2009
+
2010
+ <a name="LinkedList+insertBefore"></a>
2011
+
2012
+ ### linkedList.insertBefore(node, newNode) ⇒ [<code>LinkedList</code>](#LinkedList)
2013
+ Insert a new node (or data) before a node.
2014
+
2015
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2016
+ **Overrides**: [<code>insertBefore</code>](#Arrayable+insertBefore)
2017
+
2018
+ | Param | Type | Description |
2019
+ | --- | --- | --- |
2020
+ | node | [<code>Linker</code>](#Linker) \| <code>\*</code> | The existing node as reference |
2021
+ | newNode | [<code>Linker</code>](#Linker) \| <code>\*</code> | The new node to go before the existing node |
2022
+
2023
+ <a name="LinkedList+append"></a>
2024
+
2025
+ ### linkedList.append(node, after) ⇒ [<code>Linker</code>](#Linker)
2026
+ Add a node (or data) after the given (or last) node in the list.
2027
+
2028
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2029
+ **Overrides**: [<code>append</code>](#Arrayable+append)
2030
+
2031
+ | Param | Type | Description |
2032
+ | --- | --- | --- |
2033
+ | node | [<code>Linker</code>](#Linker) \| <code>\*</code> | The new node to add to the end of the list |
2034
+ | after | [<code>Linker</code>](#Linker) | The existing last node |
2035
+
2036
+ <a name="LinkedList+prepend"></a>
2037
+
2038
+ ### linkedList.prepend(node, before) ⇒ [<code>Linker</code>](#Linker)
2039
+ Add a node (or data) before the given (or first) node in the list.
2040
+
2041
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2042
+ **Overrides**: [<code>prepend</code>](#Arrayable+prepend)
2043
+
2044
+ | Param | Type | Description |
2045
+ | --- | --- | --- |
2046
+ | node | [<code>Linker</code>](#Linker) \| <code>\*</code> | The new node to add to the start of the list |
2047
+ | before | [<code>Linker</code>](#Linker) | The existing first node |
2048
+
2049
+ <a name="LinkedList+remove"></a>
2050
+
2051
+ ### linkedList.remove(node) ⇒ [<code>Linker</code>](#Linker)
2052
+ Remove a linker from this linked list.
2053
+
2054
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2055
+ **Overrides**: [<code>remove</code>](#Arrayable+remove)
2056
+
2057
+ | Param | Type | Description |
2058
+ | --- | --- | --- |
2059
+ | node | [<code>Linker</code>](#Linker) | The node we wish to remove (and it will be returned after removal) |
2060
+
2061
+ <a name="LinkedList+item"></a>
2062
+
2063
+ ### linkedList.item(index) ⇒ [<code>Linker</code>](#Linker) \| <code>null</code>
2064
+ Retrieve a Linker item from this list by numeric index, otherwise return null.
2065
+
2066
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2067
+ **Overrides**: [<code>item</code>](#Arrayable+item)
2068
+
2069
+ | Param | Type | Description |
2070
+ | --- | --- | --- |
2071
+ | index | <code>number</code> | The integer number for retrieving a node by position. |
2072
+
2073
+ <a name="LinkedList+forEach"></a>
2074
+
2075
+ ### linkedList.forEach(callback, thisArg) ⇒ [<code>LinkedList</code>](#LinkedList)
2076
+ Be able to run forEach on this LinkedList to iterate over the linkers.
2077
+
2078
+ **Kind**: instance method of [<code>LinkedList</code>](#LinkedList)
2079
+ **Overrides**: [<code>forEach</code>](#Arrayable+forEach)
2080
+
2081
+ | Param | Type | Description |
2082
+ | --- | --- | --- |
2083
+ | callback | <code>forEachCallback</code> | The function to call for-each linker |
2084
+ | thisArg | [<code>LinkedList</code>](#LinkedList) | Optional, 'this' reference |
2085
+
2086
+ <a name="DoublyLinkedList"></a>
2087
+
2088
+ ## DoublyLinkedList ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2089
+ Convert an array into a DoublyLinkedList instance, return the new instance.
2090
+
2091
+ **Kind**: global variable
2092
+
2093
+ | Param | Type | Default | Description |
2094
+ | --- | --- | --- | --- |
2095
+ | [values] | <code>Array</code> | <code>[]</code> | An array of values which will be converted to linkers in this doubly-linked-list |
2096
+ | [linkerClass] | <code>IsDoubleLinker</code> | <code>DoubleLinker</code> | The class to use for each linker |
2097
+ | [classType] | <code>IsArrayable.&lt;IsDoubleLinker&gt;</code> | <code>LinkedList</code> | Provide the type of IsArrayable to use. |
2098
+
2099
+
2100
+ * [DoublyLinkedList](#DoublyLinkedList) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2101
+ * [new DoublyLinkedList()](#new_DoublyLinkedList_new)
2102
+ * [.list](#DoublyLinkedList+list) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2103
+ * [.first](#DoublyLinkedList+first) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2104
+ * [.last](#DoublyLinkedList+last) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2105
+ * [.length](#DoublyLinkedList+length) ⇒ <code>number</code>
2106
+ * [.initialize(initialList)](#DoublyLinkedList+initialize) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2107
+ * [.insertAfter(node, newNode)](#DoublyLinkedList+insertAfter) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2108
+ * [.insertBefore(node, newNode)](#DoublyLinkedList+insertBefore) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2109
+ * [.append(node, after)](#DoublyLinkedList+append) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2110
+ * [.prepend(node, before)](#DoublyLinkedList+prepend) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2111
+ * [.remove(node)](#DoublyLinkedList+remove) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2112
+ * [.reset()](#DoublyLinkedList+reset) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2113
+ * [.item(index)](#DoublyLinkedList+item) ⇒ [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code>
2114
+ * [.forEach(callback, thisArg)](#DoublyLinkedList+forEach)
2115
+
2116
+ <a name="new_DoublyLinkedList_new"></a>
2117
+
2118
+ ### new DoublyLinkedList()
2119
+ Create the new DoublyLinkedList instance.
2120
+
2121
+ <a name="DoublyLinkedList+list"></a>
2122
+
2123
+ ### doublyLinkedList.list ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2124
+ Retrieve a copy of the innerList used.
2125
+
2126
+ **Kind**: instance property of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2127
+ **Overrides**: [<code>list</code>](#LinkedList+list)
2128
+ <a name="DoublyLinkedList+first"></a>
2129
+
2130
+ ### doublyLinkedList.first ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2131
+ Retrieve the first DoubleLinker in the list.
2132
+
2133
+ **Kind**: instance property of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2134
+ **Overrides**: [<code>first</code>](#LinkedList+first)
2135
+ <a name="DoublyLinkedList+last"></a>
2136
+
2137
+ ### doublyLinkedList.last ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2138
+ Retrieve the last DoubleLinker in the list.
2139
+
2140
+ **Kind**: instance property of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2141
+ **Overrides**: [<code>last</code>](#LinkedList+last)
2142
+ <a name="DoublyLinkedList+length"></a>
2143
+
2144
+ ### doublyLinkedList.length ⇒ <code>number</code>
2145
+ Return the length of the list.
2146
+
2147
+ **Kind**: instance property of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2148
+ **Overrides**: [<code>length</code>](#LinkedList+length)
2149
+ <a name="DoublyLinkedList+initialize"></a>
2150
+
2151
+ ### doublyLinkedList.initialize(initialList) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2152
+ Initialize the inner list, should only run once.
2153
+
2154
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2155
+ **Overrides**: [<code>initialize</code>](#LinkedList+initialize)
2156
+
2157
+ | Param | Type | Description |
2158
+ | --- | --- | --- |
2159
+ | initialList | [<code>DoubleLinker</code>](#DoubleLinker) | Give the list of double-linkers to start in this doubly linked-list. |
2160
+
2161
+ <a name="DoublyLinkedList+insertAfter"></a>
2162
+
2163
+ ### doublyLinkedList.insertAfter(node, newNode) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2164
+ Insert a new node (or data) after a node.
2165
+
2166
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2167
+ **Overrides**: [<code>insertAfter</code>](#LinkedList+insertAfter)
2168
+
2169
+ | Param | Type | Description |
2170
+ | --- | --- | --- |
2171
+ | node | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | The existing node as reference |
2172
+ | newNode | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | The new node to go after the existing node |
2173
+
2174
+ <a name="DoublyLinkedList+insertBefore"></a>
2175
+
2176
+ ### doublyLinkedList.insertBefore(node, newNode) ⇒ [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2177
+ Insert a new node (or data) before a node.
2178
+
2179
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2180
+ **Overrides**: [<code>insertBefore</code>](#LinkedList+insertBefore)
2181
+
2182
+ | Param | Type | Description |
2183
+ | --- | --- | --- |
2184
+ | node | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | The existing node as reference |
2185
+ | newNode | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | The new node to go before the existing node |
2186
+
2187
+ <a name="DoublyLinkedList+append"></a>
2188
+
2189
+ ### doublyLinkedList.append(node, after) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2190
+ Add a node (or data) after the given (or last) node in the list.
2191
+
2192
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2193
+ **Overrides**: [<code>append</code>](#LinkedList+append)
2194
+
2195
+ | Param | Type | Description |
2196
+ | --- | --- | --- |
2197
+ | node | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | The new node to add to the end of the list |
2198
+ | after | [<code>DoubleLinker</code>](#DoubleLinker) | The existing last node |
2199
+
2200
+ <a name="DoublyLinkedList+prepend"></a>
2201
+
2202
+ ### doublyLinkedList.prepend(node, before) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2203
+ Add a node (or data) before the given (or first) node in the list.
2204
+
2205
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2206
+ **Overrides**: [<code>prepend</code>](#LinkedList+prepend)
2207
+
2208
+ | Param | Type | Description |
2209
+ | --- | --- | --- |
2210
+ | node | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | The new node to add to the start of the list |
2211
+ | before | [<code>DoubleLinker</code>](#DoubleLinker) | The existing first node |
2212
+
2213
+ <a name="DoublyLinkedList+remove"></a>
2214
+
2215
+ ### doublyLinkedList.remove(node) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2216
+ Remove a linker from this linked list.
2217
+
2218
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2219
+ **Overrides**: [<code>remove</code>](#LinkedList+remove)
2220
+
2221
+ | Param | Type | Description |
2222
+ | --- | --- | --- |
2223
+ | node | [<code>DoubleLinker</code>](#DoubleLinker) | The node we wish to remove (and it will be returned after removal) |
2224
+
2225
+ <a name="DoublyLinkedList+reset"></a>
2226
+
2227
+ ### doublyLinkedList.reset() ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2228
+ Refresh all references and return head reference.
2229
+
2230
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2231
+ <a name="DoublyLinkedList+item"></a>
2232
+
2233
+ ### doublyLinkedList.item(index) ⇒ [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code>
2234
+ Retrieve a DoubleLinker item from this list by numeric index, otherwise return null.
2235
+
2236
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2237
+ **Overrides**: [<code>item</code>](#LinkedList+item)
2238
+
2239
+ | Param | Type | Description |
2240
+ | --- | --- | --- |
2241
+ | index | <code>number</code> | The integer number for retrieving a node by position. |
2242
+
2243
+ <a name="DoublyLinkedList+forEach"></a>
2244
+
2245
+ ### doublyLinkedList.forEach(callback, thisArg)
2246
+ Be able to run forEach on this DoublyLinkedList to iterate over the DoubleLinker Items.
2247
+
2248
+ **Kind**: instance method of [<code>DoublyLinkedList</code>](#DoublyLinkedList)
2249
+ **Overrides**: [<code>forEach</code>](#LinkedList+forEach)
2250
+
2251
+ | Param | Type | Description |
2252
+ | --- | --- | --- |
2253
+ | callback | <code>forEachCallback</code> | The function to call for-each double linker |
2254
+ | thisArg | [<code>DoublyLinkedList</code>](#DoublyLinkedList) | Optional, 'this' reference |
2255
+
2256
+ <a name="DoubleLinker"></a>
2257
+
2258
+ ## DoubleLinker ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2259
+ Make a new DoubleLinker from the data given if it is not already a valid Linker.
2260
+
2261
+ **Kind**: global variable
2262
+
2263
+ | Param | Type | Default | Description |
2264
+ | --- | --- | --- | --- |
2265
+ | linker | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>\*</code> | | Return a valid Linker instance from given data, or even an already valid one. |
2266
+ | [classType] | <code>IsDoubleLinker</code> | <code>DoubleLinker</code> | Provide the type of IsDoubleLinker to use. |
2267
+
2268
+
2269
+ * [DoubleLinker](#DoubleLinker) ⇒ [<code>DoubleLinker</code>](#DoubleLinker)
2270
+ * [new DoubleLinker([nodeData])](#new_DoubleLinker_new)
2271
+ * [.fromArray([values], [classType])](#DoubleLinker.fromArray) ⇒ <code>Object</code>
2272
+
2273
+ <a name="new_DoubleLinker_new"></a>
2274
+
2275
+ ### new DoubleLinker([nodeData])
2276
+ Create the new DoubleLinker instance, provide the data and optionally the next and prev references.
2277
+
2278
+
2279
+ | Param | Type | Default | Description |
2280
+ | --- | --- | --- | --- |
2281
+ | [nodeData] | <code>Object</code> | <code>{}</code> | |
2282
+ | [nodeData.data] | <code>\*</code> | <code></code> | The data to be stored in this linker |
2283
+ | [nodeData.next] | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code> | <code></code> | The reference to the next linker if any |
2284
+ | [nodeData.prev] | [<code>DoubleLinker</code>](#DoubleLinker) \| <code>null</code> | <code></code> | The reference to the previous linker if any |
2285
+
2286
+ <a name="DoubleLinker.fromArray"></a>
2287
+
2288
+ ### DoubleLinker.fromArray([values], [classType]) ⇒ <code>Object</code>
2289
+ Convert an array into DoubleLinker instances, return the head and tail DoubleLinkers.
2290
+
2291
+ **Kind**: static method of [<code>DoubleLinker</code>](#DoubleLinker)
2292
+
2293
+ | Param | Type | Default | Description |
2294
+ | --- | --- | --- | --- |
2295
+ | [values] | <code>Array</code> | <code>[]</code> | Provide an array of data that will be converted to a chain of linkers. |
2296
+ | [classType] | <code>IsDoubleLinker</code> | <code>DoubleLinker</code> | Provide the type of IsDoubleLinker to use. |
2297
+
2298
+ <a name="Arrayable"></a>
2299
+
2300
+ ## Arrayable ⇒ [<code>Arrayable</code>](#Arrayable)
2301
+ Convert an array to an Arrayable.
2302
+
2303
+ **Kind**: global variable
2304
+
2305
+ | Param | Type | Default | Description |
2306
+ | --- | --- | --- | --- |
2307
+ | values | <code>Array</code> | | An array of values which will be converted to elements in this arrayable |
2308
+ | [elementClass] | <code>IsElement</code> | <code>ArrayElement</code> | The class to use for each element |
2309
+ | [classType] | [<code>IsArrayable.&lt;ArrayElement&gt;</code>](#ArrayElement) | <code>Arrayable</code> | Provide the type of IsArrayable to use. |
2310
+
2311
+
2312
+ * [Arrayable](#Arrayable) ⇒ [<code>Arrayable</code>](#Arrayable)
2313
+ * [new Arrayable()](#new_Arrayable_new)
2314
+ * [.list](#Arrayable+list) ⇒ [<code>Array.&lt;ArrayElement&gt;</code>](#ArrayElement)
2315
+ * [.first](#Arrayable+first) ⇒ [<code>ArrayElement</code>](#ArrayElement)
2316
+ * [.last](#Arrayable+last) ⇒ [<code>ArrayElement</code>](#ArrayElement)
2317
+ * [.length](#Arrayable+length) ⇒ <code>number</code>
2318
+ * [.initialize(initialList)](#Arrayable+initialize) ⇒ [<code>Arrayable</code>](#Arrayable)
2319
+ * [.insertAfter(node, newNode)](#Arrayable+insertAfter) ⇒ [<code>Arrayable</code>](#Arrayable)
2320
+ * [.insertBefore(node, newNode)](#Arrayable+insertBefore) ⇒ [<code>Arrayable</code>](#Arrayable)
2321
+ * [.append(node, after)](#Arrayable+append) ⇒ [<code>Arrayable</code>](#Arrayable)
2322
+ * [.prepend(node, before)](#Arrayable+prepend) ⇒ [<code>Arrayable</code>](#Arrayable)
2323
+ * [.remove(node)](#Arrayable+remove) ⇒ [<code>ArrayElement</code>](#ArrayElement)
2324
+ * [.item(index)](#Arrayable+item) ⇒ [<code>ArrayElement</code>](#ArrayElement) \| <code>null</code>
2325
+ * [.forEach(callback, thisArg)](#Arrayable+forEach) ⇒ [<code>Arrayable</code>](#Arrayable)
2326
+
2327
+ <a name="new_Arrayable_new"></a>
2328
+
2329
+ ### new Arrayable()
2330
+ Create the new Arrayable instance, configure the Arrayable class.
2331
+
2332
+ <a name="Arrayable+list"></a>
2333
+
2334
+ ### arrayable.list ⇒ [<code>Array.&lt;ArrayElement&gt;</code>](#ArrayElement)
2335
+ Retrieve a copy of the innerList used.
2336
+
2337
+ **Kind**: instance property of [<code>Arrayable</code>](#Arrayable)
2338
+ <a name="Arrayable+first"></a>
2339
+
2340
+ ### arrayable.first ⇒ [<code>ArrayElement</code>](#ArrayElement)
2341
+ Retrieve the first Element from the Arrayable
2342
+
2343
+ **Kind**: instance property of [<code>Arrayable</code>](#Arrayable)
2344
+ <a name="Arrayable+last"></a>
2345
+
2346
+ ### arrayable.last ⇒ [<code>ArrayElement</code>](#ArrayElement)
2347
+ Retrieve the last Element from the Arrayable
2348
+
2349
+ **Kind**: instance property of [<code>Arrayable</code>](#Arrayable)
2350
+ <a name="Arrayable+length"></a>
2351
+
2352
+ ### arrayable.length ⇒ <code>number</code>
2353
+ Return the length of the list.
2354
+
2355
+ **Kind**: instance property of [<code>Arrayable</code>](#Arrayable)
2356
+ <a name="Arrayable+initialize"></a>
2357
+
2358
+ ### arrayable.initialize(initialList) ⇒ [<code>Arrayable</code>](#Arrayable)
2359
+ Initialize the inner list, should only run once.
2360
+
2361
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2362
+
2363
+ | Param | Type | Description |
2364
+ | --- | --- | --- |
2365
+ | initialList | [<code>Array.&lt;ArrayElement&gt;</code>](#ArrayElement) | Give the array of elements to start in this Arrayable. |
2366
+
2367
+ <a name="Arrayable+insertAfter"></a>
2368
+
2369
+ ### arrayable.insertAfter(node, newNode) ⇒ [<code>Arrayable</code>](#Arrayable)
2370
+ Insert a new node (or data) after a node.
2371
+
2372
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2373
+
2374
+ | Param | Type | Description |
2375
+ | --- | --- | --- |
2376
+ | node | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | The existing node as reference |
2377
+ | newNode | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | The new node to go after the existing node |
2378
+
2379
+ <a name="Arrayable+insertBefore"></a>
2380
+
2381
+ ### arrayable.insertBefore(node, newNode) ⇒ [<code>Arrayable</code>](#Arrayable)
2382
+ Insert a new node (or data) before a node.
2383
+
2384
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2385
+
2386
+ | Param | Type | Description |
2387
+ | --- | --- | --- |
2388
+ | node | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | The existing node as reference |
2389
+ | newNode | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | The new node to go before the existing node |
2390
+
2391
+ <a name="Arrayable+append"></a>
2392
+
2393
+ ### arrayable.append(node, after) ⇒ [<code>Arrayable</code>](#Arrayable)
2394
+ Add a node (or data) after the given (or last) node in the list.
2395
+
2396
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2397
+
2398
+ | Param | Type | Description |
2399
+ | --- | --- | --- |
2400
+ | node | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | The new node to add to the end of the list |
2401
+ | after | [<code>ArrayElement</code>](#ArrayElement) | The existing last node |
2402
+
2403
+ <a name="Arrayable+prepend"></a>
2404
+
2405
+ ### arrayable.prepend(node, before) ⇒ [<code>Arrayable</code>](#Arrayable)
2406
+ Add a node (or data) before the given (or first) node in the list.
2407
+
2408
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2409
+
2410
+ | Param | Type | Description |
2411
+ | --- | --- | --- |
2412
+ | node | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | The new node to add to the start of the list |
2413
+ | before | [<code>ArrayElement</code>](#ArrayElement) | The existing first node |
2414
+
2415
+ <a name="Arrayable+remove"></a>
2416
+
2417
+ ### arrayable.remove(node) ⇒ [<code>ArrayElement</code>](#ArrayElement)
2418
+ Remove an element from this arrayable.
2419
+
2420
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2421
+
2422
+ | Param | Type | Description |
2423
+ | --- | --- | --- |
2424
+ | node | [<code>ArrayElement</code>](#ArrayElement) | The node we wish to remove (and it will be returned after removal) |
2425
+
2426
+ <a name="Arrayable+item"></a>
2427
+
2428
+ ### arrayable.item(index) ⇒ [<code>ArrayElement</code>](#ArrayElement) \| <code>null</code>
2429
+ Retrieve an ArrayElement item from this list by numeric index, otherwise return null.
2430
+
2431
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2432
+
2433
+ | Param | Type | Description |
2434
+ | --- | --- | --- |
2435
+ | index | <code>number</code> | The integer number for retrieving a node by position. |
2436
+
2437
+ <a name="Arrayable+forEach"></a>
2438
+
2439
+ ### arrayable.forEach(callback, thisArg) ⇒ [<code>Arrayable</code>](#Arrayable)
2440
+ Be able to run forEach on this Arrayable to iterate over the elements.
2441
+
2442
+ **Kind**: instance method of [<code>Arrayable</code>](#Arrayable)
2443
+
2444
+ | Param | Type | Description |
2445
+ | --- | --- | --- |
2446
+ | callback | <code>forEachCallback</code> | The function to call for-each element |
2447
+ | thisArg | [<code>Arrayable</code>](#Arrayable) | Optional, 'this' reference |
2448
+
2449
+ <a name="ArrayElement"></a>
2450
+
2451
+ ## ArrayElement ⇒ [<code>ArrayElement</code>](#ArrayElement)
2452
+ Make a new Element from the data given if it is not already a valid Element.
2453
+
2454
+ **Kind**: global variable
2455
+
2456
+ | Param | Type | Default | Description |
2457
+ | --- | --- | --- | --- |
2458
+ | element | [<code>ArrayElement</code>](#ArrayElement) \| <code>\*</code> | | Return a valid ArrayElement instance from given data, or even an already valid one. |
2459
+ | [classType] | <code>IsElement</code> | <code>ArrayElement</code> | Provide the type of IsElement to use. |
2460
+
2461
+
2462
+ * [ArrayElement](#ArrayElement) ⇒ [<code>ArrayElement</code>](#ArrayElement)
2463
+ * [new ArrayElement([data])](#new_ArrayElement_new)
2464
+ * [.fromArray([values], [classType])](#ArrayElement.fromArray) ⇒ <code>Object</code>
2465
+
2466
+ <a name="new_ArrayElement_new"></a>
2467
+
2468
+ ### new ArrayElement([data])
2469
+ Create the new Element instance, provide the data and optionally configure the type of Element.
2470
+
2471
+
2472
+ | Param | Type | Default | Description |
2473
+ | --- | --- | --- | --- |
2474
+ | [data] | <code>\*</code> | <code></code> | The data to be stored in this element. |
2475
+
1443
2476
  <a name="ArrayElement.fromArray"></a>
1444
2477
 
1445
2478
  ### ArrayElement.fromArray([values], [classType]) ⇒ <code>Object</code>