Class: Journey::NFA::Builder

Inherits:
Object
  • Object
show all
Defined in:
lib/journey/nfa/builder.rb

Instance Method Summary collapse

Constructor Details

#initialize(ast) ⇒ Builder

Returns a new instance of Builder.



63
64
65
# File 'lib/journey/nfa/builder.rb', line 63

def initialize ast
  @ast = ast
end

Instance Method Details

#transition_tableObject



67
68
69
70
71
# File 'lib/journey/nfa/builder.rb', line 67

def transition_table
  tt = TransitionTable.new
  Visitor.new(tt).accept @ast
  tt
end