org.ourgrid.mygrid.ui.command
Class JobCanceller

java.lang.Object
  extended by org.ourgrid.mygrid.ui.command.JobCanceller
All Implemented Interfaces:
Command

public class JobCanceller
extends java.lang.Object
implements Command

Description: This class is responsible to send a cancel job request to the scheduler. This can be made by getting an instance from JobCanceller and using its API or through mygrid cancejob script. At both of them a job is cancelled based on it's id.

Version:
1.0 Created on 03/08/2004

Constructor Summary
JobCanceller(UIManager manager)
           
 
Method Summary
 void cancelJob(int jobId)
           
 boolean configureEnvironment()
          Determines if this command needs to configure environment before being executed
static void printUsage()
          Print's this class command line usage.
 int run(java.lang.String[] params)
          Main method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JobCanceller

public JobCanceller(UIManager manager)
Method Detail

run

public int run(java.lang.String[] params)
Main method. This method should be called with a Job Id as command line argument.

Specified by:
run in interface Command
Parameters:
params - Job Id

printUsage

public static void printUsage()
Print's this class command line usage.


configureEnvironment

public boolean configureEnvironment()
Description copied from interface: Command
Determines if this command needs to configure environment before being executed

Specified by:
configureEnvironment in interface Command
Returns:
true if this command needs to configure environment before. False, otherwise.
See Also:
Command.configureEnvironment()

cancelJob

public void cancelJob(int jobId)
               throws JobNotFoundException,
                      java.rmi.RemoteException,
                      JobCouldNotBeCancelledException
Throws:
JobNotFoundException
java.rmi.RemoteException
JobCouldNotBeCancelledException