OptParse

`sig module Opt : sig exception No_value exception Option_error of string * string exception Option_help type 'a t = { option_set : string -> string list -> unit; option_set_value : 'a -> unit; option_get : unit -> 'a option; option_metavars : string list; option_defhelp : string option; } val get : 'a OptParse.Opt.t -> 'a val set : 'a OptParse.Opt.t -> 'a -> unit val opt : 'a OptParse.Opt.t -> 'a option val is_set : 'a OptParse.Opt.t -> bool val value_option : string -> 'a option -> (string -> 'a) -> (exn -> string -> string) -> 'a OptParse.Opt.t val callback_option : string -> (string -> 'a) -> (exn -> string -> string) -> ('a -> unit) -> unit OptParse.Opt.t end module StdOpt : sig val store_const : ?default:'a -> 'a -> 'a OptParse.Opt.t val store_true : unit -> bool OptParse.Opt.t val store_false : unit -> bool OptParse.Opt.t val count_option : ?dest:int Pervasives.ref -> ?increment:int -> unit -> int OptParse.Opt.t val incr_option : ?dest:int Pervasives.ref -> unit -> int OptParse.Opt.t val decr_option : ?dest:int Pervasives.ref -> unit -> int OptParse.Opt.t val int_option : ?default:int -> ?metavar:string -> unit -> int OptParse.Opt.t val float_option : ?default:float -> ?metavar:string -> unit -> float OptParse.Opt.t val str_option : ?default:string -> ?metavar:string -> unit -> string OptParse.Opt.t val int_callback : ?metavar:string -> (int -> unit) -> unit OptParse.Opt.t val float_callback : ?metavar:string -> (float -> unit) -> unit OptParse.Opt.t val str_callback : ?metavar:string -> (string -> unit) -> unit OptParse.Opt.t val help_option : unit -> 'a OptParse.Opt.t val version_option : (unit -> string) -> 'a OptParse.Opt.t end module Formatter : sig type t = { indent : unit -> unit; dedent : unit -> unit; format_usage : string -> string; format_heading : string -> string; format_description : string -> string; format_option : char list * string list -> string list -> string option -> string; } val indented_formatter : ?level:int Pervasives.ref -> ?indent:int Pervasives.ref -> ?indent_increment:int -> ?max_help_position:int -> ?width:int -> ?short_first:bool -> unit -> OptParse.Formatter.t val titled_formatter : ?level:int Pervasives.ref -> ?indent:int Pervasives.ref -> ?indent_increment:int -> ?max_help_position:int -> ?width:int -> ?short_first:bool -> unit -> OptParse.Formatter.t val wrap : ?initial_indent:int -> ?subsequent_indent:int -> string -> int -> string list val fill : ?initial_indent:int -> ?subsequent_indent:int -> string -> int -> string end module OptParser : sig exception Option_conflict of string type t type group val make : ?usage:string -> ?status:int -> ?description:string -> ?version:string -> ?suppress_usage:bool -> ?suppress_help:bool -> ?prog:string -> ?formatter:OptParse.Formatter.t -> unit -> OptParse.OptParser.t val add : OptParse.OptParser.t -> ?group:OptParse.OptParser.group -> ?help:string -> ?hide:bool -> ?short_name:char -> ?short_names:char list -> ?long_name:string -> ?long_names:string list -> 'a OptParse.Opt.t -> unit val add_group : OptParse.OptParser.t -> ?parent:OptParse.OptParser.group -> ?description:string -> string -> OptParse.OptParser.group val error : OptParse.OptParser.t -> ?chn:Pervasives.out_channel -> ?status:int -> string -> 'a val usage : OptParse.OptParser.t -> ?chn:Pervasives.out_channel -> unit -> unit val parse : OptParse.OptParser.t -> ?first:int -> ?last:int -> string array -> string list val parse_argv : OptParse.OptParser.t -> string list end end`