--- !ruby/object:RI::ClassDescription 
attributes: 
- !ruby/object:RI::Attribute 
  comment: 
  name: dir
  rw: R
- !ruby/object:RI::Attribute 
  comment: 
  name: multiple
  rw: R
- !ruby/object:RI::Attribute 
  comment: 
  name: number
  rw: R
- !ruby/object:RI::Attribute 
  comment: 
  name: progname
  rw: R
class_methods: 
- !ruby/object:RI::MethodSummary 
  name: existing
- !ruby/object:RI::MethodSummary 
  name: find_files
- !ruby/object:RI::MethodSummary 
  name: new
comment: 
- !ruby/struct:SM::Flow::H 
  level: 3
  text: What is a Pid-File?
- !ruby/struct:SM::Flow::P 
  body: A <em>Pid-File</em> is a file containing the <em>process identification number</em> (pid) that is stored in a well-defined location of the filesystem thus allowing other programs to find out the pid of a running script.
- !ruby/struct:SM::Flow::P 
  body: Daemons needs the pid of the scripts that are currently running in the background to send them so called <em>signals</em>. Daemons uses the <tt>TERM</tt> signal to tell the script to exit when you issue a <tt>stop</tt> command.
- !ruby/struct:SM::Flow::H 
  level: 3
  text: How does a Pid-File look like?
- !ruby/struct:SM::Flow::P 
  body: "Pid-Files generated by Daemons have to following format:"
- !ruby/struct:SM::Flow::VERB 
  body: "  &lt;scriptname&gt;.rb&lt;number&gt;.pid\n"
- !ruby/struct:SM::Flow::P 
  body: (Note that <tt>&lt;number&gt;</tt> is omitted if only one instance of the script can run at any time)
- !ruby/struct:SM::Flow::P 
  body: Each file just contains one line with the pid as string (for example <tt>6432</tt>).
- !ruby/struct:SM::Flow::H 
  level: 3
  text: Where are Pid-Files stored?
- !ruby/struct:SM::Flow::P 
  body: "Daemons is configurable to store the Pid-Files relative to three different locations:"
- !ruby/object:SM::Flow::LIST 
  contents: 
  - !ruby/struct:SM::Flow::LI 
    label: "1."
    body: in a directory relative to the directory where the script (the one that is supposed to run as a daemon) resides (<tt>:script</tt> option for <tt>:dir_mode</tt>)
  - !ruby/struct:SM::Flow::LI 
    label: "2."
    body: in a directory given by <tt>:dir</tt> (<tt>:normal</tt> option for <tt>:dir_mode</tt>)
  - !ruby/struct:SM::Flow::LI 
    label: "3."
    body: in the preconfigured directory <tt>/var/run</tt> (<tt>:system</tt> option for <tt>:dir_mode</tt>)
  type: :NUMBER
constants: []

full_name: Daemons::PidFile
includes: []

instance_methods: 
- !ruby/object:RI::MethodSummary 
  name: cleanup
- !ruby/object:RI::MethodSummary 
  name: exists?
- !ruby/object:RI::MethodSummary 
  name: filename
- !ruby/object:RI::MethodSummary 
  name: pid
- !ruby/object:RI::MethodSummary 
  name: pid=
name: PidFile
superclass: Pid
