Class: Moov::Models::Components::GooglePayBillingAddress
- Inherits:
-
Object
- Object
- Moov::Models::Components::GooglePayBillingAddress
- Extended by:
- T::Sig
- Includes:
- Crystalline::MetadataFields
- Defined in:
- lib/moov/models/components/googlepaybillingaddress.rb
Overview
Billing address as returned by Google Pay.
Refer to [Google's documentation](https://developers.google.com/pay/api/web/reference/response-objects#Address)
for more information.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(address1: nil, address2: nil, address3: nil, locality: nil, administrative_area: nil, postal_code: nil, country_code: nil, name: nil, phone_number: nil, sorting_code: nil) ⇒ GooglePayBillingAddress
constructor
A new instance of GooglePayBillingAddress.
Methods included from Crystalline::MetadataFields
#field, #fields, included, #marshal_single, #to_dict, #to_json
Constructor Details
#initialize(address1: nil, address2: nil, address3: nil, locality: nil, administrative_area: nil, postal_code: nil, country_code: nil, name: nil, phone_number: nil, sorting_code: nil) ⇒ GooglePayBillingAddress
Returns a new instance of GooglePayBillingAddress.
40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/moov/models/components/googlepaybillingaddress.rb', line 40 def initialize(address1: nil, address2: nil, address3: nil, locality: nil, administrative_area: nil, postal_code: nil, country_code: nil, name: nil, phone_number: nil, sorting_code: nil) @address1 = address1 @address2 = address2 @address3 = address3 @locality = locality @administrative_area = administrative_area @postal_code = postal_code @country_code = country_code @name = name @phone_number = phone_number @sorting_code = sorting_code end |
Instance Method Details
#==(other) ⇒ Object
54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
# File 'lib/moov/models/components/googlepaybillingaddress.rb', line 54 def ==(other) return false unless other.is_a? self.class return false unless @address1 == other.address1 return false unless @address2 == other.address2 return false unless @address3 == other.address3 return false unless @locality == other.locality return false unless @administrative_area == other.administrative_area return false unless @postal_code == other.postal_code return false unless @country_code == other.country_code return false unless @name == other.name return false unless @phone_number == other.phone_number return false unless @sorting_code == other.sorting_code true end |