data-structure-typed 2.5.2 → 2.6.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 (162) hide show
  1. package/.husky/pre-commit +3 -0
  2. package/CHANGELOG.md +3 -1
  3. package/MIGRATION.md +217 -0
  4. package/README.md +80 -8
  5. package/README_CN.md +569 -143
  6. package/SPECIFICATION.md +44 -14
  7. package/SPECIFICATION.zh-CN.md +44 -14
  8. package/dist/cjs/binary-tree.cjs +5841 -1678
  9. package/dist/cjs/graph.cjs +422 -14
  10. package/dist/cjs/hash.cjs +95 -7
  11. package/dist/cjs/heap.cjs +174 -16
  12. package/dist/cjs/index.cjs +7751 -2449
  13. package/dist/cjs/linked-list.cjs +443 -2
  14. package/dist/cjs/matrix.cjs +56 -0
  15. package/dist/cjs/priority-queue.cjs +172 -14
  16. package/dist/cjs/queue.cjs +435 -0
  17. package/dist/cjs/stack.cjs +103 -4
  18. package/dist/cjs/trie.cjs +106 -0
  19. package/dist/cjs-legacy/binary-tree.cjs +5933 -1772
  20. package/dist/cjs-legacy/graph.cjs +422 -14
  21. package/dist/cjs-legacy/hash.cjs +95 -7
  22. package/dist/cjs-legacy/heap.cjs +174 -16
  23. package/dist/cjs-legacy/index.cjs +8154 -2854
  24. package/dist/cjs-legacy/linked-list.cjs +443 -2
  25. package/dist/cjs-legacy/matrix.cjs +56 -0
  26. package/dist/cjs-legacy/priority-queue.cjs +172 -14
  27. package/dist/cjs-legacy/queue.cjs +435 -0
  28. package/dist/cjs-legacy/stack.cjs +103 -4
  29. package/dist/cjs-legacy/trie.cjs +106 -0
  30. package/dist/esm/binary-tree.mjs +5841 -1678
  31. package/dist/esm/graph.mjs +422 -14
  32. package/dist/esm/hash.mjs +95 -7
  33. package/dist/esm/heap.mjs +174 -16
  34. package/dist/esm/index.mjs +7751 -2449
  35. package/dist/esm/linked-list.mjs +443 -2
  36. package/dist/esm/matrix.mjs +56 -0
  37. package/dist/esm/priority-queue.mjs +172 -14
  38. package/dist/esm/queue.mjs +435 -0
  39. package/dist/esm/stack.mjs +103 -4
  40. package/dist/esm/trie.mjs +106 -0
  41. package/dist/esm-legacy/binary-tree.mjs +5933 -1772
  42. package/dist/esm-legacy/graph.mjs +422 -14
  43. package/dist/esm-legacy/hash.mjs +95 -7
  44. package/dist/esm-legacy/heap.mjs +174 -16
  45. package/dist/esm-legacy/index.mjs +8154 -2854
  46. package/dist/esm-legacy/linked-list.mjs +443 -2
  47. package/dist/esm-legacy/matrix.mjs +56 -0
  48. package/dist/esm-legacy/priority-queue.mjs +172 -14
  49. package/dist/esm-legacy/queue.mjs +435 -0
  50. package/dist/esm-legacy/stack.mjs +103 -4
  51. package/dist/esm-legacy/trie.mjs +106 -0
  52. package/dist/types/data-structures/base/iterable-element-base.d.ts +17 -0
  53. package/dist/types/data-structures/base/linear-base.d.ts +6 -0
  54. package/dist/types/data-structures/binary-tree/avl-tree.d.ts +86 -2
  55. package/dist/types/data-structures/binary-tree/binary-indexed-tree.d.ts +98 -0
  56. package/dist/types/data-structures/binary-tree/binary-tree.d.ts +191 -15
  57. package/dist/types/data-structures/binary-tree/bst.d.ts +171 -3
  58. package/dist/types/data-structures/binary-tree/red-black-tree.d.ts +136 -8
  59. package/dist/types/data-structures/binary-tree/segment-tree.d.ts +42 -0
  60. package/dist/types/data-structures/binary-tree/tree-map.d.ts +1061 -167
  61. package/dist/types/data-structures/binary-tree/tree-multi-map.d.ts +1232 -355
  62. package/dist/types/data-structures/binary-tree/tree-multi-set.d.ts +916 -194
  63. package/dist/types/data-structures/binary-tree/tree-set.d.ts +1078 -141
  64. package/dist/types/data-structures/graph/directed-graph.d.ts +70 -0
  65. package/dist/types/data-structures/graph/undirected-graph.d.ts +63 -0
  66. package/dist/types/data-structures/hash/hash-map.d.ts +84 -6
  67. package/dist/types/data-structures/heap/heap.d.ts +140 -12
  68. package/dist/types/data-structures/linked-list/doubly-linked-list.d.ts +150 -2
  69. package/dist/types/data-structures/linked-list/singly-linked-list.d.ts +106 -1
  70. package/dist/types/data-structures/linked-list/skip-linked-list.d.ts +126 -0
  71. package/dist/types/data-structures/matrix/matrix.d.ts +56 -0
  72. package/dist/types/data-structures/queue/deque.d.ts +171 -0
  73. package/dist/types/data-structures/queue/queue.d.ts +97 -0
  74. package/dist/types/data-structures/stack/stack.d.ts +72 -2
  75. package/dist/types/data-structures/trie/trie.d.ts +84 -0
  76. package/dist/types/interfaces/binary-tree.d.ts +2 -3
  77. package/dist/umd/data-structure-typed.js +7784 -2484
  78. package/dist/umd/data-structure-typed.min.js +4 -4
  79. package/docs-site-docusaurus/docs/api/classes/AVLTree.md +188 -200
  80. package/docs-site-docusaurus/docs/api/classes/AVLTreeNode.md +11 -11
  81. package/docs-site-docusaurus/docs/api/classes/AbstractGraph.md +62 -62
  82. package/docs-site-docusaurus/docs/api/classes/BST.md +183 -195
  83. package/docs-site-docusaurus/docs/api/classes/BSTNode.md +13 -13
  84. package/docs-site-docusaurus/docs/api/classes/BinaryIndexedTree.md +15 -15
  85. package/docs-site-docusaurus/docs/api/classes/BinaryTree.md +143 -155
  86. package/docs-site-docusaurus/docs/api/classes/BinaryTreeNode.md +13 -13
  87. package/docs-site-docusaurus/docs/api/classes/Deque.md +99 -85
  88. package/docs-site-docusaurus/docs/api/classes/DirectedGraph.md +73 -73
  89. package/docs-site-docusaurus/docs/api/classes/DoublyLinkedList.md +100 -70
  90. package/docs-site-docusaurus/docs/api/classes/DoublyLinkedListNode.md +8 -8
  91. package/docs-site-docusaurus/docs/api/classes/FibonacciHeap.md +12 -12
  92. package/docs-site-docusaurus/docs/api/classes/FibonacciHeapNode.md +1 -1
  93. package/docs-site-docusaurus/docs/api/classes/HashMap.md +38 -38
  94. package/docs-site-docusaurus/docs/api/classes/Heap.md +96 -85
  95. package/docs-site-docusaurus/docs/api/classes/IterableElementBase.md +25 -25
  96. package/docs-site-docusaurus/docs/api/classes/IterableEntryBase.md +23 -23
  97. package/docs-site-docusaurus/docs/api/classes/LinearBase.md +48 -48
  98. package/docs-site-docusaurus/docs/api/classes/LinearLinkedBase.md +52 -52
  99. package/docs-site-docusaurus/docs/api/classes/LinkedHashMap.md +46 -42
  100. package/docs-site-docusaurus/docs/api/classes/LinkedListNode.md +6 -6
  101. package/docs-site-docusaurus/docs/api/classes/LinkedListQueue.md +74 -74
  102. package/docs-site-docusaurus/docs/api/classes/MapGraph.md +73 -73
  103. package/docs-site-docusaurus/docs/api/classes/Matrix.md +31 -31
  104. package/docs-site-docusaurus/docs/api/classes/MaxHeap.md +104 -89
  105. package/docs-site-docusaurus/docs/api/classes/MaxPriorityQueue.md +104 -89
  106. package/docs-site-docusaurus/docs/api/classes/MinHeap.md +104 -89
  107. package/docs-site-docusaurus/docs/api/classes/MinPriorityQueue.md +104 -89
  108. package/docs-site-docusaurus/docs/api/classes/Navigator.md +5 -5
  109. package/docs-site-docusaurus/docs/api/classes/PriorityQueue.md +103 -88
  110. package/docs-site-docusaurus/docs/api/classes/Queue.md +111 -59
  111. package/docs-site-docusaurus/docs/api/classes/RedBlackTree.md +200 -212
  112. package/docs-site-docusaurus/docs/api/classes/SegmentTree.md +10 -10
  113. package/docs-site-docusaurus/docs/api/classes/SinglyLinkedList.md +75 -75
  114. package/docs-site-docusaurus/docs/api/classes/SinglyLinkedListNode.md +6 -6
  115. package/docs-site-docusaurus/docs/api/classes/SkipList.md +37 -37
  116. package/docs-site-docusaurus/docs/api/classes/Stack.md +42 -42
  117. package/docs-site-docusaurus/docs/api/classes/TreeMap.md +107 -36
  118. package/docs-site-docusaurus/docs/api/classes/TreeMultiMap.md +43 -43
  119. package/docs-site-docusaurus/docs/api/classes/TreeSet.md +106 -35
  120. package/docs-site-docusaurus/docs/api/classes/Trie.md +43 -43
  121. package/docs-site-docusaurus/docs/api/classes/TrieNode.md +8 -8
  122. package/docs-site-docusaurus/docs/api/classes/UndirectedGraph.md +72 -72
  123. package/docs-site-docusaurus/docs/guide/architecture.md +75 -7
  124. package/docs-site-docusaurus/docs/guide/concepts.md +53 -34
  125. package/docs-site-docusaurus/docs/guide/faq.md +53 -0
  126. package/docs-site-docusaurus/docs/guide/guides.md +8 -9
  127. package/docs-site-docusaurus/docs/guide/integrations.md +74 -177
  128. package/docs-site-docusaurus/docs/guide/overview.md +131 -17
  129. package/docs-site-docusaurus/src/pages/index.tsx +4 -0
  130. package/docs-site-docusaurus/typedoc.json +1 -0
  131. package/jest.integration.config.js +1 -2
  132. package/package.json +10 -7
  133. package/src/data-structures/base/iterable-element-base.ts +32 -0
  134. package/src/data-structures/base/linear-base.ts +11 -0
  135. package/src/data-structures/binary-tree/avl-tree.ts +88 -5
  136. package/src/data-structures/binary-tree/binary-indexed-tree.ts +98 -0
  137. package/src/data-structures/binary-tree/binary-tree.ts +242 -81
  138. package/src/data-structures/binary-tree/bst.ts +173 -7
  139. package/src/data-structures/binary-tree/red-black-tree.ts +139 -15
  140. package/src/data-structures/binary-tree/segment-tree.ts +42 -0
  141. package/src/data-structures/binary-tree/tree-map.ts +948 -36
  142. package/src/data-structures/binary-tree/tree-multi-map.ts +893 -13
  143. package/src/data-structures/binary-tree/tree-multi-set.ts +761 -33
  144. package/src/data-structures/binary-tree/tree-set.ts +1260 -251
  145. package/src/data-structures/graph/directed-graph.ts +71 -1
  146. package/src/data-structures/graph/undirected-graph.ts +64 -1
  147. package/src/data-structures/hash/hash-map.ts +100 -12
  148. package/src/data-structures/heap/heap.ts +149 -19
  149. package/src/data-structures/linked-list/doubly-linked-list.ts +178 -2
  150. package/src/data-structures/linked-list/singly-linked-list.ts +106 -1
  151. package/src/data-structures/linked-list/skip-linked-list.ts +126 -0
  152. package/src/data-structures/matrix/matrix.ts +56 -0
  153. package/src/data-structures/queue/deque.ts +187 -0
  154. package/src/data-structures/queue/queue.ts +109 -0
  155. package/src/data-structures/stack/stack.ts +75 -5
  156. package/src/data-structures/trie/trie.ts +84 -0
  157. package/src/interfaces/binary-tree.ts +1 -9
  158. package/.vitepress/cache/deps_temp_51f5f1b0/chunk-7OIKW5WK.js +0 -12984
  159. package/.vitepress/cache/deps_temp_51f5f1b0/package.json +0 -3
  160. package/.vitepress/cache/deps_temp_51f5f1b0/vitepress___@vue_devtools-api.js +0 -4505
  161. package/.vitepress/cache/deps_temp_51f5f1b0/vitepress___@vueuse_core.js +0 -9731
  162. package/.vitepress/cache/deps_temp_51f5f1b0/vue.js +0 -347
