Class: PyramidScheme::Lock::File

Inherits:
Base
  • Object
show all
Defined in:
lib/pyramid_scheme/lock/file.rb

Instance Method Summary collapse

Instance Method Details

#createObject



8
9
10
# File 'lib/pyramid_scheme/lock/file.rb', line 8

def create
  FileUtils.touch(server_path)
end

#destroyObject



12
13
14
# File 'lib/pyramid_scheme/lock/file.rb', line 12

def destroy
  FileUtils.rm_f(server_path)
end

#exists?Boolean

Returns:

  • (Boolean)


4
5
6
# File 'lib/pyramid_scheme/lock/file.rb', line 4

def exists?
  ::File.exists?(client_path)
end