package mirage-console-unix

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Text console input/output operations.

include Mirage_console_lwt.S
include Mirage_device.S with type 'a io = 'a Lwt.t
type 'a io = 'a Lwt.t
type t
val disconnect : t -> unit io
include Mirage_flow.S with type 'a io := 'a io and type flow := t with type buffer = Cstruct.t
type error
val pp_error : error Fmt.t
type write_error = private [>
  1. | Mirage_flow.write_error
]
val pp_write_error : write_error Fmt.t
type buffer = Cstruct.t
val read : t -> (buffer Mirage_flow.or_eof, error) Stdlib.result io
val write : t -> buffer -> (unit, write_error) Stdlib.result io
val writev : t -> buffer list -> (unit, write_error) Stdlib.result io
val close : t -> unit io
val log : t -> string -> unit io

log t str writes str to the console t, appending appropriate line endings. If close was called on the console before, str is discarded silently.

val connect : string -> t Lwt.t
OCaml

Innovation. Community. Security.