Class: Ast::Merge::TieBreakMatchingReport

Inherits:
Struct
  • Object
show all
Defined in:
lib/ast/merge.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#diagnosticsObject

Returns the value of attribute diagnostics

Returns:

  • (Object)

    the current value of diagnostics



682
683
684
# File 'lib/ast/merge.rb', line 682

def diagnostics
  @diagnostics
end

#matchesObject

Returns the value of attribute matches

Returns:

  • (Object)

    the current value of matches



682
683
684
# File 'lib/ast/merge.rb', line 682

def matches
  @matches
end

#matching_idObject

Returns the value of attribute matching_id

Returns:

  • (Object)

    the current value of matching_id



682
683
684
# File 'lib/ast/merge.rb', line 682

def matching_id
  @matching_id
end

#scope_pathObject

Returns the value of attribute scope_path

Returns:

  • (Object)

    the current value of scope_path



682
683
684
# File 'lib/ast/merge.rb', line 682

def scope_path
  @scope_path
end

#strategyObject

Returns the value of attribute strategy

Returns:

  • (Object)

    the current value of strategy



682
683
684
# File 'lib/ast/merge.rb', line 682

def strategy
  @strategy
end

#tie_break_rulesObject

Returns the value of attribute tie_break_rules

Returns:

  • (Object)

    the current value of tie_break_rules



682
683
684
# File 'lib/ast/merge.rb', line 682

def tie_break_rules
  @tie_break_rules
end

Instance Method Details

#to_hObject



684
685
686
687
688
689
690
691
692
693
# File 'lib/ast/merge.rb', line 684

def to_h
  {
    matching_id: matching_id,
    strategy: strategy,
    scope_path: scope_path,
    tie_break_rules: tie_break_rules || [],
    matches: (matches || []).map(&:to_h),
    diagnostics: diagnostics || []
  }
end