Class: InventoryManagementAndItemManagementAndOrderManagementAndPriceManagement::Strategy5
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- InventoryManagementAndItemManagementAndOrderManagementAndPriceManagement::Strategy5
- Defined in:
- lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb
Overview
Strategy5 Model.
Instance Attribute Summary collapse
-
#maximum_seller_allowed_price ⇒ Integer
TODO: Write general description for this method.
-
#minimum_seller_allowed_price ⇒ Float
TODO: Write general description for this method.
-
#repricer_strategy ⇒ String
TODO: Write general description for this method.
-
#sku ⇒ String
TODO: Write general description for this method.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(sku = nil, repricer_strategy = nil, minimum_seller_allowed_price = nil, maximum_seller_allowed_price = nil) ⇒ Strategy5
constructor
A new instance of Strategy5.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(sku = nil, repricer_strategy = nil, minimum_seller_allowed_price = nil, maximum_seller_allowed_price = nil) ⇒ Strategy5
Returns a new instance of Strategy5.
49 50 51 52 53 54 55 56 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 49 def initialize(sku = nil, repricer_strategy = nil, minimum_seller_allowed_price = nil, maximum_seller_allowed_price = nil) @sku = sku @repricer_strategy = repricer_strategy @minimum_seller_allowed_price = minimum_seller_allowed_price @maximum_seller_allowed_price = maximum_seller_allowed_price end |
Instance Attribute Details
#maximum_seller_allowed_price ⇒ Integer
TODO: Write general description for this method
27 28 29 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 27 def maximum_seller_allowed_price @maximum_seller_allowed_price end |
#minimum_seller_allowed_price ⇒ Float
TODO: Write general description for this method
23 24 25 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 23 def minimum_seller_allowed_price @minimum_seller_allowed_price end |
#repricer_strategy ⇒ String
TODO: Write general description for this method
19 20 21 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 19 def repricer_strategy @repricer_strategy end |
#sku ⇒ String
TODO: Write general description for this method
15 16 17 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 15 def sku @sku end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 59 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. sku = hash.key?('sku') ? hash['sku'] : nil repricer_strategy = hash.key?('repricerStrategy') ? hash['repricerStrategy'] : nil minimum_seller_allowed_price = hash.key?('minimumSellerAllowedPrice') ? hash['minimumSellerAllowedPrice'] : nil maximum_seller_allowed_price = hash.key?('maximumSellerAllowedPrice') ? hash['maximumSellerAllowedPrice'] : nil # Create object from extracted values. Strategy5.new(sku, repricer_strategy, minimum_seller_allowed_price, maximum_seller_allowed_price) end |
.names ⇒ Object
A mapping from model property names to API property names.
30 31 32 33 34 35 36 37 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 30 def self.names @_hash = {} if @_hash.nil? @_hash['sku'] = 'sku' @_hash['repricer_strategy'] = 'repricerStrategy' @_hash['minimum_seller_allowed_price'] = 'minimumSellerAllowedPrice' @_hash['maximum_seller_allowed_price'] = 'maximumSellerAllowedPrice' @_hash end |
.nullables ⇒ Object
An array for nullable fields
45 46 47 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 45 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
40 41 42 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 40 def self.optionals [] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
87 88 89 90 91 92 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 87 def inspect class_name = self.class.name.split('::').last "<#{class_name} sku: #{@sku.inspect}, repricer_strategy: #{@repricer_strategy.inspect},"\ " minimum_seller_allowed_price: #{@minimum_seller_allowed_price.inspect},"\ " maximum_seller_allowed_price: #{@maximum_seller_allowed_price.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
79 80 81 82 83 84 |
# File 'lib/inventory_management_and_item_management_and_order_management_and_price_management/models/strategy5.rb', line 79 def to_s class_name = self.class.name.split('::').last "<#{class_name} sku: #{@sku}, repricer_strategy: #{@repricer_strategy},"\ " minimum_seller_allowed_price: #{@minimum_seller_allowed_price},"\ " maximum_seller_allowed_price: #{@maximum_seller_allowed_price}>" end |