Class: DuffelAPI::Resources::OrderChangeOffer

Inherits:
BaseResource
  • Object
show all
Defined in:
lib/duffel_api/resources/order_change_offer.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from BaseResource

#api_response

Constructor Details

#initialize(object, response = nil) ⇒ OrderChangeOffer

Returns a new instance of OrderChangeOffer.



22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# File 'lib/duffel_api/resources/order_change_offer.rb', line 22

def initialize(object, response = nil)
  @object = object

  @change_total_amount = object["change_total_amount"]
  @change_total_currency = object["change_total_currency"]
  @created_at = object["created_at"]
  @expires_at = object["expires_at"]
  @id = object["id"]
  @live_mode = object["live_mode"]
  @new_total_amount = object["new_total_amount"]
  @new_total_currency = object["new_total_currency"]
  @order_change_id = object["order_change_id"]
  @penalty_total_amount = object["penalty_total_amount"]
  @penalty_total_currency = object["penalty_total_currency"]
  @refund_to = object["refund_to"]
  @slices = object["slices"]
  @updated_at = object["updated_at"]

  super(object, response)
end

Instance Attribute Details

#change_total_amountObject (readonly)

Returns the value of attribute change_total_amount.



7
8
9
# File 'lib/duffel_api/resources/order_change_offer.rb', line 7

def change_total_amount
  @change_total_amount
end

#change_total_currencyObject (readonly)

Returns the value of attribute change_total_currency.



8
9
10
# File 'lib/duffel_api/resources/order_change_offer.rb', line 8

def change_total_currency
  @change_total_currency
end

#created_atObject (readonly)

Returns the value of attribute created_at.



9
10
11
# File 'lib/duffel_api/resources/order_change_offer.rb', line 9

def created_at
  @created_at
end

#expires_atObject (readonly)

Returns the value of attribute expires_at.



10
11
12
# File 'lib/duffel_api/resources/order_change_offer.rb', line 10

def expires_at
  @expires_at
end

#idObject (readonly)

Returns the value of attribute id.



11
12
13
# File 'lib/duffel_api/resources/order_change_offer.rb', line 11

def id
  @id
end

#live_modeObject (readonly)

Returns the value of attribute live_mode.



12
13
14
# File 'lib/duffel_api/resources/order_change_offer.rb', line 12

def live_mode
  @live_mode
end

#new_total_amountObject (readonly)

Returns the value of attribute new_total_amount.



13
14
15
# File 'lib/duffel_api/resources/order_change_offer.rb', line 13

def new_total_amount
  @new_total_amount
end

#new_total_currencyObject (readonly)

Returns the value of attribute new_total_currency.



14
15
16
# File 'lib/duffel_api/resources/order_change_offer.rb', line 14

def new_total_currency
  @new_total_currency
end

#order_change_idObject (readonly)

Returns the value of attribute order_change_id.



15
16
17
# File 'lib/duffel_api/resources/order_change_offer.rb', line 15

def order_change_id
  @order_change_id
end

#penalty_total_amountObject (readonly)

Returns the value of attribute penalty_total_amount.



16
17
18
# File 'lib/duffel_api/resources/order_change_offer.rb', line 16

def penalty_total_amount
  @penalty_total_amount
end

#penalty_total_currencyObject (readonly)

Returns the value of attribute penalty_total_currency.



17
18
19
# File 'lib/duffel_api/resources/order_change_offer.rb', line 17

def penalty_total_currency
  @penalty_total_currency
end

#refund_toObject (readonly)

Returns the value of attribute refund_to.



18
19
20
# File 'lib/duffel_api/resources/order_change_offer.rb', line 18

def refund_to
  @refund_to
end

#slicesObject (readonly)

Returns the value of attribute slices.



19
20
21
# File 'lib/duffel_api/resources/order_change_offer.rb', line 19

def slices
  @slices
end

#updated_atObject (readonly)

Returns the value of attribute updated_at.



20
21
22
# File 'lib/duffel_api/resources/order_change_offer.rb', line 20

def updated_at
  @updated_at
end