Class: Google::Apis::MerchantapiProductsV1beta::ProductDimension
- Inherits:
-
Object
- Object
- Google::Apis::MerchantapiProductsV1beta::ProductDimension
- 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 dimension of the product.
Instance Attribute Summary collapse
-
#unit ⇒ String
Required.
-
#value ⇒ Float
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ ProductDimension
constructor
A new instance of ProductDimension.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ ProductDimension
Returns a new instance of ProductDimension.
1328 1329 1330 |
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1328 def initialize(**args) update!(**args) end |
Instance Attribute Details
#unit ⇒ String
Required. The dimension units. Acceptable values are: * "in
" * "cm
"
Corresponds to the JSON property unit
1320 1321 1322 |
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1320 def unit @unit end |
#value ⇒ Float
Required. The dimension value represented as a number. The value can have a
maximum precision of four decimal places.
Corresponds to the JSON property value
1326 1327 1328 |
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1326 def value @value end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1333 1334 1335 1336 |
# File 'lib/google/apis/merchantapi_products_v1beta/classes.rb', line 1333 def update!(**args) @unit = args[:unit] if args.key?(:unit) @value = args[:value] if args.key?(:value) end |