class Marvelite::API::Response

Attributes

raw_response[R]

Public Class Methods

make(response) click to toggle source
# File lib/marvelite/api/response.rb, line 11
def self.make(response)
  case response.code
  when 200
    Response.new(response)
  when 304
    NotModifiedResponse.new(response)
  else
    ErrorResponse.new(response)
  end
end
new(raw) click to toggle source
Calls superclass method
# File lib/marvelite/api/response.rb, line 22
def initialize(raw)
  @raw_response = raw
  super(raw)
end