Module type Summary.OBSERVABLE_USER

The implementation side of observation. This should be held internally with the creator of the state. Only the OBSERVABLE signature should be exposed.

include OBSERVABLE
type token

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

type 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