Class: Google::Apis::ContentV2::Address
- Inherits:
-
Object
- Object
- Google::Apis::ContentV2::Address
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/content_v2/classes.rb,
lib/google/apis/content_v2/representations.rb,
lib/google/apis/content_v2/representations.rb
Instance Attribute Summary collapse
-
#administrative_area ⇒ String
Required.
-
#city ⇒ String
Required.
-
#country ⇒ String
Required.
-
#postal_code ⇒ String
Required.
-
#street_address ⇒ String
Street-level part of the address.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Address
constructor
A new instance of Address.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Address
Returns a new instance of Address.
1540 1541 1542 |
# File 'lib/google/apis/content_v2/classes.rb', line 1540 def initialize(**args) update!(**args) end |
Instance Attribute Details
#administrative_area ⇒ String
Required. Top-level administrative subdivision of the country. For example, a
state like California ("CA") or a province like Quebec ("QC").
Corresponds to the JSON property administrativeArea
1516 1517 1518 |
# File 'lib/google/apis/content_v2/classes.rb', line 1516 def administrative_area @administrative_area end |
#city ⇒ String
Required. City, town or commune. May also include dependent localities or
sublocalities (e.g. neighborhoods or suburbs).
Corresponds to the JSON property city
1522 1523 1524 |
# File 'lib/google/apis/content_v2/classes.rb', line 1522 def city @city end |
#country ⇒ String
Required. CLDR country code(e.g. "US").
Corresponds to the JSON property country
1528 1529 1530 |
# File 'lib/google/apis/content_v2/classes.rb', line 1528 def country @country end |
#postal_code ⇒ String
Required. Postal code or ZIP (e.g. "94043"). Required.
Corresponds to the JSON property postalCode
1533 1534 1535 |
# File 'lib/google/apis/content_v2/classes.rb', line 1533 def postal_code @postal_code end |
#street_address ⇒ String
Street-level part of the address.
Corresponds to the JSON property streetAddress
1538 1539 1540 |
# File 'lib/google/apis/content_v2/classes.rb', line 1538 def street_address @street_address end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1545 1546 1547 1548 1549 1550 1551 |
# File 'lib/google/apis/content_v2/classes.rb', line 1545 def update!(**args) @administrative_area = args[:administrative_area] if args.key?(:administrative_area) @city = args[:city] if args.key?(:city) @country = args[:country] if args.key?(:country) @postal_code = args[:postal_code] if args.key?(:postal_code) @street_address = args[:street_address] if args.key?(:street_address) end |