Class: Google::Apis::MonitoringV1::TemplateVariableCondition

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

Overview

A condition whose evaluation is based on the value of a template variable.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ TemplateVariableCondition

Returns a new instance of TemplateVariableCondition.



2408
2409
2410
# File 'lib/google/apis/monitoring_v1/classes.rb', line 2408

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

Instance Attribute Details

#comparatorString

Comparator to use to evaluate whether the value of the template variable matches the template_variable_value. For example, if the comparator is REGEX_FULL_MATCH, template_variable_value would contain a regex that is matched against the value of the template variable. Corresponds to the JSON property comparator

Returns:

  • (String)


2395
2396
2397
# File 'lib/google/apis/monitoring_v1/classes.rb', line 2395

def comparator
  @comparator
end

#template_variableString

The template variable whose value is evaluated. Corresponds to the JSON property templateVariable

Returns:

  • (String)


2400
2401
2402
# File 'lib/google/apis/monitoring_v1/classes.rb', line 2400

def template_variable
  @template_variable
end

#template_variable_valueString

The value to compare the template variable to. For example, if the comparator is REGEX_FULL_MATCH, this field should contain a regex. Corresponds to the JSON property templateVariableValue

Returns:

  • (String)


2406
2407
2408
# File 'lib/google/apis/monitoring_v1/classes.rb', line 2406

def template_variable_value
  @template_variable_value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2413
2414
2415
2416
2417
# File 'lib/google/apis/monitoring_v1/classes.rb', line 2413

def update!(**args)
  @comparator = args[:comparator] if args.key?(:comparator)
  @template_variable = args[:template_variable] if args.key?(:template_variable)
  @template_variable_value = args[:template_variable_value] if args.key?(:template_variable_value)
end