Class: Analyst::Entities::Pair

Inherits:
Entity
  • Object
show all
Defined in:
lib/analyst/entities/pair.rb

Instance Attribute Summary

Attributes inherited from Entity

#ast, #parent

Instance Method Summary collapse

Methods inherited from Entity

#classes, #conditionals, #constant_assignments, #constants, #file_path, #full_name, handles_node, #hashes, #initialize, #inspect, #line_number, #location, #method_calls, #methods, #modules, process, #source, #strings, #top_level_classes, #top_level_constant_assignments, #top_level_constants, #top_level_modules, #variables

Constructor Details

This class inherits a constructor from Analyst::Entities::Entity

Instance Method Details

#keyObject



8
9
10
# File 'lib/analyst/entities/pair.rb', line 8

def key
  @key ||= process_node(ast.children[0])
end

#valueObject



12
13
14
# File 'lib/analyst/entities/pair.rb', line 12

def value
  @value ||= process_node(ast.children[1])
end