package dream-httpaf

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
module Writer = Serialize.Writer
type error = [
  1. | `Malformed_response of string
  2. | `Invalid_response_body_length of Response.t
  3. | `Protocol_error of Error_code.t * string
  4. | `Exn of exn
]
type error_handler = error -> unit
type response_handler = Response.t -> Body.Reader.t -> unit
type response_info = {
  1. response : Response.t;
  2. response_body : Body.Reader.t;
  3. mutable response_body_bytes : int64;
  4. mutable trailers_parser : Stream.partial_headers option;
}
type trailers_handler = Headers.t -> unit
type active_request = {
  1. request : Request.t;
  2. request_body : Body.Writer.t;
  3. response_handler : response_handler;
  4. trailers_handler : trailers_handler;
}
val create_active_response : Response.t -> Body.Reader.t -> response_info Stream.remote_state
val close_stream : ((('a, 'b) Stream.active_state, 'c, 'd) Stream.state, 'e, 'f) Stream.stream -> unit
val _report_error : t -> ?response_body:Body.Reader.t -> error -> Error_code.t -> bool
val report_error : t -> error -> Error_code.t -> unit
val requires_output : ((('a, 'b) Stream.active_state, 'c, 'd) Stream.state, 'e, 'f) Stream.stream -> bool
val flush_request_body : ((('a, 'b Stream.remote_state) Stream.active_state, active_request, 'c) Stream.state, 'd, 'e) Stream.stream -> max_bytes:int -> int
val deliver_trailer_headers : ((('a, 'b Stream.remote_state) Stream.active_state, active_request, 'c) Stream.state, 'd, 'e) Stream.stream -> Headers.t -> unit
OCaml

Innovation. Community. Security.