Class: WebPay::ChargeResponseList
- Inherits:
-
Entity
- Object
- Entity
- WebPay::ChargeResponseList
show all
- Defined in:
- lib/webpay/data_types.rb
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Entity
#normalize_hash, #to_h, #to_s
Constructor Details
Returns a new instance of ChargeResponseList.
711
712
713
714
715
|
# File 'lib/webpay/data_types.rb', line 711
def initialize(hash = {})
hash = normalize_hash(hash)
hash['data'] = hash['data'].is_a?(Array) ? hash['data'].map { |x| WebPay::ChargeResponse.new(x) if x.is_a?(Hash) } : hash['data']
@attributes = hash
end
|
Instance Attribute Details
#attributes ⇒ Object
Returns the value of attribute attributes.
704
705
706
|
# File 'lib/webpay/data_types.rb', line 704
def attributes
@attributes
end
|
Class Method Details
.fields ⇒ Object
706
707
708
|
# File 'lib/webpay/data_types.rb', line 706
def self.fields
['object', 'url', 'count', 'data']
end
|
Instance Method Details
#count ⇒ Object
728
729
730
|
# File 'lib/webpay/data_types.rb', line 728
def count
attributes['count']
end
|
#data ⇒ Object
732
733
734
|
# File 'lib/webpay/data_types.rb', line 732
def data
attributes['data']
end
|
#object ⇒ Object
720
721
722
|
# File 'lib/webpay/data_types.rb', line 720
def object
attributes['object']
end
|
#url ⇒ Object
724
725
726
|
# File 'lib/webpay/data_types.rb', line 724
def url
attributes['url']
end
|