module Ref:
VERBOSITY
via a global ref
.
Example:
let verbosity = ref 0 module M = Kwapp.Messages (Kwapp.Argv0) (Kwapp.Ref (struct let r = v end))
Now you can change the verbosity by incrementing the ref whenever you like:
incr verbosity;
or by calling M.set
with a new value.
Parameters: |
|
val get : unit -> int
val set : int -> unit