Class | EventMachine::ProcessWatch
In: | lib/em/process_watch.rb
Parent: | Connection

This is subclassed from EventMachine::Connection for use with the process monitoring API. Read the documentation on the instance methods of this class, and for a full explanation see EventMachine.watch_process.

### Methods

pid process_exited process_forked stop_watching

### Public Instance methods

pid()

Returns the pid that EventMachine::watch_process was originally called with.

process_exited()

Should be redefined with the user‘s custom callback that will be fired when the process exits.

stop_watching is called automatically after this callback

process_forked()

Should be redefined with the user‘s custom callback that will be fired when the prcess is forked.

There is currently not an easy way to get the pid of the forked child.

stop_watching()

Discontinue monitoring of the process. This will be called automatically when a process dies. User code may call it as well.

[Validate]