Class: Google::Apis::MonitoringV3::JsonPathMatcher

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

Overview

Information needed to perform a JSONPath content match. Used for ContentMatcherOption::MATCHES_JSON_PATH and ContentMatcherOption:: NOT_MATCHES_JSON_PATH.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ JsonPathMatcher

Returns a new instance of JsonPathMatcher.



2190
2191
2192
# File 'lib/google/apis/monitoring_v3/classes.rb', line 2190

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

Instance Attribute Details

#json_matcherString

The type of JSONPath match that will be applied to the JSON output ( ContentMatcher.content) Corresponds to the JSON property jsonMatcher

Returns:

  • (String)


2182
2183
2184
# File 'lib/google/apis/monitoring_v3/classes.rb', line 2182

def json_matcher
  @json_matcher
end

#json_pathString

JSONPath within the response output pointing to the expected ContentMatcher:: content to match against. Corresponds to the JSON property jsonPath

Returns:

  • (String)


2188
2189
2190
# File 'lib/google/apis/monitoring_v3/classes.rb', line 2188

def json_path
  @json_path
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2195
2196
2197
2198
# File 'lib/google/apis/monitoring_v3/classes.rb', line 2195

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