Class: Payrex::Entities::Refund
- Inherits:
-
Object
- Object
- Payrex::Entities::Refund
- Defined in:
- lib/entities/refund.rb
Instance Attribute Summary collapse
-
#amount ⇒ Object
readonly
Returns the value of attribute amount.
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#currency ⇒ Object
readonly
Returns the value of attribute currency.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#livemode ⇒ Object
readonly
Returns the value of attribute livemode.
-
#metadata ⇒ Object
readonly
Returns the value of attribute metadata.
-
#payment_id ⇒ Object
readonly
Returns the value of attribute payment_id.
-
#reason ⇒ Object
readonly
Returns the value of attribute reason.
-
#remarks ⇒ Object
readonly
Returns the value of attribute remarks.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
-
#updated_at ⇒ Object
readonly
Returns the value of attribute updated_at.
Instance Method Summary collapse
-
#initialize(api_resource) ⇒ Refund
constructor
A new instance of Refund.
Constructor Details
#initialize(api_resource) ⇒ Refund
Returns a new instance of Refund.
17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/entities/refund.rb', line 17 def initialize(api_resource) @id = api_resource.data["id"] @amount = api_resource.data["amount"] @currency = api_resource.data["currency"] @livemode = api_resource.data["livemode"] @status = api_resource.data["status"] @description = api_resource.data["description"] @reason = api_resource.data["reason"] @remarks = api_resource.data["remarks"] @payment_id = api_resource.data["payment_id"] @metadata = api_resource.data["metadata"] @created_at = api_resource.data["created_at"] @updated_at = api_resource.data["updated_at"] end |
Instance Attribute Details
#amount ⇒ Object (readonly)
Returns the value of attribute amount.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def amount @amount end |
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def created_at @created_at end |
#currency ⇒ Object (readonly)
Returns the value of attribute currency.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def currency @currency end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def description @description end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def id @id end |
#livemode ⇒ Object (readonly)
Returns the value of attribute livemode.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def livemode @livemode end |
#metadata ⇒ Object (readonly)
Returns the value of attribute metadata.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def @metadata end |
#payment_id ⇒ Object (readonly)
Returns the value of attribute payment_id.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def payment_id @payment_id end |
#reason ⇒ Object (readonly)
Returns the value of attribute reason.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def reason @reason end |
#remarks ⇒ Object (readonly)
Returns the value of attribute remarks.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def remarks @remarks end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def status @status end |
#updated_at ⇒ Object (readonly)
Returns the value of attribute updated_at.
4 5 6 |
# File 'lib/entities/refund.rb', line 4 def updated_at @updated_at end |