Class: PlexSymlinker::Symlink

Inherits:
Object
  • Object
show all
Defined in:
lib/plex_symlinker/symlink.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ Symlink

Returns a new instance of Symlink.



5
6
7
# File 'lib/plex_symlinker/symlink.rb', line 5

def initialize(path)
  @path = path
end

Instance Attribute Details

#pathObject (readonly)

Returns the value of attribute path.



3
4
5
# File 'lib/plex_symlinker/symlink.rb', line 3

def path
  @path
end

Instance Method Details

#targetObject



9
10
11
# File 'lib/plex_symlinker/symlink.rb', line 9

def target
  File.readlink(path)
end