Class: Anamo::Fstree::Traverser
- Inherits:
-
Object
- Object
- Anamo::Fstree::Traverser
- Defined in:
- lib/anamo/fstree/thor.rb
Instance Attribute Summary collapse
-
#base_path ⇒ Object
readonly
Returns the value of attribute base_path.
Instance Method Summary collapse
- #compute ⇒ Object
-
#initialize(base_path = '/', writer = Writer.new, max_depth = 2, exclusions = []) ⇒ Traverser
constructor
A new instance of Traverser.
Constructor Details
#initialize(base_path = '/', writer = Writer.new, max_depth = 2, exclusions = []) ⇒ Traverser
Returns a new instance of Traverser.
56 57 58 59 60 61 |
# File 'lib/anamo/fstree/thor.rb', line 56 def initialize base_path = '/', writer = Writer.new, max_depth = 2, exclusions = [] @max_depth = max_depth @base_path = base_path @writer = writer @exclusions = exclusions end |
Instance Attribute Details
#base_path ⇒ Object (readonly)
Returns the value of attribute base_path.
54 55 56 |
# File 'lib/anamo/fstree/thor.rb', line 54 def base_path @base_path end |
Instance Method Details
#compute ⇒ Object
63 64 65 66 |
# File 'lib/anamo/fstree/thor.rb', line 63 def compute walk_path @base_path @writer.close end |