Class: Google::Apis::RecommenderV1beta1::GoogleCloudRecommenderV1beta1CostProjection

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

Overview

Contains metadata about how much money a recommendation can save or incur.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRecommenderV1beta1CostProjection

Returns a new instance of GoogleCloudRecommenderV1beta1CostProjection.



39
40
41
# File 'generated/google/apis/recommender_v1beta1/classes.rb', line 39

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

Instance Attribute Details

#costGoogle::Apis::RecommenderV1beta1::GoogleTypeMoney

Represents an amount of money with its currency type. Corresponds to the JSON property cost



32
33
34
# File 'generated/google/apis/recommender_v1beta1/classes.rb', line 32

def cost
  @cost
end

#durationString

Duration for which this cost applies. Corresponds to the JSON property duration

Returns:

  • (String)


37
38
39
# File 'generated/google/apis/recommender_v1beta1/classes.rb', line 37

def duration
  @duration
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



44
45
46
47
# File 'generated/google/apis/recommender_v1beta1/classes.rb', line 44

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