Class JDPSubsystem
java.lang.Object
|
+----java.lang.Thread
|
+----JDPSubsystem
- public class JDPSubsystem
- extends Thread
Class JDPSubsystem represents a process for executing jobs.
-
JDPSubsystem(JDPSubsystemMgr, String)
- Creates a Subsystem with the specified name.
-
getActiveJobCount()
- Get the number of active jobs in this susbsystem.
-
getJob(int)
- Get the Job Handle for the requested Job Number.
-
getJob(String)
- Get the Job Handle for the requested Job Number.
-
getMaxJobs()
- Get the maximum number of jobs this susbsystem can run at a time.
-
getSubsystemDesc()
- Get the description of this Subsystem.
-
getSubsystemHeld()
- Get the Subsystem status.
-
getSubsystemName()
- Get the name of this Subsystem.
-
holdJob(int)
- Hold the requested Job.
-
releaseJob(int)
- Release the requested Job.
-
run()
-
Main thread to run this subsystem
-
setJobComplete(JDPJob)
- Notification that job is complete so remove it from the subsystem and
update it's job info to the database.
-
setMaxJobs(int)
- Set the maximum number of jobs this susbsystem can run at a time.
-
setSubsystemDesc(String)
- Set the description of this Subsystem.
-
setSubsystemHeld(boolean)
- Set the Subsystem status.
-
setSubsystemName(String)
- Set the name of this Subsystem.
-
submitJob(JDPJob)
- Submit a job to the Subsystem.
JDPSubsystem
public JDPSubsystem(JDPSubsystemMgr manager,
String subsystemName)
- Creates a Subsystem with the specified name.
- Parameters:
- subsystemName - the name of the Subsystem.
run
public void run()
- Main thread to run this subsystem
- Overrides:
- run in class Thread
getSubsystemName
public String getSubsystemName()
- Get the name of this Subsystem.
- Returns:
- the name of this Subsystem.
setSubsystemName
public void setSubsystemName(String subsystemName)
- Set the name of this Subsystem.
- Parameters:
- subsystemName - the name of this Subsystem.
getSubsystemDesc
public String getSubsystemDesc()
- Get the description of this Subsystem.
- Returns:
- the description of this Subsystem.
setSubsystemDesc
public void setSubsystemDesc(String subsystemDesc)
- Set the description of this Subsystem.
- Parameters:
- subsystemDesc - the description of this Subsystem.
getActiveJobCount
public int getActiveJobCount()
- Get the number of active jobs in this susbsystem.
- Returns:
- the number of active jobs in this susbsysteme.
getMaxJobs
public int getMaxJobs()
- Get the maximum number of jobs this susbsystem can run at a time.
- Returns:
- the maximum number of jobs this susbsystem can run at a time.
setMaxJobs
public void setMaxJobs(int maxJobs)
- Set the maximum number of jobs this susbsystem can run at a time.
- Parameters:
- maxJobs - the maximum number of jobs this susbsystem can run at a time.
getSubsystemHeld
public boolean getSubsystemHeld()
- Get the Subsystem status.
- Returns:
- the held status of the queue.
setSubsystemHeld
public void setSubsystemHeld(boolean held)
- Set the Subsystem status.
- Parameters:
- heldflag - the status to set the subsystem to.
submitJob
public boolean submitJob(JDPJob job)
- Submit a job to the Subsystem.
- Parameters:
- Job - the Job to submit.
- Returns:
- whether the job submission was accepted.
setJobComplete
public boolean setJobComplete(JDPJob job)
- Notification that job is complete so remove it from the subsystem and
update it's job info to the database.
- Parameters:
- Job - the handle of the Job that completed.
holdJob
public boolean holdJob(int jobNumber)
- Hold the requested Job.
- Parameters:
- JobNumber - the Job number of the Job to hold.
- Returns:
- whether the job was successfully held.
releaseJob
public boolean releaseJob(int jobNumber)
- Release the requested Job.
- Parameters:
- JobNumber - the Job number of the Job to release.
- Returns:
- whether the job was successfully released.
getJob
public JDPJob getJob(int jobNumber)
- Get the Job Handle for the requested Job Number.
- Parameters:
- JobNumber - the Job number of the Job to retrieve.
getJob
public JDPJob getJob(String jobName)
- Get the Job Handle for the requested Job Number.
- Parameters:
- jobName - the Job name of the Job to retrieve.