@@ -250,6 +250,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
250
250
 
251
251
 
252
252
 
253
+
254
+
255
+
256
+
257
+
258
+
259
+
260
+
261
+
262
+
263
+
264
+
265
+
266
+
267
+
268
+
269
+
270
+
271
+
272
+
273
+
274
+
275
+
276
+
277
+
278
+
279
+
280
+
281
+
282
+
283
+
284
+
285
+
286
+
287
+
253
288
 
254
289
 
255
290
 
@@ -419,6 +454,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
419
454
 
420
455
 
421
456
 
457
+
458
+
459
+
460
+
461
+
462
+
463
+
464
+
465
+
466
+
467
+
468
+
469
+
470
+
471
+
472
+
473
+
474
+
475
+
476
+
477
+
478
+
479
+
480
+
481
+
482
+
483
+
484
+
485
+
486
+
487
+
488
+
489
+
490
+
491
+
422
492
 
423
493
 
424
494
 
@@ -472,6 +542,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
472
542
 
473
543
 
474
544
 
545
+
546
+
547
+
548
+
549
+
550
+
551
+
475
552
 
476
553
 
477
554
 
@@ -513,6 +590,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
513
590
 
514
591
 
515
592
 
593
+
594
+
595
+
596
+
597
+
598
+
599
+
516
600
 
