Class PidFile
In: lib/pidfile.rb
Parent: Object

Methods

alive?   locktime   new   pid   pid   pidfile_exists?   pidfile_exists?   release   running?  

Classes and Modules

Class PidFile::DuplicateProcessError

Constants

VERSION = '0.3.0'
DEFAULT_OPTIONS = { :pidfile => File.basename($0, File.extname($0)) + ".pid", :piddir => '/tmp', }

Attributes

piddir  [R] 
pidfile  [R] 
pidpath  [R] 

Public Class methods

Returns the PID, if any, of the instantiating process

class method for determining the existence of pidfile

boolean stating whether the calling program is already running

Public Instance methods

Boolean stating whether this process is alive and running

returns the modification time of the pidfile

Returns the PID, if any, of the instantiating process

does the pidfile exist?

unlock and remove the pidfile. Sets pid to nil

[Validate]