Class: Moult::DuplicationReport::Finding
- Inherits:
-
Struct
- Object
- Struct
- Moult::DuplicationReport::Finding
- Defined in:
- lib/moult/duplication_report.rb
Overview
A confidence-graded clone group. Carries its reasons so no claim is made
without a recorded justification. clone_group ("
Instance Attribute Summary collapse
-
#clone_group ⇒ Object
Returns the value of attribute clone_group.
-
#confidence ⇒ Object
Returns the value of attribute confidence.
-
#kind ⇒ Object
Returns the value of attribute kind.
-
#mass ⇒ Object
Returns the value of attribute mass.
-
#node_type ⇒ Object
Returns the value of attribute node_type.
-
#occurrences ⇒ Object
Returns the value of attribute occurrences.
-
#reasons ⇒ Object
Returns the value of attribute reasons.
Instance Method Summary collapse
Instance Attribute Details
#clone_group ⇒ Object
Returns the value of attribute clone_group
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def clone_group @clone_group end |
#confidence ⇒ Object
Returns the value of attribute confidence
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def confidence @confidence end |
#kind ⇒ Object
Returns the value of attribute kind
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def kind @kind end |
#mass ⇒ Object
Returns the value of attribute mass
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def mass @mass end |
#node_type ⇒ Object
Returns the value of attribute node_type
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def node_type @node_type end |
#occurrences ⇒ Object
Returns the value of attribute occurrences
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def occurrences @occurrences end |
#reasons ⇒ Object
Returns the value of attribute reasons
27 28 29 |
# File 'lib/moult/duplication_report.rb', line 27 def reasons @reasons end |
Instance Method Details
#to_h ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/moult/duplication_report.rb', line 28 def to_h { category: Duplication::Confidence::CATEGORY, confidence: confidence, kind: kind.to_s, node_type: node_type, mass: mass, clone_group: clone_group, reasons: reasons.map(&:to_h), occurrences: occurrences.map(&:to_h) } end |