Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Job

A job executed in a JobController, grouping one or several process.

The job life cycle can be controlled with the {@link Job#run}, {@link Job#resume} and {@link Job#suspend} and {@link Job#interrupt} methods.

Hierarchy

  • Job

Index

Methods

id

  • id(): number
  • Returns number

interrupt

  • interrupt(): boolean
  • Attempt to interrupt the job.

    Returns boolean

lastStopped

  • lastStopped(): number
  • Returns number

line

  • line(): string
  • Returns string

process

  • Returns Process

resume

  • resume(): Job
  • resume(foreground: boolean): Job
  • Resume the job to foreground.

    Returns Job

  • Resume the job.

    Parameters

    • foreground: boolean

    Returns Job

run

  • Run the job, before running the job a must be set.

    Returns Job

setSession

  • Set a session on the job.

    Parameters

    Returns Job

setTty

  • Set a tty on the job.

    Parameters

    Returns Job

status

  • Returns ExecStatus

statusUpdateHandler

  • Set an handler called when the job terminates.

    Parameters

    Returns Job

suspend

  • suspend(): Job
  • Resume the job.

    Returns Job

terminate

  • terminate(): void
  • Terminate the job.

    Returns void

toBackground

  • toBackground(): Job
  • Send the job to background.

    Returns Job

toForeground

  • toForeground(): Job
  • Send the job to foreground.

    Returns Job

Generated using TypeDoc