-
Notifications
You must be signed in to change notification settings - Fork 464
/
Copy pathBelt_HashMapInt.resi
44 lines (31 loc) · 1.12 KB
/
Belt_HashMapInt.resi
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
type key = int
type t<'b>
let make: (~hintSize: int) => t<'b>
let clear: t<'b> => unit
let isEmpty: t<_> => bool
/**
`setDone(tbl, k, v)` if `k` does not exist, add the binding `k,v`, otherwise,
update the old value with the new `v`
*/
let set: (t<'a>, key, 'a) => unit
let copy: t<'a> => t<'a>
let get: (t<'a>, key) => option<'a>
let has: (t<'b>, key) => bool
let remove: (t<'a>, key) => unit
@deprecated("Use `forEach` instead")
let forEachU: (t<'b>, (key, 'b) => unit) => unit
let forEach: (t<'b>, (key, 'b) => unit) => unit
@deprecated("Use `reduce` instead")
let reduceU: (t<'b>, 'c, ('c, key, 'b) => 'c) => 'c
let reduce: (t<'b>, 'c, ('c, key, 'b) => 'c) => 'c
@deprecated("Use `keepMapInPlace` instead")
let keepMapInPlaceU: (t<'a>, (key, 'a) => option<'a>) => unit
let keepMapInPlace: (t<'a>, (key, 'a) => option<'a>) => unit
let size: t<_> => int
let toArray: t<'a> => array<(key, 'a)>
let keysToArray: t<'a> => array<key>
let valuesToArray: t<'a> => array<'a>
let fromArray: array<(key, 'a)> => t<'a>
let mergeMany: (t<'a>, array<(key, 'a)>) => unit
let getBucketHistogram: t<_> => array<int>
let logStats: t<_> => unit