Class: OnlinePayments::SDK::Domain::CarRentalPickupReturnData
- Inherits:
-
DataObject
- Object
- DataObject
- OnlinePayments::SDK::Domain::CarRentalPickupReturnData
- Defined in:
- lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb
Instance Attribute Summary collapse
-
#address ⇒ String?
The current value of address.
-
#city ⇒ String?
The current value of city.
-
#country ⇒ Integer?
The current value of country.
-
#date ⇒ String?
The current value of date.
-
#location ⇒ String?
The current value of location.
-
#postcode ⇒ String?
The current value of postcode.
-
#state ⇒ String?
The current value of state.
Instance Method Summary collapse
Methods inherited from DataObject
Instance Attribute Details
#address ⇒ String?
Returns the current value of address.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def address @address end |
#city ⇒ String?
Returns the current value of city.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def city @city end |
#country ⇒ Integer?
Returns the current value of country.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def country @country end |
#date ⇒ String?
Returns the current value of date.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def date @date end |
#location ⇒ String?
Returns the current value of location.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def location @location end |
#postcode ⇒ String?
Returns the current value of postcode.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def postcode @postcode end |
#state ⇒ String?
Returns the current value of state.
16 17 18 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 16 def state @state end |
Instance Method Details
#from_hash(hash) ⇒ Object
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 45 def from_hash(hash) super if hash.has_key? 'address' @address = hash['address'] end if hash.has_key? 'city' @city = hash['city'] end if hash.has_key? 'country' @country = hash['country'] end if hash.has_key? 'date' @date = hash['date'] end if hash.has_key? 'location' @location = hash['location'] end if hash.has_key? 'postcode' @postcode = hash['postcode'] end if hash.has_key? 'state' @state = hash['state'] end end |
#to_h ⇒ Hash
33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/onlinepayments/sdk/domain/car_rental_pickup_return_data.rb', line 33 def to_h hash = super hash['address'] = @address unless @address.nil? hash['city'] = @city unless @city.nil? hash['country'] = @country unless @country.nil? hash['date'] = @date unless @date.nil? hash['location'] = @location unless @location.nil? hash['postcode'] = @postcode unless @postcode.nil? hash['state'] = @state unless @state.nil? hash end |