package capnp-rpc-mirage

  1. Overview
  2. Docs
type 'a io = 'a Lwt.t
type io_addr = Ipaddr.t * int
type ns_addr = [ `TCP | `UDP ] * io_addr
type stack = Stack.t
val create : ?nameserver:ns_addr -> timeout:int64 -> stack -> t
val nameserver : t -> ns_addr
val rng : int -> Cstruct.t
val clock : unit -> int64
val connect : ?nameserver:ns_addr -> t -> (context, [> `Msg of string ]) Stdlib.result io
val send : context -> Cstruct.t -> (unit, [> `Msg of string ]) Stdlib.result io
val recv : context -> (Cstruct.t, [> `Msg of string ]) Stdlib.result io
val close : context -> unit io
val bind : 'a io -> ('a -> 'b io) -> 'b io
val lift : 'a -> 'a io
OCaml

Innovation. Community. Security.