Sha256: 1b80cd591b6f576f00759676078cb6ad2134b4ed8f79c97969ffa1f94037b8bb

Contents?: true

Size: 734 Bytes

Versions: 4

Compression:

Stored size: 734 Bytes

Contents

# frozen_string_literal: true

require "openapi3_parser/node/object"

module Openapi3Parser
  module Node
    # @see https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.0.md#responseObject
    class Response < Node::Object
      # @return [String]
      def description
        node_data["description"]
      end

      # @return [String]
      def description_html
        render_markdown(description)
      end

      # @return [Map<String, Header>]
      def headers
        node_data["headers"]
      end

      # @return [Map<String, MediaType>]
      def content
        node_data["content"]
      end

      # @return [Map<String, Link>]
      def links
        node_data["links"]
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
openapi3_parser-0.5.2 lib/openapi3_parser/node/response.rb
openapi3_parser-0.5.1 lib/openapi3_parser/node/response.rb
openapi3_parser-0.5.0 lib/openapi3_parser/node/response.rb
openapi3_parser-0.4.0 lib/openapi3_parser/node/response.rb