Class: Seriline::ResponseData
- Inherits:
-
Object
- Object
- Seriline::ResponseData
- Defined in:
- lib/seriline/response_data.rb
Direct Known Subclasses
AvailableConfigProductNode, AvailableConfigProductsResponse, ConfigProductSingleOrderResponse, LoginResponse, OrderInfoResponse
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ ResponseData
constructor
A new instance of ResponseData.
- #success? ⇒ Boolean
Constructor Details
#initialize(attributes = {}) ⇒ ResponseData
Returns a new instance of ResponseData.
23 24 25 26 27 28 29 |
# File 'lib/seriline/response_data.rb', line 23 def initialize(attributes = {}) attributes.each do |attribute, value| reader_name = snake_case(attribute) next unless respond_to? reader_name instance_variable_set("@#{reader_name}", value) end end |
Instance Method Details
#success? ⇒ Boolean
31 32 33 |
# File 'lib/seriline/response_data.rb', line 31 def success? success end |