package tcpip

  1. Overview
  2. Docs
OCaml TCP/IP networking stack, used in MirageOS

Install

dune-project
 Dependency

Authors

Maintainers

Sources

tcpip-8.2.0.tbz
sha256=916e688aba897676c444db8129f4963ad739f8d1be631d9e009c6228b4b7d6ed
sha512=a8f5fa8f7e96758075c93211132839950477b756fba490207a7d630f2766757bbb44bbdd02e2b1f2b4a7d83d4d8b10d34cb03903bbd516e7d7c1a9a987eb1915

doc/src/tcpip/udp.ml.html

Source file udp.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
module type S = sig
  type error
  val pp_error: error Fmt.t
  type ipaddr
  type t
  val disconnect : t -> unit Lwt.t
  type callback = src:ipaddr -> dst:ipaddr -> src_port:int -> Cstruct.t -> unit Lwt.t
  val listen : t -> port:int -> callback -> unit
  val unlisten : t -> port:int -> unit
  val input: t -> src:ipaddr -> dst:ipaddr -> Cstruct.t -> unit Lwt.t
  val write: ?src:ipaddr -> ?src_port:int -> ?ttl:int -> dst:ipaddr -> dst_port:int -> t -> Cstruct.t ->
    (unit, error) result Lwt.t
end