class Xenon::Response

Attributes

body[R]
headers[R]
status[R]

Public Class Methods

new() click to toggle source
# File lib/xenon/response.rb, line 7
def initialize
  @headers = Headers.new
  @complete = false
  freeze
end

Public Instance Methods

complete?() click to toggle source
# File lib/xenon/response.rb, line 13
def complete?
  @complete
end
copy(changes = {}) click to toggle source
# File lib/xenon/response.rb, line 17
def copy(changes = {})
  r = dup
  changes.each { |k, v| r.instance_variable_set("@#{k}", v) }
  r.freeze
end
freeze() click to toggle source
Calls superclass method
# File lib/xenon/response.rb, line 23
def freeze
  @headers.freeze
  @body.freeze
  super
end