siren-json-0.3.1.1: Siren Tools for Haskell

Copyright(c) Alex Brandt 2017
LicenseMIT
Safe HaskellNone
LanguageHaskell2010

Data.SirenJSON

Contents

Description

A collection of types and instances for application/vnd.siren+json.

Full documentation for application/vnd.siren+json can be found at https://github.com/kevinswiber/siren.

Synopsis

Core Data Types

data Entity Source #

The top-level object for an application/vnd.siren+json resource.

Constructors

Entity 

Fields

Instances
Eq Entity Source # 
Instance details

Defined in Data.SirenJSON

Methods

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

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

Show Entity Source # 
Instance details

Defined in Data.SirenJSON

ToJSON Entity Source # 
Instance details

Defined in Data.SirenJSON

FromJSON Entity Source # 
Instance details

Defined in Data.SirenJSON

data SubEntity Source #

Nested object for an application/vnd.siren+json.

Instances
Eq SubEntity Source # 
Instance details

Defined in Data.SirenJSON

Show SubEntity Source # 
Instance details

Defined in Data.SirenJSON

ToJSON SubEntity Source # 
Instance details

Defined in Data.SirenJSON

FromJSON SubEntity Source # 
Instance details

Defined in Data.SirenJSON

data Link Source #

Link to a related resource.

Constructors

Link 

Fields

data Action Source #

Behavior of an Entity.

Constructors

Action 
Instances
Eq Action Source # 
Instance details

Defined in Data.SirenJSON

Methods

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

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

Show Action Source # 
Instance details

Defined in Data.SirenJSON

ToJSON Action Source # 
Instance details

Defined in Data.SirenJSON

FromJSON Action Source # 
Instance details

Defined in Data.SirenJSON

data Field Source #

Control inside of an Action.

Constructors

Field 
Instances
Eq Field Source # 
Instance details

Defined in Data.SirenJSON

Methods

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

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

Show Field Source # 
Instance details

Defined in Data.SirenJSON

Methods

showsPrec :: Int -> Field -> ShowS #

show :: Field -> String #

showList :: [Field] -> ShowS #

ToJSON Field Source # 
Instance details

Defined in Data.SirenJSON

FromJSON Field Source # 
Instance details

Defined in Data.SirenJSON

Type Conversion

class FromEntity a where Source #

A type that can be converted from Entity.

Methods

fromEntity :: Entity -> a Source #

class ToEntity a where Source #

A type that can be converted to Entity.

Methods

toEntity :: a -> Entity Source #