package eio

  1. Overview
  2. Docs
include Eio.File.Pi.WRITE
include Eio.Flow.Pi.SINK
type t
include Eio.File.Pi.READ with type t := t
include Eio.Flow.Pi.SOURCE with type t := t
val pread : t -> file_offset:Optint.Int63.t -> Cstruct.t list -> int
val stat : t -> Eio.File.Stat.t
val seek : t -> Optint.Int63.t -> [ `Set | `Cur | `End ] -> Optint.Int63.t
val pwrite : t -> file_offset:Optint.Int63.t -> Cstruct.t list -> int
val sync : t -> unit
val truncate : t -> Optint.Int63.t -> unit
include STREAM_SOCKET with type t := t
include Eio.Net.Pi.STREAM_SOCKET with type t := t
type tag
include Eio.Flow.Pi.SHUTDOWN with type t := t
val shutdown : t -> Eio.Flow.shutdown_command -> unit
include Eio.Flow.Pi.SOURCE with type t := t
val read_methods : t Eio.Flow.read_method list
val single_read : t -> Cstruct.t -> int
include Eio.Flow.Pi.SINK with type t := t
val single_write : t -> Cstruct.t list -> int
val copy : t -> src:_ Eio.Flow.source -> unit

copy t ~src allows for optimising copy operations.

If you have no optimisations, you can use simple_copy to implement this using single_write.

val close : t -> unit
val send_msg : t -> fds:Fd.t list -> Cstruct.t list -> int
val recv_msg_with_fds : t -> sw:Eio.Std.Switch.t -> max_fds:int -> Cstruct.t list -> int * Fd.t list
val fd : t -> Fd.t
OCaml

Innovation. Community. Security.