# File lib/fssm/tree.rb, line 3 def initialize @children = {} end
# File lib/fssm/tree.rb, line 9 def child(segment) @children["#{segment}"] end
# File lib/fssm/tree.rb, line 13 def child!(segment) (@children["#{segment}"] ||= Node.new) end
# File lib/fssm/tree.rb, line 17 def has_child?(segment) @children.has_key?("#{segment}") end
# File lib/fssm/tree.rb, line 21 def remove_child(segment) @children.delete("#{segment}") end
# File lib/fssm/tree.rb, line 25 def remove_children @children.clear end