Class: CldProvisioning::Models::Shared::MetricUsage

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Includes:
Crystalline::MetadataFields
Defined in:
lib/cld_provisioning/models/shared/metric_usage.rb

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(metric: nil, limit: nil, cycles: nil, monthly_cycles: nil) ⇒ MetricUsage

Returns a new instance of MetricUsage.



49
50
51
52
53
54
# File 'lib/cld_provisioning/models/shared/metric_usage.rb', line 49

def initialize(metric: nil, limit: nil, cycles: nil, monthly_cycles: nil)
  @metric = metric
  @limit = limit
  @cycles = cycles
  @monthly_cycles = monthly_cycles
end

Instance Method Details

#==(other) ⇒ Object



57
58
59
60
61
62
63
64
# File 'lib/cld_provisioning/models/shared/metric_usage.rb', line 57

def ==(other)
  return false unless other.is_a?(self.class)
  return false unless @metric == other.metric
  return false unless @limit == other.limit
  return false unless @cycles == other.cycles
  return false unless @monthly_cycles == other.monthly_cycles
  true
end