Sha256: 888132159bd65a821b6f4051f100fb21149be01dfb90b5aa5bf1b3484483760e

Contents?: true

Size: 381 Bytes

Versions: 7

Compression:

Stored size: 381 Bytes

Contents

module Kanpachi
  module DSL
    class Response
      def initialize(response)
        @response = response
      end

      def status(status)
        @response.status = status
      end

      def header(key, value)
        @response.headers[key] = value
      end

      def representation(&block)
        @response.representation.module_eval &block
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
kanpachi-0.0.7 lib/kanpachi/dsl/response.rb
kanpachi-0.0.6 lib/kanpachi/dsl/response.rb
kanpachi-0.0.5 lib/kanpachi/dsl/response.rb
kanpachi-0.0.4 lib/kanpachi/dsl/response.rb
kanpachi-0.0.3 lib/kanpachi/dsl/response.rb
kanpachi-0.0.2 lib/kanpachi/dsl/response.rb
kanpachi-0.0.1 lib/kanpachi/dsl/response.rb