Class: Google::Apis::MonitoringV3::Metric
- Inherits:
- 
      Object
      
        - Object
- Google::Apis::MonitoringV3::Metric
 
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/monitoring_v3/classes.rb,
 generated/google/apis/monitoring_v3/representations.rb,
 generated/google/apis/monitoring_v3/representations.rb
Overview
A specific metric, identified by specifying values for all of the labels of a MetricDescriptor.
Instance Attribute Summary collapse
- 
  
    
      #labels  ⇒ Hash<String,String> 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    The set of label values that uniquely identify this metric. 
- 
  
    
      #type  ⇒ String 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    An existing metric type, see google.api.MetricDescriptor. 
Instance Method Summary collapse
- 
  
    
      #initialize(**args)  ⇒ Metric 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of Metric. 
- 
  
    
      #update!(**args)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    Update properties of this object. 
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ Metric
Returns a new instance of Metric
| 1546 1547 1548 | # File 'generated/google/apis/monitoring_v3/classes.rb', line 1546 def initialize(**args) update!(**args) end | 
Instance Attribute Details
#labels ⇒ Hash<String,String>
The set of label values that uniquely identify this metric. All labels listed
in the MetricDescriptor must be assigned values.
Corresponds to the JSON property labels
| 1538 1539 1540 | # File 'generated/google/apis/monitoring_v3/classes.rb', line 1538 def labels @labels end | 
#type ⇒ String
An existing metric type, see google.api.MetricDescriptor. For example, custom.
googleapis.com/invoice/paid/amount.
Corresponds to the JSON property type
| 1544 1545 1546 | # File 'generated/google/apis/monitoring_v3/classes.rb', line 1544 def type @type end | 
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
| 1551 1552 1553 1554 | # File 'generated/google/apis/monitoring_v3/classes.rb', line 1551 def update!(**args) @labels = args[:labels] if args.key?(:labels) @type = args[:type] if args.key?(:type) end |