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.



12145
12146
12147
# File 'lib/google/apis/content_v2_1/classes.rb', line 12145

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)


12136
12137
12138
# File 'lib/google/apis/content_v2_1/classes.rb', line 12136

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)


12143
12144
12145
# File 'lib/google/apis/content_v2_1/classes.rb', line 12143

def price_delta
  @price_delta
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



12150
12151
12152
12153
# File 'lib/google/apis/content_v2_1/classes.rb', line 12150

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