| 1 | interface ISortedMap<K, V> { |
| 2 | clear(): void; |
| 3 | delete(key: K): boolean; |
| 4 | forEach(callbackfn: (value: V, key: K, map: Map<K, V>) => void, thisArg?: any): void; |
| 5 | get(key: K): V | undefined; |
| 6 | has(key: K): boolean; |
| 7 | set(key: K, value: V): Map<K, V>; |
| 8 | size(): number; |
| 9 | map: (callbackfn: (value: [K, V], index: number, array: [K, V][]) => any, thisArg?: any) => any[]; |
| 10 | iterator: Map<K, V> |
| 11 | } |
| 12 | |
| 13 | export function SortedMap<K, V>(comparator: (a: [K, V], b: [K, V]) => number): ISortedMap<K, V> { |
| 14 | const obj = new Map<K, V>(); |
no outgoing calls
no test coverage detected