package eio
Effect-based direct-style IO API for OCaml
Install
Dune Dependency
Authors
Maintainers
Sources
eio-0.12.tbz
sha256=d84847ce85ffb78641496ad24be3c6ab5cc2c6885cedad6ae257ecac59d926a0
sha512=fbcbc8e7e8eaaeacd6c7b3be04fec19b356f900307b2cc1bf6c1cd6bd538c4ea59ab2c7d936fac00c52a3277737671759f1584025c24e0a7727447609c633821
doc/src/eio.unix/pi.ml.html
Source file pi.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51
open Eio.Std module type STREAM_SOCKET = sig include Eio.Net.Pi.STREAM_SOCKET val send_msg : t -> fds:Fd.t list -> Cstruct.t list -> int val recv_msg_with_fds : t -> sw:Switch.t -> max_fds:int -> Cstruct.t list -> int * Fd.t list val fd : t -> Fd.t end type (_, _, _) Eio.Resource.pi += | Stream_socket : ('t, (module STREAM_SOCKET with type t = 't), [> `Platform of [> `Unix] | `Socket | `Stream]) Eio.Resource.pi module type FLOW = sig include Eio.File.Pi.WRITE include STREAM_SOCKET with type t := t end let flow_handler (type t tag) (module X : FLOW with type t = t and type tag = tag) : (t, _) Eio.Resource.handler = Eio.Resource.handler @@ Eio.Resource.bindings (Eio.Net.Pi.stream_socket (module X)) @ Eio.Resource.bindings (Eio.File.Pi.rw (module X)) @ [ H (Resource.T, X.fd); H (Stream_socket, (module X)); ] module type DATAGRAM_SOCKET = sig include Eio.Net.Pi.DATAGRAM_SOCKET val fd : t -> Fd.t end let datagram_handler (type t tag) (module X : DATAGRAM_SOCKET with type t = t and type tag = tag) : (t, _) Eio.Resource.handler = Eio.Resource.handler @@ Eio.Resource.bindings (Eio.Net.Pi.datagram_socket (module X)) @ [ H (Resource.T, X.fd); ] module type LISTENING_SOCKET = sig include Eio.Net.Pi.LISTENING_SOCKET val fd : t -> Fd.t end let listening_socket_handler (type t tag) (module X : LISTENING_SOCKET with type t = t and type tag = tag) : (t, _) Eio.Resource.handler = Eio.Resource.handler @@ Eio.Resource.bindings (Eio.Net.Pi.listening_socket (module X)) @ [ H (Resource.T, X.fd); ]
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>