1 (* !!take care!!: this class does side effect, not a pure oassoc.
3 * Also can not put structure with ref or mutable field because when
4 * you will modify those refs or fields, you will modify it in the memory,
5 * not in the disk. The only way to modify on the disk is to call
6 * #add or #replace with what you modified. Oassocbdb has no way
7 * to know that you modified it.
9 class ['b
] oassoc_btree_string
:
11 string (* db name, for profiling *) ->
12 (unit -> Bdb.dbtxn
option) (* transaction handler *) ->
14 inherit [string,'b
] Oassoc.oassoc
16 (* ocollection concrete instantiation of virtual methods *)
18 method add
: string * 'b
-> 'o
20 method iter
: (string * 'b
-> unit) -> unit
21 method view
: (string * 'b
, 'o
) Ocollection.view
23 method del
: string * 'b
-> 'o
24 method mem
: string * 'b
-> bool
27 (* oassoc concrete instantiation of virtual methods *)
28 method assoc
: string -> 'b
29 method delkey
: string -> 'o
31 method keys
: string list
39 (unit -> Bdb.dbtxn
option) ->
41 Bdb.db
* (string, 'a
) Oassoc_buffer.oassoc_buffer