Module Summary.MakeObservable

Generic implementation of OBSERVABLE_USER.

Parameters

module Obs : sig ... end

Signature

include OBSERVABLE with type value = Obs.value
type token

The type of tokens to manipulate values. This is always marshallable.

type value = Obs.value

The value being stored. May be non-marshallable (typically a closure).

val register : name:string -> ?override:bool -> value -> token

Register a new value and get the token used to enable and disable it.

val activate : token -> unit

Activate/deactive the value attached to the token.

val deactivate : token -> unit
val is_active : token -> bool

Determine if the value for the given token is active.

val all_active : unit -> (string * value) list

Get all of the active values