Module type Plugin.Parameter


module type Parameter = sig .. end
Generic signature of a parameter.
Consult the Plugin Development Guide for additional details.

type t 
Type of the parameter (an int, a string, etc). It is concrete for each module implementing this signature.
val parameter : Parameter.t
Since Nitrogen-20111001
val set : t -> unit
Set the option.
val add_set_hook : (t -> t -> unit) -> unit
Add a hook to be called whenafter the function Plugin.Parameter.set is called. The first parameter of the hook is the old value of the parameter while the second one is the new value.
val add_update_hook : (t -> t -> unit) -> unit
Add a hook to be called when the value of the parameter changes (by calling Plugin.Parameter.set or indirectly by the project library. The first parameter of the hook is the old value of the parameter while the second one is the new value. Note that it is **not** specified if the hook is applied just before or just after the effective change.
Since Nitrogen-20111001
val get : unit -> t
Option value (not necessarly set on the current command line).
val clear : unit -> unit
Set the option to its default value, that is the value if set was never called.
val is_default : unit -> bool
Is the option equal to its default value?
val option_name : string
Name of the option on the command-line
Since Carbon-20110201
include State_builder.S
val equal : t -> t -> bool
val add_aliases : string list -> unit
Add some aliases for this option. That is other option names which have exactly the same semantics that the initial option.
Raises Invalid_argument if one of the strings is empty
val add_alias : string list -> unit
Deprecated.since Carbon-20110201
Equivalent to add_aliases.