package opium

  1. Overview
  2. Docs
OCaml web framework

Install

dune-project
 Dependency

Authors

Maintainers

Sources

opium-0.20.0.tbz
sha256=326b91866de90baf535f8b7d4b2ff23e39d952e573c04b3c13f1054b59ff2fb6
sha512=59b83e7c8fe5f7ae328fb7f2343fe5b8fb735e8f6ee263cfd6c75bb179688ef7cf2b4586b35a2231ed3f3c1ada543021b7a4759326ae095eb77a5f38b9fa3a8a

doc/opium/Opium/Version/index.html

Module Opium.VersionSource

Protocol Version

HTTP uses a "<major>.<minor>" numbering scheme to indicate versions of the protocol. The protocol version as a whole indicates the sender's conformance with the set of requirements laid out in that version's corresponding specification of HTTP.

See RFC7230§2.6 for more details.

Sourcetype t = Httpaf.Version.t = {
  1. major : int;
  2. minor : int;
}
Sourceval compare : t -> t -> int

compare x y returns 0 if version x is equal to version y, a negative integer if version x is less than version y, and a positive integer if version x is greater than version y.

Sourceval to_string : t -> string

to_string t returns a string representation of the version t.

Sourceval of_string : string -> t

of_string s returns a version from its string representation s.

Utilities

Sourceval sexp_of_t : t -> Sexplib0.Sexp.t

sexp_of_t t converts the request t to an s-expression

Sourceval pp : Format.formatter -> t -> unit

pp formats the request t as an s-expression

Sourceval pp_hum : Format.formatter -> t -> unit

pp_hum formats the request t as a standard HTTP request

OCaml

Innovation. Community. Security.

On This Page
  1. Utilities