Class: Google::Apis::ContentV2_1::RepricingRuleStatsBasedRule

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/content_v2_1/classes.rb,
lib/google/apis/content_v2_1/representations.rb,
lib/google/apis/content_v2_1/representations.rb

Overview

Definition of stats based rule.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ RepricingRuleStatsBasedRule

Returns a new instance of RepricingRuleStatsBasedRule.



11850
11851
11852
# File 'lib/google/apis/content_v2_1/classes.rb', line 11850

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

Instance Attribute Details

#percentage_deltaFixnum

The percent change against the price target. Valid from 0 to 100 inclusively. Corresponds to the JSON property percentageDelta

Returns:

  • (Fixnum)


11841
11842
11843
# File 'lib/google/apis/content_v2_1/classes.rb', line 11841

def percentage_delta
  @percentage_delta
end

#price_deltaString

The price delta against the above price target. A positive value means the price should be adjusted to be above statistical measure, and a negative value means below. Currency code must not be included. Corresponds to the JSON property priceDelta

Returns:

  • (String)


11848
11849
11850
# File 'lib/google/apis/content_v2_1/classes.rb', line 11848

def price_delta
  @price_delta
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



11855
11856
11857
11858
# File 'lib/google/apis/content_v2_1/classes.rb', line 11855

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