Class: Google::Apis::MerchantapiProductsV1beta::ShippingDimension

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 ShippingDimension of the product.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ShippingDimension

Returns a new instance of ShippingDimension.



2027
2028
2029
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 2027

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

Instance Attribute Details

#unitString

The unit of value. Corresponds to the JSON property unit

Returns:

  • (String)


2020
2021
2022
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 2020

def unit
  @unit
end

#valueFloat

The dimension of the product used to calculate the shipping cost of the item. Corresponds to the JSON property value

Returns:

  • (Float)


2025
2026
2027
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 2025

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2032
2033
2034
2035
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 2032

def update!(**args)
  @unit = args[:unit] if args.key?(:unit)
  @value = args[:value] if args.key?(:value)
end