Class: Inttegro::Product::Dimensions

Inherits:
T::Struct
  • Object
show all
Defined in:
lib/inttegro/product/dimensions.rb

Overview

At most one of physical, digital, or custom.

This generated model is immutable. Construct it with .new, or decode a string-keyed API payload with .from_hash. #serialize produces a string-keyed hash using the original wire field names and serialized enum values.

Instance Attribute Summary collapse

Instance Attribute Details

#custom ⇒ Inttegro::Product::DimensionsCustom? (readonly)

Value of the custom field in the Inttegro API payload.

Optional in the API payload; omitted values default to nil. Wire name: custom.



38
39
40
41
42
# File 'lib/inttegro/product/dimensions.rb', line 38

class Dimensions < T::Struct
  const :physical, T.nilable(Inttegro::Product::DimensionsPhysical), default: nil
  const :digital, T.nilable(Inttegro::Product::DimensionsDigital), default: nil
  const :custom, T.nilable(Inttegro::Product::DimensionsCustom), default: nil
end

#digital ⇒ Inttegro::Product::DimensionsDigital? (readonly)

Value of the digital field in the Inttegro API payload.

Optional in the API payload; omitted values default to nil. Wire name: digital.



38
39
40
41
42
# File 'lib/inttegro/product/dimensions.rb', line 38

class Dimensions < T::Struct
  const :physical, T.nilable(Inttegro::Product::DimensionsPhysical), default: nil
  const :digital, T.nilable(Inttegro::Product::DimensionsDigital), default: nil
  const :custom, T.nilable(Inttegro::Product::DimensionsCustom), default: nil
end

#physical ⇒ Inttegro::Product::DimensionsPhysical? (readonly)

Value of the physical field in the Inttegro API payload.

Optional in the API payload; omitted values default to nil. Wire name: physical.



38
39
40
41
42
# File 'lib/inttegro/product/dimensions.rb', line 38

class Dimensions < T::Struct
  const :physical, T.nilable(Inttegro::Product::DimensionsPhysical), default: nil
  const :digital, T.nilable(Inttegro::Product::DimensionsDigital), default: nil
  const :custom, T.nilable(Inttegro::Product::DimensionsCustom), default: nil
end