import { HashMap } from "https://deno.land/x/rimbu@0.13.1/core/main/exports.ts";
Interfaces
A mutable | |
A context instance for a | |
A non-empty type-invariant immutable Map of key type K, and value type V. In the Map, each key has exactly one value, and the Map cannot contain duplicate keys.
| |
Utility interface that provides higher-kinded types for this collection. |
import { type HashMap } from "https://deno.land/x/rimbu@0.13.1/core/main/exports.ts";
A type-invariant immutable Map of key type K, and value type V. In the Map, each key has exactly one value, and the Map cannot contain duplicate keys.
- The
HashMap
uses the context'shasher
instance to hash keys for performance. - The
HashMap
uses the context'seq
function to determine equivalence between keys.
See the Map documentation and the HashMap API documentation
Examples
Example 1
Example 1
const m1 = HashMap.empty<number, string>()
const m2 = HashMap.of([1, 'a'], [2, 'b'])
import { HashMap } from "https://deno.land/x/rimbu@0.13.1/core/main/exports.ts";