Class: Delfos::FileSystem::Relation::RelatedPaths

Inherits:
Object
  • Object
show all
Defined in:
lib/delfos/file_system/relation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ RelatedPaths

Returns a new instance of RelatedPaths.



89
90
91
# File 'lib/delfos/file_system/relation.rb', line 89

def initialize(path)
  @path = path
end

Instance Attribute Details

#pathObject (readonly)

Returns the value of attribute path.



87
88
89
# File 'lib/delfos/file_system/relation.rb', line 87

def path
  @path
end

Instance Method Details

#directoriesObject



97
98
99
# File 'lib/delfos/file_system/relation.rb', line 97

def directories
  all.select(&:directory?)
end

#filesObject



93
94
95
# File 'lib/delfos/file_system/relation.rb', line 93

def files
  all.select(&:file?)
end