Class: Crystalball::MapGenerator::ParserStrategy::Processor

Inherits:
Object
  • Object
show all
Defined in:
lib/crystalball/map_generator/parser_strategy/processor.rb

Overview

Parses the given source files and adds the class and module definitions to the ‘consts_defined` array.

Instance Method Summary collapse

Instance Method Details

#consts_defined_in(path) ⇒ Object



11
12
13
14
15
16
# File 'lib/crystalball/map_generator/parser_strategy/processor.rb', line 11

def consts_defined_in(path)
  self.current_scope = nil
  self.consts_defined = []
  parse_and_process(path)
  consts_defined
end

#consts_interacted_with_in(path) ⇒ Object



18
19
20
21
22
23
# File 'lib/crystalball/map_generator/parser_strategy/processor.rb', line 18

def consts_interacted_with_in(path)
  self.current_scope = nil
  self.consts_interacted_with = []
  parse_and_process(path)
  consts_interacted_with
end