package tcpip

  1. Overview
  2. Docs

Parameters

module IP : Mirage_protocols_lwt.IP
module R : Mirage_random.C

Signature

include Mirage_protocols_lwt.UDP with type ip = IP.t and type ipaddr = IP.ipaddr and type ipinput = src:IP.ipaddr -> dst:IP.ipaddr -> Cstruct.t -> unit Lwt.t
type error
val pp_error : error Fmt.t
type buffer = Cstruct.t
type ip = IP.t
type ipaddr = IP.ipaddr
type ipinput = src:IP.ipaddr -> dst:IP.ipaddr -> Cstruct.t -> unit Lwt.t
type 'a io = 'a Lwt.t
type t
val disconnect : t -> unit io
type callback = src:ipaddr -> dst:ipaddr -> src_port:int -> buffer -> unit io
val input : listeners:(dst_port:int -> callback option) -> t -> ipinput
val write : ?src_port:int -> dst:ipaddr -> dst_port:int -> t -> buffer -> (unit, error) Pervasives.result io
val connect : ip -> t Lwt.t
OCaml

Innovation. Community. Security.