517
601
 
518
602
 
@@ -713,6 +797,48 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
713
797
 
714
798
 
715
799
 
800
+
801
+
802
+
803
+
804
+
805
+
806
+
807
+
808
+
809
+
810
+
811
+
812
+
813
+
814
+
815
+
816
+
817
+
818
+
819
+
820
+
821
+
822
+
823
+
824
+
825
+
826
+
827
+
828
+
829
+
830
+
831
+
832
+
833
+
834
+
835
+
836
+
837
+
838
+
839
+
840
+
841
+
716
842
 
717
843
 
718
844
 
@@ -924,6 +1050,48 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
924
1050
 
925
1051
 
926
1052
 
1053
+
1054
+
1055
+
1056
+
1057
+
1058
+
1059
+
1060
+
1061
+
1062
+
1063
+
1064
+
1065
+
1066
+
1067
+
1068
+
1069
+
1070
+
1071
+
1072
+
1073
+
1074
+
1075
+
1076
+
1077
+
1078
+
1079
+
1080
+
1081
+
1082
+
1083
+
1084
+
1085
+
1086
+
1087
+
1088
+
1089
+
1090
+
1091
+
1092
+
1093
+
1094
+
927
1095
 
928
1096
 
929
1097
 
@@ -1091,6 +1259,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1091
1259
 
