Class: Worldline::Connect::SDK::V1::Domain::LodgingCharge
- Inherits:
-
Domain::DataObject
- Object
- Domain::DataObject
- Worldline::Connect::SDK::V1::Domain::LodgingCharge
- Defined in:
- lib/worldline/connect/sdk/v1/domain/lodging_charge.rb
Instance Attribute Summary collapse
-
#charge_amount ⇒ Integer
The current value of charge_amount.
-
#charge_amount_currency_code ⇒ String
The current value of charge_amount_currency_code.
-
#charge_type ⇒ String
The current value of charge_type.
Instance Method Summary collapse
Methods inherited from Domain::DataObject
Instance Attribute Details
#charge_amount ⇒ Integer
Returns the current value of charge_amount.
15 16 17 |
# File 'lib/worldline/connect/sdk/v1/domain/lodging_charge.rb', line 15 def charge_amount @charge_amount end |
#charge_amount_currency_code ⇒ String
Returns the current value of charge_amount_currency_code.
15 16 17 |
# File 'lib/worldline/connect/sdk/v1/domain/lodging_charge.rb', line 15 def charge_amount_currency_code @charge_amount_currency_code end |
#charge_type ⇒ String
Returns the current value of charge_type.
15 16 17 |
# File 'lib/worldline/connect/sdk/v1/domain/lodging_charge.rb', line 15 def charge_type @charge_type end |
Instance Method Details
#from_hash(hash) ⇒ Object
32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/worldline/connect/sdk/v1/domain/lodging_charge.rb', line 32 def from_hash(hash) super if hash.has_key? 'chargeAmount' @charge_amount = hash['chargeAmount'] end if hash.has_key? 'chargeAmountCurrencyCode' @charge_amount_currency_code = hash['chargeAmountCurrencyCode'] end if hash.has_key? 'chargeType' @charge_type = hash['chargeType'] end end |
#to_h ⇒ Hash
24 25 26 27 28 29 30 |
# File 'lib/worldline/connect/sdk/v1/domain/lodging_charge.rb', line 24 def to_h hash = super hash['chargeAmount'] = @charge_amount unless @charge_amount.nil? hash['chargeAmountCurrencyCode'] = @charge_amount_currency_code unless @charge_amount_currency_code.nil? hash['chargeType'] = @charge_type unless @charge_type.nil? hash end |