wire-api-federation-0.1.0: The Wire server-to-server API for federation
Safe HaskellSafe-Inferred
LanguageGHC2021

Wire.API.Federation.Version

Synopsis

Version, VersionInfo

data Version Source #

Constructors

V0 
V1 
V2 

Instances

Instances details
FromJSON Version Source # 
Instance details

Defined in Wire.API.Federation.Version

ToJSON Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Bounded Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Enum Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Generic Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Associated Types

type Rep Version :: Type -> Type #

Methods

from :: Version -> Rep Version x #

to :: Rep Version x -> Version #

Show Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Eq Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Methods

(==) :: Version -> Version -> Bool #

(/=) :: Version -> Version -> Bool #

Ord Version Source # 
Instance details

Defined in Wire.API.Federation.Version

ToSchema Version Source # 
Instance details

Defined in Wire.API.Federation.Version

SingKind Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Associated Types

type Demote Version = (r :: Type) Source #

POrd Version Source # 
Instance details

Defined in Wire.API.Federation.Version

Associated Types

type Compare arg arg1 :: Ordering Source #

type arg < arg1 :: Bool Source #

type arg <= arg1 :: Bool Source #

type arg > arg1 :: Bool Source #

type arg >= arg1 :: Bool Source #

type Max arg arg1 :: a Source #

type Min arg arg1 :: a Source #

SingI 'V0 Source # 
Instance details

Defined in Wire.API.Federation.Version

Methods

sing :: Sing 'V0 Source #

SingI 'V1 Source # 
Instance details

Defined in Wire.API.Federation.Version

Methods

sing :: Sing 'V1 Source #

SingI 'V2 Source # 
Instance details

Defined in Wire.API.Federation.Version

Methods

sing :: Sing 'V2 Source #

VersionedMonad Version (FederatorClient c) Source # 
Instance details

Defined in Wire.API.Federation.Client

(IsNamed name, SingI v) => IsNamed (Versioned v name :: Type) Source # 
Instance details

Defined in Wire.API.Federation.API

Methods

nameVal' :: Text Source #

type Rep Version Source # 
Instance details

Defined in Wire.API.Federation.Version

type Rep Version = D1 ('MetaData "Version" "Wire.API.Federation.Version" "wire-api-federation-0.1.0-KrCnHof6TO1avA0Ur7PtD" 'False) (C1 ('MetaCons "V0" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "V1" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "V2" 'PrefixI 'False) (U1 :: Type -> Type)))
type Demote Version Source # 
Instance details

Defined in Wire.API.Federation.Version

type Sing Source # 
Instance details

Defined in Wire.API.Federation.Version

type Sing
type (arg :: Version) < (arg1 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type (arg :: Version) < (arg1 :: Version) = Apply (Apply (TFHelper_6989586621679359029Sym0 :: TyFun Version (Version ~> Bool) -> Type) arg) arg1
type (arg :: Version) <= (arg1 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type (arg :: Version) <= (arg1 :: Version) = Apply (Apply (TFHelper_6989586621679359045Sym0 :: TyFun Version (Version ~> Bool) -> Type) arg) arg1
type (arg :: Version) > (arg1 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type (arg :: Version) > (arg1 :: Version) = Apply (Apply (TFHelper_6989586621679359061Sym0 :: TyFun Version (Version ~> Bool) -> Type) arg) arg1
type (arg :: Version) >= (arg1 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type (arg :: Version) >= (arg1 :: Version) = Apply (Apply (TFHelper_6989586621679359077Sym0 :: TyFun Version (Version ~> Bool) -> Type) arg) arg1
type Compare (a1 :: Version) (a2 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type Compare (a1 :: Version) (a2 :: Version)
type Max (arg :: Version) (arg1 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type Max (arg :: Version) (arg1 :: Version) = Apply (Apply (Max_6989586621679359093Sym0 :: TyFun Version (Version ~> Version) -> Type) arg) arg1
type Min (arg :: Version) (arg1 :: Version) Source # 
Instance details

Defined in Wire.API.Federation.Version

type Min (arg :: Version) (arg1 :: Version) = Apply (Apply (Min_6989586621679359109Sym0 :: TyFun Version (Version ~> Version) -> Type) arg) arg1

type family V0Sym0 :: Version where ... Source #

Equations

V0Sym0 = 'V0 

type family V1Sym0 :: Version where ... Source #

Equations

V1Sym0 = 'V1 

type family V2Sym0 :: Version where ... Source #

Equations

V2Sym0 = 'V2 

VersionRange

data VersionRange Source #

Instances

Instances details
FromJSON VersionRange Source # 
Instance details

Defined in Wire.API.Federation.Version

ToJSON VersionRange Source # 
Instance details

Defined in Wire.API.Federation.Version

Semigroup VersionRange Source #

The semigroup instance of VersionRange is intersection.

Instance details

Defined in Wire.API.Federation.Version

Show VersionRange Source # 
Instance details

Defined in Wire.API.Federation.Version

Eq VersionRange Source # 
Instance details

Defined in Wire.API.Federation.Version

Ord VersionRange Source # 
Instance details

Defined in Wire.API.Federation.Version

ToSchema VersionRange Source # 
Instance details

Defined in Wire.API.Federation.Version

latestCommonVersion :: Foldable f => VersionRange -> f Int -> Maybe Version Source #

For a version range of a local backend and for a set of versions that a remote backend supports, compute the newest version supported by both. The remote versions are given as integers as the range of versions supported by the remote backend can include a version unknown to the local backend. If there is no version in common, the return value is Nothing.