Sha256: 21a427c1cc1999caf218a24ff54174f1bbfd4ccd56f68ba8782e9e742f0259de

Contents?: true

Size: 374 Bytes

Versions: 5

Compression:

Stored size: 374 Bytes

Contents

# -*- coding: utf-8 -*-
module TreeVisitor
  #
  # Visitor for DirTreeWalker
  # Prints the node at enter
  # TODO: join this con PrintTreeNodeVisitor
  class PrintDirTreeVisitor # < BasicTreeNodeVisitor

    def enter_node( pathname )
      puts pathname
    end

    def exit_node( pathname )
    end

    def visit_leaf( pathname )
      puts pathname
    end

  end
end

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
tree.rb-0.3.0 lib/treevisitor/visitors/print_dir_tree_visitor.rb
treevisitor-0.2.3 lib/treevisitor/visitors/print_dir_tree_visitor.rb
treevisitor-0.2.2 lib/treevisitor/visitors/print_dir_tree_visitor.rb
treevisitor-0.2.1 lib/treevisitor/visitors/print_dir_tree_visitor.rb
treevisitor-0.2.0 lib/treevisitor/visitors/print_dir_tree_visitor.rb