Class: Qti::V1::Models::Numerics::ExactMatch

Inherits:
ScoringBase
  • Object
show all
Defined in:
lib/qti/v1/models/numerics/exact_match.rb

Instance Method Summary collapse

Methods inherited from ScoringBase

#equal_node, #gt_node, #gte_node, #initialize, #lte_node

Constructor Details

This class inherits a constructor from Qti::V1::Models::Numerics::ScoringBase

Instance Method Details

#scoring_dataObject



6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/qti/v1/models/numerics/exact_match.rb', line 6

def scoring_data
  return unless valid?
  Struct.new(
    :id,
    :type,
    :value
  ).new(
    equal_node.attributes['respident']&.value,
    'exactResponse',
    equal_node.content
  )
end