1092
1260
 
1093
1261
 
1262
+
1263
+
1264
+
1265
+
1266
+
1267
+
1268
+
1269
+
1270
+
1271
+
1272
+
1273
+
1274
+
1275
+
1276
+
1277
+
1278
+
1279
+
1280
+
1281
+
1282
+
1283
+
1284
+
1285
+
1286
+
1287
+
1288
+
1289
+
1290
+
1291
+
1292
+
1293
+
1294
+
1295
+
1296
+
1094
1297
 
1095
1298
 
1096
1299
 
@@ -1306,6 +1509,48 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1306
1509
 
1307
1510
 
1308
1511
 
1512
+
1513
+
1514
+
1515
+
1516
+
1517
+
1518
+
1519
+
1520
+
1521
+
1522
+
1523
+
1524
+
1525
+
1526
+
1527
+
1528
+
1529
+
1530
+
1531
+
1532
+
1533
+
1534
+
1535
+
1536
+
1537
+
1538
+
1539
+
1540
+
1541
+
1542
+
1543
+
1544
+
1545
+
1546
+
1547
+
1548
+
1549
+
1550
+
1551
+
1552
+
1553
+
1309
1554
 
1310
1555
 
1311
1556
 
@@ -1558,18 +1803,60 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1558
1803
 
