Class: Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductCatalogItemExactPrice

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

Overview

Exact product price.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRecommendationengineV1beta1ProductCatalogItemExactPrice

Returns a new instance of GoogleCloudRecommendationengineV1beta1ProductCatalogItemExactPrice.



1245
1246
1247
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1245

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

Instance Attribute Details

#display_priceFloat

Optional. Display price of the product. Corresponds to the JSON property displayPrice

Returns:

  • (Float)


1237
1238
1239
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1237

def display_price
  @display_price
end

#original_priceFloat

Optional. Price of the product without any discount. If zero, by default set to be the 'displayPrice'. Corresponds to the JSON property originalPrice

Returns:

  • (Float)


1243
1244
1245
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1243

def original_price
  @original_price
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1250
1251
1252
1253
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1250

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