Class: DirectoryInspector
- Inherits:
-
Object
- Object
- DirectoryInspector
- Defined in:
- lib/directory_inspector.rb
Overview
Copyright © 2009 Matteo Sasso
This file is part of durb.
durb is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
durb is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with durb. If not, see <www.gnu.org/licenses/>.
Instance Method Summary collapse
-
#initialize(path) ⇒ DirectoryInspector
constructor
A new instance of DirectoryInspector.
- #run ⇒ Object
Constructor Details
#initialize(path) ⇒ DirectoryInspector
Returns a new instance of DirectoryInspector.
19 20 21 22 |
# File 'lib/directory_inspector.rb', line 19 def initialize(path) @path = DirectoryNode.string_to_path(path) @filesystem = $options[:cross_filesystems] ? nil : File.stat(path).dev end |
Instance Method Details
#run ⇒ Object
24 25 26 |
# File 'lib/directory_inspector.rb', line 24 def run make_node(@path) end |