HttpVersion

Companion
class
trait Product
trait Mirror
class Object
trait Matchable
class Any

Type members

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Inherited from
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Inherited from
Mirror

Value members

Concrete methods

Returns an HTTP version from its HTTP/1 string representation.

Returns an HTTP version from its HTTP/1 string representation.

>>> HttpVersion.fromString("HTTP/1.1")
Right(HTTP/1.1)
def fromVersion(major: Int, minor: Int): ParseResult[HttpVersion]

Returns an HTTP version from a major and minor version.

Returns an HTTP version from a major and minor version.

>>> HttpVersion.fromVersion(1, 1)
Right(HTTP/1.1)

>>> HttpVersion.fromVersion(1, 10)
Left(org.http4s.ParseFailure: Invalid HTTP version: major must be <= 9: 10)
Value Params
major

The major version, 0 to 9 inclusive

minor

The minor version, 0 to 9 inclusive

Deprecated methods

@deprecated("Renamed to `HTTP/2`. HTTP/2 does not define minor versions.", "0.22.6")
Deprecated

Concrete fields

HTTP/0.9 was first formalized in the HTTP/1.0 spec. HTTP/0.9 does not literally appear in the HTTP/0.9 protocol.

HTTP/0.9 was first formalized in the HTTP/1.0 spec. HTTP/0.9 does not literally appear in the HTTP/0.9 protocol.

See also

HTTP/1.0 is the first major version of HTTP.

HTTP/1.0 is the first major version of HTTP.

See also

HTTP/2 is the second major version of HTTP. It defines no minor versions, so minor version 0 is implied.

HTTP/2 is the second major version of HTTP. It defines no minor versions, so minor version 0 is implied.

See also

HTTP/3 is the third major version of HTTP. It defines no minor versions, so minor version 0 is implied.

HTTP/3 is the third major version of HTTP. It defines no minor versions, so minor version 0 is implied.

See also

Transfer Protocol Version 3 (HTTP/3) (draft)

Implicits

Implicits

implicit
val catsInstancesForHttp4sHttpVersion: Order[HttpVersion] & Show[HttpVersion] & Hash[HttpVersion] & BoundedEnumerable[HttpVersion]