Class: Inferno::DSL::FHIREvaluation::EvaluationContext

Inherits:
Object
  • Object
show all
Defined in:
lib/inferno/dsl/fhir_evaluation/evaluation_context.rb

Overview

EvaluationContext is a wrapper class around the concepts needed to perform an evaluation: - The IG used as the basis for evaluation - The data being evaluated - A summary/characterization of the data - Evaluation results

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(ig, data, config) ⇒ EvaluationContext

rubocop:disable Naming/MethodParameterName



12
13
14
15
16
17
# File 'lib/inferno/dsl/fhir_evaluation/evaluation_context.rb', line 12

def initialize(ig, data, config) # rubocop:disable Naming/MethodParameterName
  @ig = ig
  @data = data
  @results = []
  @config = config
end

Instance Attribute Details

#configObject (readonly)

Returns the value of attribute config.



10
11
12
# File 'lib/inferno/dsl/fhir_evaluation/evaluation_context.rb', line 10

def config
  @config
end

#dataObject (readonly)

Returns the value of attribute data.



10
11
12
# File 'lib/inferno/dsl/fhir_evaluation/evaluation_context.rb', line 10

def data
  @data
end

#igObject (readonly)

Returns the value of attribute ig.



10
11
12
# File 'lib/inferno/dsl/fhir_evaluation/evaluation_context.rb', line 10

def ig
  @ig
end

#resultsObject (readonly)

Returns the value of attribute results.



10
11
12
# File 'lib/inferno/dsl/fhir_evaluation/evaluation_context.rb', line 10

def results
  @results
end

Instance Method Details

#add_result(result) ⇒ Object



19
20
21
# File 'lib/inferno/dsl/fhir_evaluation/evaluation_context.rb', line 19

def add_result(result)
  results.push result
end