Class: Miron::Response

Inherits:
Object
  • Object
show all
Defined in:
lib/miron/response.rb

Overview

Miron::Reponse allows HTTP responses to be sent.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeResponse


18
19
20
21
22
23
# File 'lib/miron/response.rb', line 18

def initialize
  @http_status = 200
  @headers = {}
  @body = ''
  @cookies = {}
end

Instance Attribute Details

#bodyObject

Returns the value of attribute body


5
6
7
# File 'lib/miron/response.rb', line 5

def body
  @body
end

#cookiesObject

Returns the value of attribute cookies


5
6
7
# File 'lib/miron/response.rb', line 5

def cookies
  @cookies
end

#headersObject

Returns the value of attribute headers


5
6
7
# File 'lib/miron/response.rb', line 5

def headers
  @headers
end

#http_statusObject

Returns the value of attribute http_status


5
6
7
# File 'lib/miron/response.rb', line 5

def http_status
  @http_status
end