Class: Moov::Models::Components::CreateProductOption

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Includes:
Crystalline::MetadataFields
Defined in:
lib/moov/models/components/createproductoption.rb

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(name:, description: nil, price_modifier: nil, images: nil) ⇒ CreateProductOption

Returns a new instance of CreateProductOption.



29
30
31
32
33
34
# File 'lib/moov/models/components/createproductoption.rb', line 29

def initialize(name:, description: nil, price_modifier: nil, images: nil)
  @name = name
  @description = description
  @price_modifier = price_modifier
  @images = images
end

Instance Method Details

#==(other) ⇒ Object



37
38
39
40
41
42
43
44
# File 'lib/moov/models/components/createproductoption.rb', line 37

def ==(other)
  return false unless other.is_a? self.class
  return false unless @name == other.name
  return false unless @description == other.description
  return false unless @price_modifier == other.price_modifier
  return false unless @images == other.images
  true
end