org.jppf.management
Class TaskInformation

java.lang.Object
  extended by org.jppf.management.TaskInformation
All Implemented Interfaces:
Serializable

public class TaskInformation
extends Object
implements Serializable

Instances of this class encapsulate runtime information on tasks executed by a node.

Author:
Laurent Cohen
See Also:
Serialized Form

Constructor Summary
TaskInformation(String id, String jobId, long cpuTime, long elapsedTime, boolean error)
          Initialize this event object with the specified task.
 
Method Summary
 long getCpuTime()
          Get the cpu time taken by the task.
 long getElapsedTime()
          Get the wall clock time taken by the task.
 String getId()
          Get the task id.
 String getJobId()
          Get the id of the job this task belongs to.
 long getTimestamp()
          Get the timestamp for the creation of this event.
 boolean hasError()
          Determines whether the task had an exception.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TaskInformation

public TaskInformation(String id,
                       String jobId,
                       long cpuTime,
                       long elapsedTime,
                       boolean error)
Initialize this event object with the specified task.

Parameters:
id - the task id.
jobId - the id of the job this task belongs to.
cpuTime - the cpu time taken by the task.
elapsedTime - the wall clock time taken by the task.
error - determines whether the task had an exception.
Method Detail

getId

public String getId()
Get the task id.

Returns:
the id as a string.

getJobId

public String getJobId()
Get the id of the job this task belongs to.

Returns:
the job id as a string.

getCpuTime

public long getCpuTime()
Get the cpu time taken by the task.

Returns:
the cpu time in milliseconds.

getElapsedTime

public long getElapsedTime()
Get the wall clock time taken by the task.

Returns:
the elapsed time in milliseconds.

hasError

public boolean hasError()
Determines whether the task had an exception.

Returns:
true if the task had an exception, false otherwise.

getTimestamp

public long getTimestamp()
Get the timestamp for the creation of this event.

Returns:
the timestamp as a long value.


Copyright © 2005-2010 JPPF Team.