# Class JobInfoImpl

java.lang.Object
com.sun.grid.drmaa.JobInfoImpl

All Implemented Interfaces:
  `JobInfo`

public class JobInfoImpl extends Object implements JobInfo
This class provides information about a completed Grid Engine job.

Since:
  0.5 version 1.0
See Also:
  - `JobInfo`

## Method Summary

Modifier and Type
Method
Description
`int`
`getExitStatus()`
If hasExited() returns true, this function returns the exit code that the job passed to _exit() (see exit(2)) or exit(3C)), or the value that the child process returned from its main method.
`String`
`getJobId()`
Get the id of the finished job.
`Map`
`getResourceUsage()`
Get the resource usage data for the finished job.
`String`
`getTerminatingSignal()`
If hasSignaled() returns true, this method returns a representation of the signal that caused the termination of the job.
`boolean`
`hasCoreDump()`
If hasSignaled() returns `true`, this function returns `true` if a core image of the terminated job was created.
`boolean`
`hasExited()`
Returns `true` if the job terminated normally.
`boolean`
`hasSignaled()`
Returns `true` if the job terminated due to the receipt of a signal.
`boolean`
`wasAborted()`
Returns `true` if the job ended before entering the running state.

### Methods inherited from class Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Method Details

### getExitStatus

public int getExitStatus()
Description copied from interface: `JobInfo`
If hasExited() returns true, this function returns the exit code that the job passed to _exit() (see exit(2)) or exit(3C)), or the value that the child process returned from its main method.

Specified by:
  `getExitStatus` in interface `JobInfo`
Returns:
  the exit code for the job
See Also:
  - `JobInfo.hasExited()`

### getTerminatingSignal

public String getTerminatingSignal()
If hasSignaled() returns true, this method returns a representation of the signal that caused the termination of the job. For signals declared by POSIX or otherwise known to Grid Engine, the symbolic names are returned (e.g., SIGABRT, SIGALRM).
For signals not known by Grid Engine, the string "unknown signal" is returned.

Specified by:
  `getTerminatingSignal` in interface `JobInfo`
Returns:
  the name of the terminating signal
See Also:
  - `JobInfo.hasSignaled()`

### hasCoreDump

public boolean hasCoreDump()
Description copied from interface: `JobInfo`
If hasSignaled() returns `true`, this function returns `true` if a core image of the terminated job was created.

Specified by:
  `hasCoreDump` in interface `JobInfo`
Returns:
  whether a core dump image was created
See Also:
  - `JobInfo.hasSignaled()`

### hasExited

public boolean hasExited()
Description copied from interface: `JobInfo`
Returns `true` if the job terminated normally. `False` can also indicate that although the job has terminated normally, an exit status is not available, or that it is not known whether the job terminated normally. In both cases getExitStatus() will throw an IllegalStateException. `True` indicates that more detailed diagnosis can be discovered by means of getExitStatus().

Specified by:
  `hasExited` in interface `JobInfo`
Returns:
  if the job has exited
See Also:
  - `JobInfo.getExitStatus()`

### hasSignaled

public boolean hasSignaled()
Description copied from interface: `JobInfo`
Returns `true` if the job terminated due to the receipt of a signal. `False` can also indicate that although the job has terminated due to the receipt of a signal, the signal is not available, or that it is not known whether the job terminated due to the receipt of a signal. In both cases getTerminatingSignal() will throw an IllegalStateException. `True` indicates that the name of the terminating signal can be discovered by means of getTerminatingSignal().

Specified by:
  `hasSignaled` in interface `JobInfo`
Returns:
  if the job exited on a signal
See Also:
  - `JobInfo.getTerminatingSignal()`

### wasAborted

public boolean wasAborted()
Description copied from interface: `JobInfo`
Returns `true` if the job ended before entering the running state.

Specified by:
  `wasAborted` in interface `JobInfo`
Returns:
  whether the job ended before entering the running state

### getJobId

public String getJobId()
Description copied from interface: `JobInfo`
Get the id of the finished job.

Specified by:
  `getJobId` in interface `JobInfo`
Returns:
  the job id

### getResourceUsage

public Map getResourceUsage()
Description copied from interface: `JobInfo`
Get the resource usage data for the finished job. If the job finished, but no resource usage data is available, this method will return `null`.

Specified by:
  `getResourceUsage` in interface `JobInfo`
Returns:
  the resource usage data