linked-list-typed 2.0.5 → 2.1.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.
- package/README.md +14 -14
- package/dist/data-structures/base/iterable-element-base.d.ts +186 -83
- package/dist/data-structures/base/iterable-element-base.js +149 -107
- package/dist/data-structures/base/iterable-entry-base.d.ts +95 -119
- package/dist/data-structures/base/iterable-entry-base.js +59 -116
- package/dist/data-structures/base/linear-base.d.ts +250 -192
- package/dist/data-structures/base/linear-base.js +137 -274
- package/dist/data-structures/binary-tree/avl-tree-counter.d.ts +126 -158
- package/dist/data-structures/binary-tree/avl-tree-counter.js +171 -205
- package/dist/data-structures/binary-tree/avl-tree-multi-map.d.ts +100 -69
- package/dist/data-structures/binary-tree/avl-tree-multi-map.js +135 -87
- package/dist/data-structures/binary-tree/avl-tree.d.ts +138 -149
- package/dist/data-structures/binary-tree/avl-tree.js +208 -195
- package/dist/data-structures/binary-tree/binary-tree.d.ts +476 -632
- package/dist/data-structures/binary-tree/binary-tree.js +598 -869
- package/dist/data-structures/binary-tree/bst.d.ts +258 -306
- package/dist/data-structures/binary-tree/bst.js +505 -481
- package/dist/data-structures/binary-tree/red-black-tree.d.ts +107 -179
- package/dist/data-structures/binary-tree/red-black-tree.js +114 -209
- package/dist/data-structures/binary-tree/tree-counter.d.ts +132 -154
- package/dist/data-structures/binary-tree/tree-counter.js +172 -203
- package/dist/data-structures/binary-tree/tree-multi-map.d.ts +72 -69
- package/dist/data-structures/binary-tree/tree-multi-map.js +105 -85
- package/dist/data-structures/graph/abstract-graph.d.ts +238 -233
- package/dist/data-structures/graph/abstract-graph.js +267 -237
- package/dist/data-structures/graph/directed-graph.d.ts +108 -224
- package/dist/data-structures/graph/directed-graph.js +146 -233
- package/dist/data-structures/graph/map-graph.d.ts +49 -55
- package/dist/data-structures/graph/map-graph.js +56 -59
- package/dist/data-structures/graph/undirected-graph.d.ts +103 -146
- package/dist/data-structures/graph/undirected-graph.js +129 -149
- package/dist/data-structures/hash/hash-map.d.ts +164 -338
- package/dist/data-structures/hash/hash-map.js +270 -457
- package/dist/data-structures/heap/heap.d.ts +214 -289
- package/dist/data-structures/heap/heap.js +340 -349
- package/dist/data-structures/heap/max-heap.d.ts +11 -47
- package/dist/data-structures/heap/max-heap.js +11 -66
- package/dist/data-structures/heap/min-heap.d.ts +12 -47
- package/dist/data-structures/heap/min-heap.js +11 -66
- package/dist/data-structures/linked-list/doubly-linked-list.d.ts +231 -347
- package/dist/data-structures/linked-list/doubly-linked-list.js +368 -494
- package/dist/data-structures/linked-list/singly-linked-list.d.ts +261 -310
- package/dist/data-structures/linked-list/singly-linked-list.js +447 -466
- package/dist/data-structures/linked-list/skip-linked-list.d.ts +0 -107
- package/dist/data-structures/linked-list/skip-linked-list.js +0 -100
- package/dist/data-structures/priority-queue/max-priority-queue.d.ts +12 -56
- package/dist/data-structures/priority-queue/max-priority-queue.js +11 -78
- package/dist/data-structures/priority-queue/min-priority-queue.d.ts +11 -57
- package/dist/data-structures/priority-queue/min-priority-queue.js +10 -79
- package/dist/data-structures/priority-queue/priority-queue.d.ts +2 -61
- package/dist/data-structures/priority-queue/priority-queue.js +8 -83
- package/dist/data-structures/queue/deque.d.ts +227 -254
- package/dist/data-structures/queue/deque.js +309 -348
- package/dist/data-structures/queue/queue.d.ts +180 -201
- package/dist/data-structures/queue/queue.js +265 -248
- package/dist/data-structures/stack/stack.d.ts +124 -102
- package/dist/data-structures/stack/stack.js +181 -125
- package/dist/data-structures/trie/trie.d.ts +164 -165
- package/dist/data-structures/trie/trie.js +189 -172
- package/dist/interfaces/binary-tree.d.ts +56 -6
- package/dist/interfaces/graph.d.ts +16 -0
- package/dist/types/data-structures/base/base.d.ts +1 -1
- package/dist/types/data-structures/graph/abstract-graph.d.ts +4 -0
- package/dist/types/utils/utils.d.ts +1 -0
- package/dist/utils/utils.d.ts +1 -1
- package/dist/utils/utils.js +2 -1
- package/package.json +2 -2
- package/src/data-structures/base/iterable-element-base.ts +238 -115
- package/src/data-structures/base/iterable-entry-base.ts +96 -120
- package/src/data-structures/base/linear-base.ts +271 -277
- package/src/data-structures/binary-tree/avl-tree-counter.ts +198 -216
- package/src/data-structures/binary-tree/avl-tree-multi-map.ts +192 -101
- package/src/data-structures/binary-tree/avl-tree.ts +239 -206
- package/src/data-structures/binary-tree/binary-tree.ts +664 -893
- package/src/data-structures/binary-tree/bst.ts +568 -570
- package/src/data-structures/binary-tree/red-black-tree.ts +161 -222
- package/src/data-structures/binary-tree/tree-counter.ts +199 -218
- package/src/data-structures/binary-tree/tree-multi-map.ts +131 -97
- package/src/data-structures/graph/abstract-graph.ts +339 -264
- package/src/data-structures/graph/directed-graph.ts +146 -236
- package/src/data-structures/graph/map-graph.ts +63 -60
- package/src/data-structures/graph/undirected-graph.ts +129 -152
- package/src/data-structures/hash/hash-map.ts +274 -496
- package/src/data-structures/heap/heap.ts +389 -402
- package/src/data-structures/heap/max-heap.ts +12 -76
- package/src/data-structures/heap/min-heap.ts +13 -76
- package/src/data-structures/linked-list/doubly-linked-list.ts +426 -530
- package/src/data-structures/linked-list/singly-linked-list.ts +495 -517
- package/src/data-structures/linked-list/skip-linked-list.ts +1 -108
- package/src/data-structures/priority-queue/max-priority-queue.ts +12 -87
- package/src/data-structures/priority-queue/min-priority-queue.ts +11 -88
- package/src/data-structures/priority-queue/priority-queue.ts +3 -92
- package/src/data-structures/queue/deque.ts +381 -357
- package/src/data-structures/queue/queue.ts +310 -264
- package/src/data-structures/stack/stack.ts +217 -131
- package/src/data-structures/trie/trie.ts +240 -175
- package/src/interfaces/binary-tree.ts +240 -6
- package/src/interfaces/graph.ts +37 -0
- package/src/types/data-structures/base/base.ts +5 -5
- package/src/types/data-structures/graph/abstract-graph.ts +5 -0
- package/src/types/utils/utils.ts +2 -0
- package/src/utils/utils.ts +9 -14
|
@@ -1,27 +1,32 @@
|
|
|
1
|
-
import { EntryCallback, ReduceEntryCallback } from '../../types';
|
|
2
|
-
|
|
1
|
+
import type { EntryCallback, ReduceEntryCallback } from '../../types';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Iterable view over key-value entries.
|
|
5
|
+
* @template K - Key type.
|
|
6
|
+
* @template V - Value type.
|
|
7
|
+
* @remarks Time O(1), Space O(1)
|
|
8
|
+
*/
|
|
3
9
|
export abstract class IterableEntryBase<K = any, V = any> {
|
|
10
|
+
/**
|
|
11
|
+
* Total number of entries.
|
|
12
|
+
* @returns Entry count.
|
|
13
|
+
* @remarks Time O(1), Space O(1)
|
|
14
|
+
*/
|
|
4
15
|
abstract get size(): number;
|
|
5
16
|
|
|
6
17
|
/**
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* The function is an implementation of the Symbol.iterator method that returns an iterable iterator.
|
|
11
|
-
* @param {any[]} args - The `args` parameter in the code snippet represents a rest parameter. It
|
|
12
|
-
* allows the function to accept any number of arguments as an array. In this case, the `args`
|
|
13
|
-
* parameter is used to pass any additional arguments to the `_getIterator` method.
|
|
18
|
+
* Default iterator yielding `[key, value]` entries.
|
|
19
|
+
* @returns Iterator of `[K, V]`.
|
|
20
|
+
* @remarks Time O(n) to iterate, Space O(1)
|
|
14
21
|
*/
|
|
15
22
|
*[Symbol.iterator](...args: any[]): IterableIterator<[K, V]> {
|
|
16
23
|
yield* this._getIterator(...args);
|
|
17
24
|
}
|
|
18
25
|
|
|
19
26
|
/**
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* The function returns an iterator that yields key-value pairs from the object, where the value can
|
|
24
|
-
* be undefined.
|
|
27
|
+
* Iterate over `[key, value]` pairs (may yield `undefined` values).
|
|
28
|
+
* @returns Iterator of `[K, V | undefined]`.
|
|
29
|
+
* @remarks Time O(n), Space O(1)
|
|
25
30
|
*/
|
|
26
31
|
*entries(): IterableIterator<[K, V | undefined]> {
|
|
27
32
|
for (const item of this) {
|
|
@@ -30,10 +35,9 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
30
35
|
}
|
|
31
36
|
|
|
32
37
|
/**
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
* The function returns an iterator that yields the keys of a data structure.
|
|
38
|
+
* Iterate over keys only.
|
|
39
|
+
* @returns Iterator of keys.
|
|
40
|
+
* @remarks Time O(n), Space O(1)
|
|
37
41
|
*/
|
|
38
42
|
*keys(): IterableIterator<K> {
|
|
39
43
|
for (const item of this) {
|
|
@@ -42,10 +46,9 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
42
46
|
}
|
|
43
47
|
|
|
44
48
|
/**
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
* The function returns an iterator that yields the values of a collection.
|
|
49
|
+
* Iterate over values only.
|
|
50
|
+
* @returns Iterator of values.
|
|
51
|
+
* @remarks Time O(n), Space O(1)
|
|
49
52
|
*/
|
|
50
53
|
*values(): IterableIterator<V> {
|
|
51
54
|
for (const item of this) {
|
|
@@ -54,18 +57,11 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
54
57
|
}
|
|
55
58
|
|
|
56
59
|
/**
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
* @
|
|
62
|
-
* `value`, `key`, and `index`. It should return a boolean value indicating whether the condition is
|
|
63
|
-
* met for the current element in the iteration.
|
|
64
|
-
* @param {any} [thisArg] - The `thisArg` parameter is an optional argument that specifies the value
|
|
65
|
-
* to be used as `this` when executing the `predicate` function. If `thisArg` is provided, it will be
|
|
66
|
-
* passed as the first argument to the `predicate` function. If `thisArg` is not provided
|
|
67
|
-
* @returns The `every` method is returning a boolean value. It returns `true` if every element in
|
|
68
|
-
* the collection satisfies the provided predicate function, and `false` otherwise.
|
|
60
|
+
* Test whether all entries satisfy the predicate.
|
|
61
|
+
* @param predicate - `(key, value, index, self) => boolean`.
|
|
62
|
+
* @param thisArg - Optional `this` for callback.
|
|
63
|
+
* @returns `true` if all pass; otherwise `false`.
|
|
64
|
+
* @remarks Time O(n), Space O(1)
|
|
69
65
|
*/
|
|
70
66
|
every(predicate: EntryCallback<K, V, boolean>, thisArg?: any): boolean {
|
|
71
67
|
let index = 0;
|
|
@@ -78,19 +74,11 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
78
74
|
}
|
|
79
75
|
|
|
80
76
|
/**
|
|
81
|
-
*
|
|
82
|
-
*
|
|
83
|
-
*
|
|
84
|
-
*
|
|
85
|
-
*
|
|
86
|
-
* @param predicate - The `predicate` parameter is a callback function that takes three arguments:
|
|
87
|
-
* `value`, `key`, and `index`. It should return a boolean value indicating whether the condition is
|
|
88
|
-
* met for the current element in the iteration.
|
|
89
|
-
* @param {any} [thisArg] - The `thisArg` parameter is an optional argument that specifies the value
|
|
90
|
-
* to be used as the `this` value when executing the `predicate` function. If `thisArg` is provided,
|
|
91
|
-
* it will be passed as the first argument to the `predicate` function. If `thisArg` is
|
|
92
|
-
* @returns a boolean value. It returns true if the predicate function returns true for any pair in
|
|
93
|
-
* the collection, and false otherwise.
|
|
77
|
+
* Test whether any entry satisfies the predicate.
|
|
78
|
+
* @param predicate - `(key, value, index, self) => boolean`.
|
|
79
|
+
* @param thisArg - Optional `this` for callback.
|
|
80
|
+
* @returns `true` if any passes; otherwise `false`.
|
|
81
|
+
* @remarks Time O(n), Space O(1)
|
|
94
82
|
*/
|
|
95
83
|
some(predicate: EntryCallback<K, V, boolean>, thisArg?: any): boolean {
|
|
96
84
|
let index = 0;
|
|
@@ -103,17 +91,10 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
103
91
|
}
|
|
104
92
|
|
|
105
93
|
/**
|
|
106
|
-
*
|
|
107
|
-
*
|
|
108
|
-
*
|
|
109
|
-
*
|
|
110
|
-
* function for each pair.
|
|
111
|
-
* @param callbackfn - The callback function that will be called for each element in the collection.
|
|
112
|
-
* It takes four parameters: the value of the current element, the key of the current element, the
|
|
113
|
-
* index of the current element, and the collection itself.
|
|
114
|
-
* @param {any} [thisArg] - The `thisArg` parameter is an optional argument that allows you to
|
|
115
|
-
* specify the value of `this` within the callback function. If `thisArg` is provided, it will be
|
|
116
|
-
* used as the `this` value when calling the callback function. If `thisArg` is not provided, `
|
|
94
|
+
* Visit each entry, left-to-right.
|
|
95
|
+
* @param callbackfn - `(key, value, index, self) => void`.
|
|
96
|
+
* @param thisArg - Optional `this` for callback.
|
|
97
|
+
* @remarks Time O(n), Space O(1)
|
|
117
98
|
*/
|
|
118
99
|
forEach(callbackfn: EntryCallback<K, V, void>, thisArg?: any): void {
|
|
119
100
|
let index = 0;
|
|
@@ -124,21 +105,11 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
124
105
|
}
|
|
125
106
|
|
|
126
107
|
/**
|
|
127
|
-
*
|
|
128
|
-
*
|
|
129
|
-
*
|
|
130
|
-
*
|
|
131
|
-
*
|
|
132
|
-
* @param callbackfn - The callback function that will be called for each entry in the collection. It
|
|
133
|
-
* takes three arguments: the value of the entry, the key of the entry, and the index of the entry in
|
|
134
|
-
* the collection. It should return a boolean value indicating whether the current entry matches the
|
|
135
|
-
* desired condition.
|
|
136
|
-
* @param {any} [thisArg] - The `thisArg` parameter is an optional argument that specifies the value
|
|
137
|
-
* to be used as `this` when executing the `callbackfn` function. If `thisArg` is provided, it will
|
|
138
|
-
* be passed as the `this` value to the `callbackfn` function. If `thisArg
|
|
139
|
-
* @returns The method `find` returns the value of the first element in the iterable that satisfies
|
|
140
|
-
* the provided callback function. If no element satisfies the callback function, `undefined` is
|
|
141
|
-
* returned.
|
|
108
|
+
* Find the first entry that matches a predicate.
|
|
109
|
+
* @param callbackfn - `(key, value, index, self) => boolean`.
|
|
110
|
+
* @param thisArg - Optional `this` for callback.
|
|
111
|
+
* @returns Matching `[key, value]` or `undefined`.
|
|
112
|
+
* @remarks Time O(n), Space O(1)
|
|
142
113
|
*/
|
|
143
114
|
find(callbackfn: EntryCallback<K, V, boolean>, thisArg?: any): [K, V] | undefined {
|
|
144
115
|
let index = 0;
|
|
@@ -150,14 +121,10 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
150
121
|
}
|
|
151
122
|
|
|
152
123
|
/**
|
|
153
|
-
*
|
|
154
|
-
*
|
|
155
|
-
*
|
|
156
|
-
*
|
|
157
|
-
* @param {K} key - The parameter "key" is of type K, which means it can be any type. It represents
|
|
158
|
-
* the key that we want to check for existence in the data structure.
|
|
159
|
-
* @returns a boolean value. It returns true if the key is found in the collection, and false
|
|
160
|
-
* otherwise.
|
|
124
|
+
* Whether the given key exists.
|
|
125
|
+
* @param key - Key to test.
|
|
126
|
+
* @returns `true` if found; otherwise `false`.
|
|
127
|
+
* @remarks Time O(n) generic, Space O(1)
|
|
161
128
|
*/
|
|
162
129
|
has(key: K): boolean {
|
|
163
130
|
for (const item of this) {
|
|
@@ -168,13 +135,10 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
168
135
|
}
|
|
169
136
|
|
|
170
137
|
/**
|
|
171
|
-
*
|
|
172
|
-
*
|
|
173
|
-
*
|
|
174
|
-
*
|
|
175
|
-
* @param {V} value - The parameter "value" is the value that we want to check if it exists in the
|
|
176
|
-
* collection.
|
|
177
|
-
* @returns a boolean value, either true or false.
|
|
138
|
+
* Whether there exists an entry with the given value.
|
|
139
|
+
* @param value - Value to test.
|
|
140
|
+
* @returns `true` if found; otherwise `false`.
|
|
141
|
+
* @remarks Time O(n), Space O(1)
|
|
178
142
|
*/
|
|
179
143
|
hasValue(value: V): boolean {
|
|
180
144
|
for (const [, elementValue] of this) {
|
|
@@ -184,14 +148,10 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
184
148
|
}
|
|
185
149
|
|
|
186
150
|
/**
|
|
187
|
-
*
|
|
188
|
-
*
|
|
189
|
-
*
|
|
190
|
-
*
|
|
191
|
-
* @param {K} key - K (the type of the key) - This parameter represents the key that is being
|
|
192
|
-
* searched for in the collection.
|
|
193
|
-
* @returns The `get` method returns the value associated with the specified key if it exists in the
|
|
194
|
-
* collection, otherwise it returns `undefined`.
|
|
151
|
+
* Get the value under a key.
|
|
152
|
+
* @param key - Key to look up.
|
|
153
|
+
* @returns Value or `undefined`.
|
|
154
|
+
* @remarks Time O(n) generic, Space O(1)
|
|
195
155
|
*/
|
|
196
156
|
get(key: K): V | undefined {
|
|
197
157
|
for (const item of this) {
|
|
@@ -202,20 +162,11 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
202
162
|
}
|
|
203
163
|
|
|
204
164
|
/**
|
|
205
|
-
*
|
|
206
|
-
*
|
|
207
|
-
*
|
|
208
|
-
*
|
|
209
|
-
*
|
|
210
|
-
* @param callbackfn - The callback function that will be called for each element in the collection.
|
|
211
|
-
* It takes four arguments: the current accumulator value, the current value of the element, the key
|
|
212
|
-
* of the element, and the index of the element in the collection. It should return the updated
|
|
213
|
-
* accumulator value.
|
|
214
|
-
* @param {U} initialValue - The `initialValue` parameter is the initial value of the accumulator. It
|
|
215
|
-
* is the value that will be used as the first argument to the `callbackfn` function when reducing
|
|
216
|
-
* the elements of the collection.
|
|
217
|
-
* @returns The `reduce` method is returning the final value of the accumulator after iterating over
|
|
218
|
-
* all the elements in the collection.
|
|
165
|
+
* Reduce entries into a single accumulator.
|
|
166
|
+
* @param callbackfn - `(acc, value, key, index, self) => acc`.
|
|
167
|
+
* @param initialValue - Initial accumulator.
|
|
168
|
+
* @returns Final accumulator.
|
|
169
|
+
* @remarks Time O(n), Space O(1)
|
|
219
170
|
*/
|
|
220
171
|
reduce<U>(callbackfn: ReduceEntryCallback<K, V, U>, initialValue: U): U {
|
|
221
172
|
let accumulator = initialValue;
|
|
@@ -228,34 +179,59 @@ export abstract class IterableEntryBase<K = any, V = any> {
|
|
|
228
179
|
}
|
|
229
180
|
|
|
230
181
|
/**
|
|
231
|
-
*
|
|
232
|
-
*
|
|
233
|
-
*
|
|
234
|
-
* The print function logs the elements of an array to the console.
|
|
182
|
+
* Visualize the iterable as an array of `[key, value]` pairs (or a custom string).
|
|
183
|
+
* @returns Array of entries (default) or a string.
|
|
184
|
+
* @remarks Time O(n), Space O(n)
|
|
235
185
|
*/
|
|
236
186
|
toVisual(): [K, V][] | string {
|
|
237
187
|
return [...this];
|
|
238
188
|
}
|
|
239
189
|
|
|
240
190
|
/**
|
|
241
|
-
*
|
|
242
|
-
*
|
|
243
|
-
*
|
|
244
|
-
* The print function logs the elements of an array to the console.
|
|
191
|
+
* Print a human-friendly representation to the console.
|
|
192
|
+
* @remarks Time O(n), Space O(n)
|
|
245
193
|
*/
|
|
246
194
|
print(): void {
|
|
247
195
|
console.log(this.toVisual());
|
|
248
196
|
}
|
|
249
197
|
|
|
198
|
+
/**
|
|
199
|
+
* Whether there are no entries.
|
|
200
|
+
* @returns `true` if empty; `false` otherwise.
|
|
201
|
+
* @remarks Time O(1) typical, Space O(1)
|
|
202
|
+
*/
|
|
250
203
|
abstract isEmpty(): boolean;
|
|
251
204
|
|
|
205
|
+
/**
|
|
206
|
+
* Remove all entries.
|
|
207
|
+
* @remarks Time O(n) typical, Space O(1)
|
|
208
|
+
*/
|
|
252
209
|
abstract clear(): void;
|
|
253
210
|
|
|
254
|
-
|
|
211
|
+
/**
|
|
212
|
+
* Deep clone preserving the concrete subtype.
|
|
213
|
+
* @returns A new instance of the same concrete class (`this` type).
|
|
214
|
+
* @remarks Time O(n) typical, Space O(n)
|
|
215
|
+
*/
|
|
216
|
+
abstract clone(): this;
|
|
255
217
|
|
|
218
|
+
/**
|
|
219
|
+
* Map entries using an implementation-specific strategy.
|
|
220
|
+
* @remarks Time O(n), Space O(n)
|
|
221
|
+
*/
|
|
256
222
|
abstract map(...args: any[]): any;
|
|
257
223
|
|
|
258
|
-
|
|
224
|
+
/**
|
|
225
|
+
* Filter entries and return the same-species structure.
|
|
226
|
+
* @returns A new instance of the same concrete class (`this` type).
|
|
227
|
+
* @remarks Time O(n), Space O(n)
|
|
228
|
+
*/
|
|
229
|
+
abstract filter(...args: any[]): this;
|
|
259
230
|
|
|
231
|
+
/**
|
|
232
|
+
* Underlying iterator for the default iteration protocol.
|
|
233
|
+
* @returns Iterator of `[K, V]`.
|
|
234
|
+
* @remarks Time O(n), Space O(1)
|
|
235
|
+
*/
|
|
260
236
|
protected abstract _getIterator(...args: any[]): IterableIterator<[K, V]>;
|
|
261
237
|
}
|