Class: Path::Backend::Mock::File

Inherits:
Node
  • Object
show all
Defined in:
lib/rubypath/backend/mock.rb

Internal Virtual File System collapse

Attributes inherited from Node

#atime, #mode, #mtime, #name, #parent, #sys

Internal Virtual File System collapse

Methods inherited from Node

#added, #path

Constructor Details

#initialize(backend, name, opts = {}) ⇒ File

Returns a new instance of File.



351
352
353
354
# File 'lib/rubypath/backend/mock.rb', line 351

def initialize(backend, name, opts = {})
  super
  self.mode = 0o666 - backend.umask
end

Instance Attribute Details

#contentObject

Returns the value of attribute content.



349
350
351
# File 'lib/rubypath/backend/mock.rb', line 349

def content
  @content
end

Instance Method Details

#lookup(_path) ⇒ Object



356
357
358
# File 'lib/rubypath/backend/mock.rb', line 356

def lookup(_path)
  nil
end