class TFW::State
Singleton class to keep the stack
Public Class Methods
new()
click to toggle source
# File lib/tfw/state.rb, line 8 def initialize @stack = TFDSL::Stack.new end
Public Instance Methods
reset()
click to toggle source
# File lib/tfw/state.rb, line 17 def reset @stack = TFDSL::Stack.new end
stack(&block)
click to toggle source
# File lib/tfw/state.rb, line 12 def stack(&block) @stack.instance_eval(&block) if block_given? @stack end