Sha256: c29ace9e0eb8faa24b018ccf52e89e8bf58c83507e340a72257ec9a907db9603
Contents?: true
Size: 617 Bytes
Versions: 7
Compression:
Stored size: 617 Bytes
Contents
require "json/schema/serializer" require_relative "./schema_accessor" require_relative "./media_type/deserializer" require_relative "./media_type/validator" module Swagger class Schema class MediaType extend SchemaAccessor def initialize(schema) @schema = schema end define_schema_accessor :schema, :example, :examples, :encoding def serializer(options = {}) JSON::Schema::Serializer.new(schema, options) end def deserializer Deserializer.new(schema) end def validator Validator.new(schema) end end end end
Version data entries
7 entries across 7 versions & 1 rubygems