Class Rex::JobContainer
In: lib/rex/job_container.rb
Parent: Hash

This class contains zero or more abstract jobs that can be enumerated and stopped in a generic fashion. This is used to provide a mechanism for keeping track of arbitrary contexts that may or may not require a dedicated thread.

Methods

Public Class methods

Public Instance methods

Adds an already running task as a symbolic job to the container.

Removes a job that was previously running. This is typically called when a job completes its task.

Starts a background job that doesn‘t call the cleanup routine or run the run_proc in its own thread. Rather, the run_proc is called immediately and the clean_proc is never called until the job is removed from the job container.

Starts a job using the supplied name and run/clean procedures.

Stops the job with the supplied name and forces it to cleanup. Stopping the job also leads to its removal.

[Validate]