class RubyIndexer::PrefixTree::Node Constants >Value Attributes children (attr_reader) key (attr_reader) leaf (attr_accessor) parent (attr_reader) value (attr_accessor) Public Class Methods new(key, value, parent = nil) Show source # File lib/ruby_indexer/lib/ruby_indexer/prefix_tree.rb, line 132 def initialize(key, value, parent = nil) @key = key @value = value @parent = parent @children = {} @leaf = false end Public Instance Methods collect() Show source # File lib/ruby_indexer/lib/ruby_indexer/prefix_tree.rb, line 141 def collect result = [] result << @value if @leaf @children.each_value do |node| result.concat(node.collect) end result end