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.S
include Mirage_device.S
type t
val disconnect : t -> unit Lwt.t
include Mirage_flow.S with type flow := t
type error
val pp_error : error Fmt.t
type nonrec write_error = private [>
  1. | Mirage_flow.write_error
]
val pp_write_error : write_error Fmt.t
val read : t -> (Cstruct.t Mirage_flow.or_eof, error) Stdlib.result Lwt.t
val write : t -> Cstruct.t -> (unit, write_error) Stdlib.result Lwt.t
val writev : t -> Cstruct.t list -> (unit, write_error) Stdlib.result Lwt.t
val close : t -> unit Lwt.t
val log : t -> string -> unit Lwt.t

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.