Class: Analyzer

Inherits:
Object
  • Object
show all
Defined in:
lib/mikras_utils/rls/analyzer.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(spec) ⇒ Analyzer

Returns a new instance of Analyzer.



6
7
8
# File 'lib/mikras_utils/rls/analyzer.rb', line 6

def initialize(spec)
  @spec = spec
end

Instance Attribute Details

#specObject (readonly)

Returns the value of attribute spec.



3
4
5
# File 'lib/mikras_utils/rls/analyzer.rb', line 3

def spec
  @spec
end

Class Method Details

.analyze(spec) ⇒ Object



17
18
19
# File 'lib/mikras_utils/rls/analyzer.rb', line 17

def self.analyze(spec)
  self.new(spec).analyze
end

Instance Method Details

#analyzeObject



10
11
12
13
14
15
# File 'lib/mikras_utils/rls/analyzer.rb', line 10

def analyze
  interpolate
  expand_rules
  merge_rules
  spec
end

#varsObject



4
# File 'lib/mikras_utils/rls/analyzer.rb', line 4

def vars = spec.variables