class BehaveFun::Tree
Attributes
root[R]
Public Instance Methods
add_child(child)
click to toggle source
tree does not have children, it only contains a root
# File lib/behave_fun/tree.rb, line 36 def add_child(child) self.root = child end
as_json()
click to toggle source
# File lib/behave_fun/tree.rb, line 45 def as_json { version: 1, root: root.as_json } end
child_fail()
click to toggle source
# File lib/behave_fun/tree.rb, line 31 def child_fail fail end
child_running()
click to toggle source
# File lib/behave_fun/tree.rb, line 23 def child_running running end
child_success()
click to toggle source
# File lib/behave_fun/tree.rb, line 27 def child_success success end
context=(context)
click to toggle source
# File lib/behave_fun/tree.rb, line 14 def context=(context) @context = context @root.context = context end
dump_status()
click to toggle source
# File lib/behave_fun/tree.rb, line 52 def dump_status root.dump_status end
dup()
click to toggle source
# File lib/behave_fun/tree.rb, line 60 def dup cloned = self.class.new(params) cloned.root = root.dup cloned end
execute()
click to toggle source
# File lib/behave_fun/tree.rb, line 19 def execute root.run end
reset()
click to toggle source
Calls superclass method
BehaveFun::Task#reset
# File lib/behave_fun/tree.rb, line 40 def reset super root.reset end
restore_status(data)
click to toggle source
# File lib/behave_fun/tree.rb, line 56 def restore_status(data) root.restore_status(data) end
root=(root)
click to toggle source
# File lib/behave_fun/tree.rb, line 5 def root=(root) @root = root @root.control = self end
tree()
click to toggle source
# File lib/behave_fun/tree.rb, line 10 def tree self end