package mnet

  1. Overview
  2. Docs
An implementation of TCP (Transmission Control Protocol) in OCaml for Miou & Solo5

Install

dune-project
 Dependency

Authors

Maintainers

Sources

mnet-0.0.5.tbz
sha256=ebc621ad01b33a7f96fd049e71bbd06ef95c1a6b36d4072fd15fd35c1a93dc17
sha512=8d47f9434bc6472703f55f819bea21a7deb12095d925f0f8fbb8b96b799473b62a8b302966f579792354aa256b9109dcc16851f5cf951002d35a7d70bca59135

doc/mnet.ke/Ke/index.html

Module KeSource

Sourcetype t

Type of a ringbuffer.

Utilities.

Length of a ring buffer must be a power of two. Here we have few functions to help to user to generate a power of two value or to check if a value is a power of two. Due to this constraint, a ring buffer can not be larger than max_ke_length (otherwise, we raise an exception).

Sourceval is_power_of_two : int -> bool
Sourceval to_power_of_two : int -> int
Sourceval max_ke_length : int

Ringbuffer.

Sourceval create : ?limit:int option -> int -> t
Sourceval unsafe_create : ?limit:int option -> int -> t
Sourceval push : t -> string -> unit
Sourceval peek : t -> string option
Sourceval peek_into : t -> (bytes -> off:int -> len:int -> unit) -> unit
Sourceval peek_into_bytes : t -> ?off:int -> ?len:int -> bytes -> int
Sourceval length : t -> int
Sourceval shift : t -> int -> unit
Sourceval unsafe_shift : t -> int -> unit
Sourceval available : t -> int
Sourceval compress : t -> unit