Class: Klarna::Checkout::Address
- Defined in:
- lib/klarna/checkout/address.rb
Instance Attribute Summary collapse
-
#care_of ⇒ Object
Returns the value of attribute care_of.
-
#city ⇒ Object
Returns the value of attribute city.
-
#country ⇒ Object
Returns the value of attribute country.
-
#email ⇒ Object
Returns the value of attribute email.
-
#family_name ⇒ Object
Returns the value of attribute family_name.
-
#given_name ⇒ Object
Returns the value of attribute given_name.
-
#phone ⇒ Object
Returns the value of attribute phone.
-
#postal_code ⇒ Object
Returns the value of attribute postal_code.
-
#street_address ⇒ Object
Returns the value of attribute street_address.
Instance Method Summary collapse
Methods inherited from Resource
defaults, defaults=, #initialize, #json_sanitize, #to_json
Methods included from HasOne
Methods included from HasMany
Constructor Details
This class inherits a constructor from Klarna::Checkout::Resource
Instance Attribute Details
#care_of ⇒ Object
Returns the value of attribute care_of.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def care_of @care_of end |
#city ⇒ Object
Returns the value of attribute city.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def city @city end |
#country ⇒ Object
Returns the value of attribute country.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def country @country end |
#email ⇒ Object
Returns the value of attribute email.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def email @email end |
#family_name ⇒ Object
Returns the value of attribute family_name.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def family_name @family_name end |
#given_name ⇒ Object
Returns the value of attribute given_name.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def given_name @given_name end |
#phone ⇒ Object
Returns the value of attribute phone.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def phone @phone end |
#postal_code ⇒ Object
Returns the value of attribute postal_code.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def postal_code @postal_code end |
#street_address ⇒ Object
Returns the value of attribute street_address.
4 5 6 |
# File 'lib/klarna/checkout/address.rb', line 4 def street_address @street_address end |
Instance Method Details
#as_json ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/klarna/checkout/address.rb', line 7 def as_json json_sanitize({ :given_name => @given_name, :family_name => @family_name, :care_of => @care_of, :street_address => @street_address, :postal_code => @postal_code, :city => @city, :country => @country, :email => @email, :phone => @phone }) end |