@@ -289,15 +289,11 @@ data ParamOtherSchema = ParamOtherSchema
289 -- Default value is @False@.
289 -- Default value is @False@.
290 , _paramOtherSchemaAllowEmptyValue :: Maybe Bool
290 , _paramOtherSchemaAllowEmptyValue :: Maybe Bool
292− -- | __Required if type is @'ParamArray'@__.
293− -- Describes the type of items in the array.
294− , _paramOtherSchemaItems :: Maybe Items
296 -- | Determines the format of the array if @'ParamArray'@ is used.
292 -- | Determines the format of the array if @'ParamArray'@ is used.
297 -- Default value is csv.
293 -- Default value is csv.
298 , _paramOtherSchemaCollectionFormat :: Maybe CollectionFormat
294 , _paramOtherSchemaCollectionFormat :: Maybe CollectionFormat
300− , _paramOtherSchemaCommon :: SchemaCommon ParamType
296+ , _paramOtherSchemaCommon :: SchemaCommon ParamType Items
301 } deriving (Eq, Show, Generic)
297 } deriving (Eq, Show, Generic)
303data ParamType
299data ParamType
@@ -375,7 +371,6 @@ data Schema = Schema
375 , _schemaDescription :: Maybe Text
371 , _schemaDescription :: Maybe Text
376 , _schemaRequired :: [ParamName]
372 , _schemaRequired :: [ParamName]
378− , _schemaItems :: Maybe SchemaItems
379 , _schemaAllOf :: Maybe [Schema]
374 , _schemaAllOf :: Maybe [Schema]
380 , _schemaProperties :: HashMap Text (Referenced Schema)
375 , _schemaProperties :: HashMap Text (Referenced Schema)
381 , _schemaAdditionalProperties :: Maybe Schema
376 , _schemaAdditionalProperties :: Maybe Schema
@@ -389,7 +384,7 @@ data Schema = Schema
389 , _schemaMaxProperties :: Maybe Integer
384 , _schemaMaxProperties :: Maybe Integer
390 , _schemaMinProperties :: Maybe Integer
385 , _schemaMinProperties :: Maybe Integer
392− , _schemaSchemaCommon :: SchemaCommon SchemaType
387+ , _schemaSchemaCommon :: SchemaCommon SchemaType SchemaItems
393 } deriving (Eq, Show, Generic)
388 } deriving (Eq, Show, Generic)
395data SchemaItems
390data SchemaItems
@@ -397,7 +392,7 @@ data SchemaItems
397 | SchemaItemsArray [Referenced Schema]
392 | SchemaItemsArray [Referenced Schema]
398 deriving (Eq, Show)
393 deriving (Eq, Show)
400−data SchemaCommon typeDomain = SchemaCommon
395+data SchemaCommon typeDomain items = SchemaCommon
401 { -- | Declares the value of the parameter that the server will use if none is provided,
396 { -- | Declares the value of the parameter that the server will use if none is provided,
402 -- for example a @"count"@ to control the number of results per page might default to @100@
397 -- for example a @"count"@ to control the number of results per page might default to @100@
403 -- if not supplied by the client in the request.
398 -- if not supplied by the client in the request.
@@ -407,6 +402,7 @@ data SchemaCommon typeDomain = SchemaCommon
408 , _schemaCommonType :: typeDomain
403 , _schemaCommonType :: typeDomain
409 , _schemaCommonFormat :: Maybe Format
404 , _schemaCommonFormat :: Maybe Format
405+ , _schemaCommonItems :: Maybe items
410 , _schemaCommonMaximum :: Maybe Scientific
406 , _schemaCommonMaximum :: Maybe Scientific
411 , _schemaCommonExclusiveMaximum :: Maybe Bool
407 , _schemaCommonExclusiveMaximum :: Maybe Bool
412 , _schemaCommonMinimum :: Maybe Scientific
408 , _schemaCommonMinimum :: Maybe Scientific
@@ -450,15 +446,11 @@ data Xml = Xml
450 } deriving (Eq, Show, Generic)
446 } deriving (Eq, Show, Generic)
452data Items = Items
448data Items = Items
453− { -- | __Required if type is @'ItemsArray'@.__
454− -- Describes the type of items in the array.
455− _itemsItems :: Maybe Items
457− -- | Determines the format of the array if type array is used.
449+ { -- | Determines the format of the array if type array is used.
458 -- Default value is @'ItemsCollectionCSV'@.
450 -- Default value is @'ItemsCollectionCSV'@.
459− , _itemsCollectionFormat :: Maybe ItemsCollectionFormat
451+ _itemsCollectionFormat :: Maybe ItemsCollectionFormat
461− , _itemsCommon :: SchemaCommon ItemsType
453+ , _itemsCommon :: SchemaCommon ItemsType Items
462 } deriving (Eq, Show, Generic)
454 } deriving (Eq, Show, Generic)
464-- | A container for the expected responses of an operation.
456-- | A container for the expected responses of an operation.
@@ -504,15 +496,11 @@ data Header = Header
504 { -- | A short description of the header.
496 { -- | A short description of the header.
505 _headerDescription :: Maybe Text
497 _headerDescription :: Maybe Text
507− -- | __Required if type is @'ItemsArray'@__.
508− -- Describes the type of items in the array.
509− , _headerItems :: Maybe Items
511 -- | Determines the format of the array if type array is used.
499 -- | Determines the format of the array if type array is used.
512 -- Default value is @'ItemsCollectionCSV'@.
500 -- Default value is @'ItemsCollectionCSV'@.
513 , _headerCollectionFormat :: Maybe ItemsCollectionFormat
501 , _headerCollectionFormat :: Maybe ItemsCollectionFormat
515− , _headerCommon :: SchemaCommon ItemsType
503+ , _headerCommon :: SchemaCommon ItemsType Items
516 } deriving (Eq, Show, Generic)
504 } deriving (Eq, Show, Generic)
518data Example = Example { getExample :: Map MediaType Value }
506data Example = Example { getExample :: Map MediaType Value }
@@ -634,7 +622,7 @@ instance Monoid Schema where
634 mempty = genericMempty
622 mempty = genericMempty
635 mappend = genericMappend
623 mappend = genericMappend
637−instance SwaggerMonoid t => Monoid (SchemaCommon t) where
625+instance SwaggerMonoid t => Monoid (SchemaCommon t i) where
638 mempty = genericMempty
626 mempty = genericMempty
639 mappend = genericMappend
627 mappend = genericMappend
@@ -670,7 +658,7 @@ instance SwaggerMonoid Info
670instance SwaggerMonoid Paths
658instance SwaggerMonoid Paths
671instance SwaggerMonoid PathItem
659instance SwaggerMonoid PathItem
672instance SwaggerMonoid Schema
660instance SwaggerMonoid Schema
673−instance SwaggerMonoid t => SwaggerMonoid (SchemaCommon t)
661+instance SwaggerMonoid t => SwaggerMonoid (SchemaCommon t i)
674instance SwaggerMonoid Param
662instance SwaggerMonoid Param
675instance SwaggerMonoid ParamOtherSchema
663instance SwaggerMonoid ParamOtherSchema
676instance SwaggerMonoid Responses
664instance SwaggerMonoid Responses