package alt-ergo-lib

  1. Overview
  2. Docs

Output channels manager.

type t = private
  1. | Stdout
  2. | Stderr
  3. | Channel of Stdlib.out_channel * Stdlib.Format.formatter
  4. | Fmt of Stdlib.Format.formatter
  5. | Invalid
val of_formatter : Stdlib.Format.formatter -> t

of_formatter fmt create an out channel of the formatter fmt.

val to_formatter : t -> Stdlib.Format.formatter

to_formatter fmt return the underlying formatter.

val create_channel : string -> t

create_filename filename create an out channel to the file filename. If the argument is "stdout", respectively "stderr", the channel is the standard output, respectively the standard error. If the file does not exist, the procedure creates it. An existant file is truncated to zero length.

val close_all : unit -> unit

Flushing and closing all the remaining output channels.

val set_regular : t -> unit

Set the regular output channel used by default to output results, models and unsat cores.

Default to Format.std_formatter.

val set_diagnostic : t -> unit

Set the diagnostic output channel used by default to output errors, debug and warning informations.

Default to Format.err_formatter.

val get_fmt_std : unit -> Stdlib.Format.formatter

Value specifying the formatter used to output results.

Default to Format.std_formatter.

val get_fmt_err : unit -> Stdlib.Format.formatter

Value specifying the formatter used to output errors.

Default to Format.err_formatter.

val get_fmt_wrn : unit -> Stdlib.Format.formatter

Value specifying the formatter used to output warnings.

Default to Format.err_formatter.

val get_fmt_dbg : unit -> Stdlib.Format.formatter

Value specifying the formatter used to output debug informations.

Default to Format.err_formatter.

val get_fmt_usc : unit -> Stdlib.Format.formatter

Value specifying the formatter used to output unsat cores.

Default to Format.std_formatter.

val set_std : t -> unit

Set fmt_std accessible with get_fmt_std

val set_err : t -> unit

Set fmt_err accessible with get_fmt_err

val set_wrn : t -> unit

Set fmt_wrn accessible with get_fmt_wrn

val set_dbg : t -> unit

Set fmt_dbg accessible with get_fmt_dbg

val set_usc : t -> unit

Set fmt_usc accessible with get_fmt_usc

OCaml

Innovation. Community. Security.