Class: Datadog::DI::EvaluationFailure Private

Inherits:
Object
  • Object
show all
Defined in:
lib/datadog/di/evaluation_failure.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

An expression evaluation failure reported in a snapshot's evaluation errors: the expression that failed and the error description.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(expr:, message:) ⇒ void

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Initializes the failure.

Parameters:

  • expr (String) —

    name of the capture expression, or source of the condition or template expression, that failed to evaluate or serialize

  • message (String) —

    error description of the failed evaluation



14
15
16
17
# File 'lib/datadog/di/evaluation_failure.rb', line 14

def initialize(expr:, message:)
  @expr = expr
  @message = message
end

Instance Attribute Details

#expr ⇒ String (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

The name of the capture expression, or the source of the condition or template expression, that failed to evaluate or serialize.

Returns:

  • (String)


22
23
24
# File 'lib/datadog/di/evaluation_failure.rb', line 22

def expr
  @expr
end

#message ⇒ String (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns the error description of the failed evaluation.

Returns:

  • (String) —

    the error description of the failed evaluation



25
26
27
# File 'lib/datadog/di/evaluation_failure.rb', line 25

def message
  @message
end