1559
1804
 
1560
1805
 
1561
- * @example
1562
- * // Remove key
1563
- * const mm = new TreeMultiMap<number, string>();
1564
- * mm.add(1, 'a');
1565
- * mm.add(2, 'b');
1566
- * mm.delete(1);
1567
- * console.log(mm.has(1)); // false;
1568
- */
1569
- delete(key: K): boolean {
1570
- this._validateKey(key);
1571
- return this.#core.delete(key).length > 0;
1572
- }
1806
+
1807
+
1808
+
1809
+
1810
+
1811
+
1812
+
1813
+
1814
+
1815
+
1816
+
1817
+
1818
+
1819
+
1820
+
1821
+
1822
+
1823
+
1824
+
1825
+
1826
+
1827
+
1828
+
1829
+
1830
+
1831
+
1832
+
1833
+
1834
+
1835
+
1836
+
1837
+
1838
+
1839
+
1840
+
1841
+
1842
+
1843
+
1844
+
1845
+
1846
+
1847
+
1848
+ * @example
1849
+ * // Remove key
1850
+ * const mm = new TreeMultiMap<number, string>();
1851
+ * mm.add(1, 'a');
1852
+ * mm.add(2, 'b');
1853
+ * mm.delete(1);
1854
+ * console.log(mm.has(1)); // false;
1855
+ */
1856
+ delete(key: K): boolean {
1857
+ this._validateKey(key);
1858
+ return this.#core.delete(key);
1859
+ }
1573
1860
 
