org.ourgrid.common.spec
Class TaskSpec

java.lang.Object
  extended by org.ourgrid.common.spec.TaskSpec
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
FakeTaskSpec

public class TaskSpec
extends java.lang.Object
implements java.io.Serializable

Entity that encapsulates all the infomations given by the user about each task. To inform, the user uses the Description Files that can be compiled by CommonCompiler.

Version:
1.0
See Also:
CommonCompiler, Serialized Form

Constructor Summary
TaskSpec(IOBlock initBlock, java.lang.String remoteExec, IOBlock finalBlock)
          The constructor.
 
Method Summary
 boolean equals(java.lang.Object o)
           
 IOBlock getFinalBlock()
          Gets the final part of a task.
 IOBlock getInitBlock()
          Gets the init part of a task.
 java.lang.String getRemoteExec()
          Gets the remote part of a task.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TaskSpec

public TaskSpec(IOBlock initBlock,
                java.lang.String remoteExec,
                IOBlock finalBlock)
         throws TaskSpecificationException
The constructor.

Parameters:
initBlock - The information about the files that will be transfered to the remote machine that will be used at the execution of the task.
remoteExec - The command that will be run at the remote machine to execute the task.
finalBlock - The information about the files that will be transfered from the remote machine as results of the execution.
Throws:
TaskSpecificationException - If the informations about the task are not valid.
Method Detail

getInitBlock

public IOBlock getInitBlock()
Gets the init part of a task.

Returns:
Returns the initBlock.

getFinalBlock

public IOBlock getFinalBlock()
Gets the final part of a task.

Returns:
Returns the finalBlock.

getRemoteExec

public java.lang.String getRemoteExec()
Gets the remote part of a task.

Returns:
Returns the remoteExec.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object