org.jwarp.service.work
Interface IJob

All Superinterfaces:
java.lang.Runnable
All Known Implementing Classes:
AJob

public interface IJob
extends java.lang.Runnable

This interface defines the main methods and settings a workmanager job has. Workmanager jobs are independent request for doing some work. The component to be called actually to execute the job is determined by the tool setting. The work manager tries to loacate the tool named equally and tries to execute the tool with the parameters given.


Field Summary
static int ANY
          Any or undefined status.
static int STATUS_ACTIVE
          Status: The job is executing actually.
static int STATUS_CREATED
          Status: The job has just been created.
static int STATUS_EXITED_ERROR
          Status: The job has thrown an exception.
static int STATUS_EXITED_OK
          Status: The job was executed successfully.
 
Method Summary
 java.util.Date getCreationDate()
          The date time of the creation of this job.
 java.util.Date getFinishedDate()
          The date time of the execution or null if the job is not executed yet.
 int getId()
          Returns the ID of the job.
 long getMaxTime()
          Returns the result of the calculation.
 int getPriority()
          Ge the desired priority of the job
 java.lang.String getReference()
          The user who created this job.
 java.util.Date getStartDate()
          The date time of the execution or null if the job is not executed yet.
 int getStatus()
          This returns the status of the job as defined in the constants.
 long getTotalRuntime()
          Returns the result of the calculation.
 int getUser()
          The user who created this job.
 
Methods inherited from interface java.lang.Runnable
run
 

Field Detail

ANY

public static final int ANY
Any or undefined status.

STATUS_CREATED

public static final int STATUS_CREATED
Status: The job has just been created.

STATUS_ACTIVE

public static final int STATUS_ACTIVE
Status: The job is executing actually.

STATUS_EXITED_OK

public static final int STATUS_EXITED_OK
Status: The job was executed successfully.

STATUS_EXITED_ERROR

public static final int STATUS_EXITED_ERROR
Status: The job has thrown an exception.
Method Detail

getStatus

public int getStatus()
This returns the status of the job as defined in the constants. The life cycle is CREATED, ACTIVE, EXITED(OK or ERROR). The status any is for earching or undefined behaviour.
Returns:
The status of the job.

getId

public int getId()
Returns the ID of the job.
Returns:
The ID

getReference

public java.lang.String getReference()
The user who created this job.
Returns:
the user

getPriority

public int getPriority()
Ge the desired priority of the job

getUser

public int getUser()
The user who created this job.
Returns:
the user

getCreationDate

public java.util.Date getCreationDate()
The date time of the creation of this job.
Returns:
the creation date

getStartDate

public java.util.Date getStartDate()
The date time of the execution or null if the job is not executed yet.
Returns:
the execution date

getFinishedDate

public java.util.Date getFinishedDate()
The date time of the execution or null if the job is not executed yet.
Returns:
the execution date

getTotalRuntime

public long getTotalRuntime()
Returns the result of the calculation. The type depends on wheter the tools execution was successful. If not an exceptino is the result of the execution. If successfull the type is determined by the tool executed. If the job is not executed yet null must be returned.
Returns:
the execution result

getMaxTime

public long getMaxTime()
Returns the result of the calculation. The type depends on wheter the tools execution was successful. If not an exceptino is the result of the execution. If successfull the type is determined by the tool executed. If the job is not executed yet null must be returned.
Returns:
the execution result

©   O R C A   S y s t e m s