1574
1861
  /**
1575
1862
  * Check if a specific value exists in a key's bucket.
@@ -1592,6 +1879,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1592
1879
 
1593
1880
 
1594
1881
 
1882
+
1883
+
1884
+
1885
+
1886
+
1887
+
1888
+
1595
1889
 
1596
1890
 
1597
1891
 
@@ -1634,6 +1928,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1634
1928
 
1635
1929
 
1636
1930
 
1931
+
1932
+
1933
+
1934
+
1935
+
1936
+
1937
+
1637
1938
 
1638
1939
 
1639
1940
 
@@ -1681,6 +1982,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1681
1982
 
1682
1983
 
1683
1984
 
1985
+
1986
+
1987
+
1988
+
1989
+
1990
+
1991
+
1684
1992
 
1685
1993
 
1686
1994
 
@@ -1865,6 +2173,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
1865
2173
 
1866
2174
 
1867
2175
 
2176
+
2177
+
2178
+
2179
+
2180
+
2181
+
2182
+
2183
+
2184
+
2185
+
2186
+
2187
+
2188
+
2189
+
2190
+
2191
+
2192
+
2193
+
2194
+
2195
+
2196
+
2197
+
2198
+
2199
+
2200
+
2201
+
2202
+
2203
+
2204
+
2205
+
2206
+
2207
+
2208
+
2209
+
2210
+
1868
2211
 
1869
2212
 
1870
2213
 
@@ -2037,6 +2380,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2037
2380
 
2038
2381
 
2039
2382
 
2383
+
2384
+
2385
+
2386
+
2387
+
2388
+
2389
+
2390
+
2391
+
2392
+
2393
+
2394
+
2395
+
2396
+
2397
+
2398
+
2399
+
2400
+
2401
+
2402
+
2403
+
2404
+
2405
+
2406
+
2407
+
2408
+
2409
+
2410
+
2411
+
2412
+
2413
+
2414
+
2415
+
2416
+
2417
+
2040
2418
 
2041
2419
 
2042
2420
 
@@ -2069,6 +2447,32 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2069
2447
  for (const [, bucket] of this) yield bucket;
2070
2448
  }
2071
2449
 
2450
+ /**
2451
+ * Iterate over all `[key, values[]]` entries (Map-compatible).
2452
+ * @remarks Time O(n), Space O(1) per step.
2453
+
2454
+
2455
+
2456
+
2457
+
2458
+
2459
+
2460
+
2461
+ * @example
2462
+ * // Iterate over entries
2463
+ * const mm = new TreeMultiMap<number, string>();
2464
+ * mm.set(1, 'a');
2465
+ * mm.set(1, 'b');
2466
+ * mm.set(2, 'c');
2467
+ * console.log([...mm.entries()]); // [
2468
+ * // [1, ['a', 'b']],
2469
+ * // [2, ['c']]
2470
+ * // ];
2471
+ */
2472
+ *entries(): IterableIterator<[K, V[]]> {
2473
+ yield* this;
2474
+ }
2475
+
2072
2476
  // ---- entry-flat views ----
2073
2477
 
