package bencode

  1. Overview
  2. Docs
type t
type result =
  1. | Next of token
  2. | End
  3. | Error of string
  4. | Await
val of_string : string -> t
val of_bytes : Bytes.t -> t
val of_slice : string -> int -> int -> t
val of_bytes_slice : Bytes.t -> int -> int -> t
val of_chan : in_channel -> t
val manual : unit -> t
val feed : t -> string -> int -> int -> unit
val feed_bytes : t -> Bytes.t -> int -> int -> unit
val next : t -> result
val iter : t -> (token -> unit) -> unit
val to_list : t -> token list option
OCaml

Innovation. Community. Security.