Class: Moult::Gate::Evaluation::RuleOutcome

Inherits:
Struct
  • Object
show all
Defined in:
lib/moult/gate/evaluation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#evaluatedObject

Returns the value of attribute evaluated

Returns:

  • (Object)

    the current value of evaluated



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def evaluated
  @evaluated
end

#findingsObject

Returns the value of attribute findings

Returns:

  • (Object)

    the current value of findings



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def findings
  @findings
end

#observedObject

Returns the value of attribute observed

Returns:

  • (Object)

    the current value of observed



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def observed
  @observed
end

#passedObject

Returns the value of attribute passed

Returns:

  • (Object)

    the current value of passed



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def passed
  @passed
end

#reasonsObject

Returns the value of attribute reasons

Returns:

  • (Object)

    the current value of reasons



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def reasons
  @reasons
end

#ruleObject

Returns the value of attribute rule

Returns:

  • (Object)

    the current value of rule



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def rule
  @rule
end

#thresholdObject

Returns the value of attribute threshold

Returns:

  • (Object)

    the current value of threshold



49
50
51
# File 'lib/moult/gate/evaluation.rb', line 49

def threshold
  @threshold
end

Instance Method Details

#to_hObject



50
51
52
53
54
55
56
57
58
59
60
# File 'lib/moult/gate/evaluation.rb', line 50

def to_h
  {
    rule: rule,
    evaluated: evaluated,
    observed: observed,
    threshold: threshold,
    passed: passed,
    reasons: reasons.map(&:to_h),
    findings: findings.map(&:to_h)
  }
end