json-schema-0.7.4.2: Types and type classes for defining JSON schemas.

Safe HaskellNone
LanguageHaskell2010

Data.JSON.Schema.Generic

Description

Generic derivation of schemas. The schemas generated match the JSON generated by type 'generic-aeson' package. See that package for documentation on the format and examples of it.

Synopsis

Documentation

class GJSONSchema f Source #

Minimal complete definition

gSchema'

Instances
GJSONSchema (U1 :: * -> *) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (U1 a) -> Schema

GJSONSchema (K1 i String :: * -> *) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (K1 i String a) -> Schema

JSONSchema c => GJSONSchema (K1 i c :: * -> *) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (K1 i c a) -> Schema

(GJSONSchema f, GJSONSchema g) => GJSONSchema (f :+: g) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy ((f :+: g) a) -> Schema

(GJSONSchema f, GJSONSchema g) => GJSONSchema (f :*: g) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy ((f :*: g) a) -> Schema

GJSONSchema f => GJSONSchema (M1 D c f) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (M1 D c f a) -> Schema

(Constructor c, GJSONSchema f) => GJSONSchema (M1 C c f) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (M1 C c f a) -> Schema

(Selector c, GJSONSchema f) => GJSONSchema (M1 S c f) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (M1 S c f a) -> Schema

Selector c => GJSONSchema (M1 S c (K1 i (Maybe String) :: * -> *)) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (M1 S c (K1 i (Maybe String)) a) -> Schema

(Selector c, JSONSchema a) => GJSONSchema (M1 S c (K1 i (Maybe a) :: * -> *)) Source # 
Instance details

Defined in Data.JSON.Schema.Generic

Methods

gSchema' :: Settings -> Bool -> [Text] -> Proxy (M1 S c (K1 i (Maybe a)) a0) -> Schema

gSchema :: (Generic a, GJSONSchema (Rep a), ConNames (Rep a), GIsEnum (Rep a)) => Proxy a -> Schema Source #

Derive a JSON schema for types with an instance of Generic.