2074
2478
  /**
@@ -2092,6 +2496,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2092
2496
 
2093
2497
 
2094
2498
 
2499
+
2500
+
2501
+
2502
+
2503
+
2504
+
2505
+
2095
2506
 
2096
2507
 
2097
2508
 
@@ -2134,6 +2545,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2134
2545
 
2135
2546
 
2136
2547
 
2548
+
2549
+
2550
+
2551
+
2552
+
2553
+
2554
+
2137
2555
 
2138
2556
 
2139
2557
 
@@ -2176,6 +2594,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2176
2594
 
2177
2595
 
2178
2596
 
2597
+
2598
+
2599
+
2600
+
2601
+
2602
+
2603
+
2179
2604
 
2180
2605
 
2181
2606
 
@@ -2250,6 +2675,20 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2250
2675
 
2251
2676
 
2252
2677
 
2678
+
2679
+
2680
+
2681
+
2682
+
2683
+
2684
+
2685
+
2686
+
2687
+
2688
+
2689
+
2690
+
2691
+
2253
2692
 
2254
2693
 
2255
2694
 
@@ -2329,6 +2768,20 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2329
2768
 
2330
2769
 
2331
2770
 
2771
+
2772
+
2773
+
2774
+
2775
+
2776
+
2777
+
2778
+
2779
+
2780
+
2781
+
2782
+
2783
+
2784
+
2332
2785
 
2333
2786
 
2334
2787
 
@@ -2380,6 +2833,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2380
2833
 
2381
2834
 
2382
2835
 
2836
+
2837
+
2838
+
2839
+
2840
+
2841
+
2842
+
2383
2843
 
2384
2844
 
2385
2845
 
@@ -2426,6 +2886,13 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2426
2886
 
2427
2887
 
2428
2888
 
2889
+
2890
+
2891
+
2892
+
2893
+
2894
+
2895
+
2429
2896
 
2430
2897
 
2431
2898
 
@@ -2592,6 +3059,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2592
3059
 
2593
3060
 
2594
3061
 
3062
+
3063
+
3064
+
3065
+
3066
+
3067
+
3068
+
3069
+
3070
+
3071
+
3072
+
3073
+
3074
+
3075
+
3076
+
3077
+
3078
+
3079
+
3080
+
3081
+
3082
+
3083
+
3084
+
3085
+
3086
+
3087
+
3088
+
3089
+
3090
+
3091
+
3092
+
3093
+
3094
+
3095
+
3096
+
2595
3097
 
2596
3098
 
2597
3099
 
@@ -2772,6 +3274,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2772
3274
 
2773
3275
 
2774
3276
 
3277
+
3278
+
3279
+
3280
+
3281
+
3282
+
3283
+
3284
+
3285
+
3286
+
3287
+
3288
+
3289
+
3290
+
3291
+
3292
+
3293
+
3294
+
3295
+
3296
+
3297
+
3298
+
3299
+
3300
+
3301
+
3302
+
3303
+
3304
+
3305
+
3306
+
3307
+
3308
+
3309
+
3310
+
3311
+
2775
3312
 
2776
3313
 
2777
3314
 
@@ -2917,6 +3454,34 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
2917
3454
 
2918
3455
 
2919
3456
 
3457
+
3458
+
3459
+
3460
+
3461
+
3462
+
3463
+
3464
+
3465
+
3466
+
3467
+
3468
+
3469
+
3470
+
3471
+
3472
+
3473
+
3474
+
3475
+
3476
+
3477
+
3478
+
3479
+
3480
+
3481
+
3482
+
3483
+
3484
+
2920
3485
 
2921
3486
 
2922
3487
 
@@ -3061,6 +3626,34 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
3061
3626
 
3062
3627
 
3063
3628
 
3629
+
3630
+
3631
+
3632
+
3633
+
3634
+
3635
+
3636
+
3637
+
3638
+
3639
+
3640
+
3641
+
3642
+
3643
+
3644
+
3645
+
3646
+
3647
+
3648
+
3649
+
3650
+
3651
+
3652
+
3653
+
3654
+
3655
+
3656
+
3064
3657
 
3065
3658
 
3066
3659
 
@@ -3239,6 +3832,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
3239
3832
 
3240
3833
 
3241
3834
 
3835
+
3836
+
3837
+
3838
+
3839
+
3840
+
3841
+
3842
+
3843
+
3844
+
3845
+
3846
+
3847
+
3848
+
3849
+
3850
+
3851
+
3852
+
3853
+
3854
+
3855
+
3856
+
3857
+
3858
+
3859
+
3860
+
3861
+
3862
+
3863
+
3864
+
3865
+
3866
+
3867
+
3868
+
3869
+
3242
3870
 
3243
3871
 
3244
3872
 
@@ -3410,6 +4038,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
3410
4038
 
3411
4039
 
3412
4040
 
4041
+
4042
+
4043
+
4044
+
4045
+
4046
+
4047
+
4048
+
4049
+
4050
+
4051
+
4052
+
4053
+
4054
+
4055
+
4056
+
4057
+
4058
+
4059
+
4060
+
4061
+
4062
+
4063
+
4064
+
4065
+
4066
+
4067
+
4068
+
4069
+
4070
+
4071
+
4072
+
4073
+
4074
+
4075
+
3413
4076
 
3414
4077
 
3415
4078
 
@@ -3586,6 +4249,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
3586
4249
 
3587
4250
 
3588
4251
 
4252
+
4253
+
4254
+
4255
+
4256
+
4257
+
4258
+
4259
+
4260
+
4261
+
4262
+
4263
+
4264
+
4265
+
4266
+
4267
+
4268
+
4269
+
4270
+
4271
+
4272
+
4273
+
4274
+
4275
+
4276
+
4277
+
4278
+
4279
+
4280
+
4281
+
4282
+
4283
+
4284
+
4285
+
4286
+
3589
4287
 
3590
4288
 
3591
4289
 
@@ -3764,6 +4462,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
3764
4462
 
3765
4463
 
3766
4464
 
4465
+
4466
+
4467
+
4468
+
4469
+
4470
+
4471
+
4472
+
4473
+
4474
+
4475
+
4476
+
4477
+
4478
+
4479
+
4480
+
4481
+
4482
+
4483
+
4484
+
4485
+
4486
+
4487
+
4488
+
4489
+
4490
+
4491
+
4492
+
4493
+
4494
+
4495
+
4496
+
4497
+
4498
+
4499
+
3767
4500
 
3768
4501
 
3769
4502
 
@@ -3942,6 +4675,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
3942
4675
 
3943
4676
 
3944
4677
 
4678
+
4679
+
4680
+
4681
+
4682
+
4683
+
4684
+
4685
+
4686
+
4687
+
4688
+
4689
+
4690
+
4691
+
4692
+
4693
+
4694
+
4695
+
4696
+
4697
+
4698
+
4699
+
4700
+
4701
+
4702
+
4703
+
4704
+
4705
+
4706
+
4707
+
4708
+
4709
+
4710
+
4711
+
4712
+
3945
4713
 
3946
4714
 
3947
4715
 
@@ -4111,6 +4879,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
4111
4879
 
4112
4880
 
4113
4881
 
4882
+
4883
+
4884
+
4885
+
4886
+
4887
+
4888
+
4889
+
4890
+
4891
+
4892
+
4893
+
4894
+
4895
+
4896
+
4897
+
4898
+
4899
+
4900
+
4901
+
4902
+
4903
+
4904
+
4905
+
4906
+
4907
+
4908
+
4909
+
4910
+
4911
+
4912
+
4913
+
4914
+
4915
+
4916
+
4114
4917
 
4115
4918
 
4116
4919
 
@@ -4255,6 +5058,34 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
4255
5058
 
4256
5059
 
4257
5060
 
5061
+
5062
+
5063
+
5064
+
5065
+
5066
+
5067
+
5068
+
5069
+
5070
+
5071
+
5072
+
5073
+
5074
+
5075
+
5076
+
5077
+
5078
+
5079
+
5080
+
5081
+
5082
+
5083
+
5084
+
5085
+
5086
+
5087
+
5088
+
4258
5089
 
4259
5090
 
4260
5091
 
@@ -4486,8 +5317,22 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
4486
5317
  /**
4487
5318
  * Get elements by rank range
4488
5319
 
5320
+
5321
+
5322
+
5323
+
5324
+
5325
+
5326
+
5327
+
5328
+
5329
+
5330
+
5331
+
5332
+
5333
+
4489
5334
  * @example
4490
- * // Pagination with rangeByRank
5335
+ * // Pagination by position in tree order
4491
5336
  * const tree = new TreeMultiMap<number>(
4492
5337
  * [10, 20, 30, 40, 50, 60, 70, 80, 90],
4493
5338
  * { enableOrderStatistic: true }
@@ -4514,6 +5359,41 @@ export class TreeMultiMap<K = any, V = any, R = any> implements Iterable<[K, V[]
4514
5359
 
4515
5360
 
4516
5361
 
5362
+
5363
+
5364
+
5365
+
5366
+
5367
+
5368
+
5369
+
5370
+
5371
+
5372
+
5373
+
5374
+
5375
+
5376
+
5377
+
5378
+
5379
+
5380
+
5381
+
5382
+
5383
+
5384
+
5385
+
5386
+
5387
+
5388
+
5389
+
5390
+
5391
+
5392
+
5393
+
5394
+
5395
+
5396
+
4517
5397
  * @example
4518
5398
  * // Deep clone
4519
5399
  * const mm = new TreeMultiMap<number, string>();