Class: Google::Apis::MerchantapiAccountsV1beta::Address

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/merchantapi_accounts_v1beta/classes.rb,
lib/google/apis/merchantapi_accounts_v1beta/representations.rb,
lib/google/apis/merchantapi_accounts_v1beta/representations.rb

Overview

Shipping address of the warehouse.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Address

Returns a new instance of Address.



570
571
572
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 570

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#administrative_areaString

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

Returns:

  • (String)


546
547
548
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 546

def administrative_area
  @administrative_area
end

#cityString

Required. City, town or commune. May also include dependent localities or sublocalities (For example neighborhoods or suburbs). Corresponds to the JSON property city

Returns:

  • (String)


552
553
554
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 552

def city
  @city
end

#postal_codeString

Required. Postal code or ZIP (For example "94043"). Corresponds to the JSON property postalCode

Returns:

  • (String)


557
558
559
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 557

def postal_code
  @postal_code
end

#region_codeString

Required. CLDR country code (For example "US"). Corresponds to the JSON property regionCode

Returns:

  • (String)


563
564
565
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 563

def region_code
  @region_code
end

#street_addressString

Street-level part of the address. For example: 111w 31st Street. Corresponds to the JSON property streetAddress

Returns:

  • (String)


568
569
570
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 568

def street_address
  @street_address
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



575
576
577
578
579
580
581
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 575

def update!(**args)
  @administrative_area = args[:administrative_area] if args.key?(:administrative_area)
  @city = args[:city] if args.key?(:city)
  @postal_code = args[:postal_code] if args.key?(:postal_code)
  @region_code = args[:region_code] if args.key?(:region_code)
  @street_address = args[:street_address] if args.key?(:street_address)
end