Class: Google::Apis::MerchantapiProductsV1beta::Shipping

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

Overview

The Shipping of the product.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Shipping

Returns a new instance of Shipping.



1709
1710
1711
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1709

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

Instance Attribute Details

#countryString

The CLDR territory code of the country to which an item will ship. Corresponds to the JSON property country

Returns:

  • (String)


1636
1637
1638
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1636

def country
  @country
end

#location_group_nameString

The location where the shipping is applicable, represented by a location group name. Corresponds to the JSON property locationGroupName

Returns:

  • (String)


1642
1643
1644
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1642

def location_group_name
  @location_group_name
end

#location_idFixnum

The numeric ID of a location that the shipping rate applies to as defined in the AdWords API. Corresponds to the JSON property locationId

Returns:

  • (Fixnum)


1649
1650
1651
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1649

def location_id
  @location_id
end

#max_handling_timeFixnum

Maximum handling time (inclusive) between when the order is received and shipped in business days. 0 means that the order is shipped on the same day as it is received if it happens before the cut-off time. Both maxHandlingTime and maxTransitTime are required if providing shipping speeds. minHandlingTime is optional if maxHandlingTime is present. Corresponds to the JSON property maxHandlingTime

Returns:

  • (Fixnum)


1658
1659
1660
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1658

def max_handling_time
  @max_handling_time
end

#max_transit_timeFixnum

Maximum transit time (inclusive) between when the order has shipped and when it is delivered in business days. 0 means that the order is delivered on the same day as it ships. Both maxHandlingTime and maxTransitTime are required if providing shipping speeds. minTransitTime is optional if maxTransitTime is present. Corresponds to the JSON property maxTransitTime

Returns:

  • (Fixnum)


1667
1668
1669
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1667

def max_transit_time
  @max_transit_time
end

#min_handling_timeFixnum

Minimum handling time (inclusive) between when the order is received and shipped in business days. 0 means that the order is shipped on the same day as it is received if it happens before the cut-off time. minHandlingTime can only be present together with maxHandlingTime; but it is not required if maxHandlingTime is present. Corresponds to the JSON property minHandlingTime

Returns:

  • (Fixnum)


1676
1677
1678
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1676

def min_handling_time
  @min_handling_time
end

#min_transit_timeFixnum

Minimum transit time (inclusive) between when the order has shipped and when it is delivered in business days. 0 means that the order is delivered on the same day as it ships. minTransitTime can only be present together with maxTransitTime; but it is not required if maxTransitTime is present. Corresponds to the JSON property minTransitTime

Returns:

  • (Fixnum)


1684
1685
1686
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1684

def min_transit_time
  @min_transit_time
end

#postal_codeString

The postal code range that the shipping rate applies to, represented by a postal code, a postal code prefix followed by a * wildcard, a range between two postal codes or two postal code prefixes of equal length. Corresponds to the JSON property postalCode

Returns:

  • (String)


1691
1692
1693
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1691

def postal_code
  @postal_code
end

#priceGoogle::Apis::MerchantapiProductsV1beta::Price

The price represented as a number and currency. Corresponds to the JSON property price



1696
1697
1698
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1696

def price
  @price
end

#regionString

The geographic region to which a shipping rate applies. See region for more information. Corresponds to the JSON property region

Returns:

  • (String)


1702
1703
1704
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1702

def region
  @region
end

#serviceString

A free-form description of the service class or delivery speed. Corresponds to the JSON property service

Returns:

  • (String)


1707
1708
1709
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1707

def service
  @service
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1714

def update!(**args)
  @country = args[:country] if args.key?(:country)
  @location_group_name = args[:location_group_name] if args.key?(:location_group_name)
  @location_id = args[:location_id] if args.key?(:location_id)
  @max_handling_time = args[:max_handling_time] if args.key?(:max_handling_time)
  @max_transit_time = args[:max_transit_time] if args.key?(:max_transit_time)
  @min_handling_time = args[:min_handling_time] if args.key?(:min_handling_time)
  @min_transit_time = args[:min_transit_time] if args.key?(:min_transit_time)
  @postal_code = args[:postal_code] if args.key?(:postal_code)
  @price = args[:price] if args.key?(:price)
  @region = args[:region] if args.key?(:region)
  @service = args[:service] if args.key?(:service)
end