elm-bridge-0.8.4: Derive Elm types and Json code from Haskell types, using aeson's options
Safe HaskellSafe-Inferred
LanguageHaskell2010

Elm.TyRep

Description

This module defines how the derived Haskell data types are represented. - It is useful for writing type conversion rules.

Synopsis

Documentation

data ETypeDef Source #

Type definition, including constructors.

Instances

Instances details
Show ETypeDef Source # 
Instance details

Defined in Elm.TyRep

ElmRenderable ETypeDef Source # 
Instance details

Defined in Elm.TyRender

Eq ETypeDef Source # 
Instance details

Defined in Elm.TyRep

data EType Source #

Type construction : type variables, type constructors, tuples and type application.

Instances

Instances details
Show EType Source # 
Instance details

Defined in Elm.TyRep

ElmRenderable EType Source # 
Instance details

Defined in Elm.TyRender

Eq EType Source # 
Instance details

Defined in Elm.TyRep

Methods

(==) :: EType -> EType -> Bool Source #

(/=) :: EType -> EType -> Bool Source #

Ord EType Source # 
Instance details

Defined in Elm.TyRep

newtype ETCon Source #

Type constructor:

ETCon "Int"

Constructors

ETCon 

Fields

Instances

Instances details
Show ETCon Source # 
Instance details

Defined in Elm.TyRep

ElmRenderable ETCon Source # 
Instance details

Defined in Elm.TyRender

Eq ETCon Source # 
Instance details

Defined in Elm.TyRep

Methods

(==) :: ETCon -> ETCon -> Bool Source #

(/=) :: ETCon -> ETCon -> Bool Source #

Ord ETCon Source # 
Instance details

Defined in Elm.TyRep

newtype ETVar Source #

Type variable:

ETVar "a"

Constructors

ETVar 

Fields

Instances

Instances details
Show ETVar Source # 
Instance details

Defined in Elm.TyRep

ElmRenderable ETVar Source # 
Instance details

Defined in Elm.TyRender

Eq ETVar Source # 
Instance details

Defined in Elm.TyRep

Methods

(==) :: ETVar -> ETVar -> Bool Source #

(/=) :: ETVar -> ETVar -> Bool Source #

Ord ETVar Source # 
Instance details

Defined in Elm.TyRep

data ETypeName Source #

Type name:

ETypeName "Map" [ETVar "k", ETVar "v"]

Constructors

ETypeName 

Fields

data EAlias Source #

Instances

Instances details
Show EAlias Source # 
Instance details

Defined in Elm.TyRep

ElmRenderable EAlias Source # 
Instance details

Defined in Elm.TyRender

Eq EAlias Source # 
Instance details

Defined in Elm.TyRep

Ord EAlias Source # 
Instance details

Defined in Elm.TyRep

data ESum Source #

Instances

Instances details
Show ESum Source # 
Instance details

Defined in Elm.TyRep

ElmRenderable ESum Source # 
Instance details

Defined in Elm.TyRender

Eq ESum Source # 
Instance details

Defined in Elm.TyRep

Methods

(==) :: ESum -> ESum -> Bool Source #

(/=) :: ESum -> ESum -> Bool Source #

Ord ESum Source # 
Instance details

Defined in Elm.TyRep

unpackTupleType :: EType -> [EType] Source #

Transforms tuple types in a list of types. Otherwise returns a singleton list with the original type.

toElmType :: Typeable a => Proxy a -> EType Source #

Get an elm-bridge type representation for a Haskell type. This can be used to render the type declaration via ElmRenderable or the the JSON serializer/parser names via jsonSerForType and jsonParserForType.