Class: SmartyStreets::Response

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(payload, status_code, header = nil, error = nil) ⇒ Response

Returns a new instance of Response.



5
6
7
8
9
10
# File 'lib/smartystreets_ruby_sdk/response.rb', line 5

def initialize(payload, status_code, header = nil, error = nil)
  @payload = payload
  @status_code = status_code
  @header = header
  @error = error
end

Instance Attribute Details

#errorObject

Returns the value of attribute error.



3
4
5
# File 'lib/smartystreets_ruby_sdk/response.rb', line 3

def error
  @error
end

#headerObject

Returns the value of attribute header.



3
4
5
# File 'lib/smartystreets_ruby_sdk/response.rb', line 3

def header
  @header
end

#payloadObject

Returns the value of attribute payload.



3
4
5
# File 'lib/smartystreets_ruby_sdk/response.rb', line 3

def payload
  @payload
end

#status_codeObject

Returns the value of attribute status_code.



3
4
5
# File 'lib/smartystreets_ruby_sdk/response.rb', line 3

def status_code
  @status_code
end