servant-hateoas-0.2.0: HATEOAS extension for servant
Safe HaskellSafe-Inferred
LanguageGHC2021

Servant.Hateoas.ContentType.Collection

Synopsis

Documentation

data Collection (t :: Type) Source #

Data-Kind representing Content-Types of HATEOAS collections.

Type parameter t is the Mime-Type suffix in application/vnd.collection+t.

data CollectionResource a Source #

Resource wrapper for Collection.

Constructors

CollectionResource 

Fields

Instances

Instances details
CollectingResource CollectionResource Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

Resource CollectionResource Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

Methods

addLink :: forall (a :: k). (String, Link) -> CollectionResource a -> CollectionResource a Source #

(Related a, HasField (IdSelName a) a id, IsElem (GetOneApi a) api, HasLink (GetOneApi a), MkLink (GetOneApi a) Link ~ (id -> Link), BuildRels api (Relations a) a, Resource CollectionResource) => ToCollection (api :: Type) CollectionResource a Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

ToJSON a => MimeRender (Collection JSON) (CollectionResource a) Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

ToJSON a => ToJSON (CollectionResource a) Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

Generic (CollectionResource a) Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

Associated Types

type Rep (CollectionResource a) :: Type -> Type #

Show a => Show (CollectionResource a) Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection

type Rep (CollectionResource a) Source # 
Instance details

Defined in Servant.Hateoas.ContentType.Collection