Class: Fixturex::VimgrepTreeFormatter

Inherits:
Object
  • Object
show all
Defined in:
lib/fixturex/vimgrep_tree_formatter.rb

Instance Method Summary collapse

Constructor Details

#initialize(tree, stdout = $stdout) ⇒ VimgrepTreeFormatter

Returns a new instance of VimgrepTreeFormatter.



5
6
7
8
# File 'lib/fixturex/vimgrep_tree_formatter.rb', line 5

def initialize(tree, stdout = $stdout)
  @tree = tree
  @stdout = stdout
end

Instance Method Details



10
11
12
# File 'lib/fixturex/vimgrep_tree_formatter.rb', line 10

def print
  print_entry(@tree, '', file_address_lengths(@tree).max)
end