Interface IZosBatch
-
Method Summary
Modifier and TypeMethodDescriptionReturn a list of zOS Batch jobs with the given jobname and/or the owner.@NotNull IZosBatchJobsubmitJob(@NotNull String jcl, IZosBatchJobname jobname) Submit a job.@NotNull IZosBatchJobsubmitJob(@NotNull String jcl, IZosBatchJobname jobname, ZosBatchJobcard jobCard) Submit a job.@NotNull IZosBatchJobsubmitJobWithSuppliedJobcard(@NotNull String jcl) Submit a job using JCL that contains its own JOB statement, for example a member of a JCL library.
-
Method Details
-
submitJob
@NotNull @NotNull IZosBatchJob submitJob(@NotNull @NotNull String jcl, IZosBatchJobname jobname) throws ZosBatchException Submit a job.The Manager generates a JOB statement and puts it in front of the supplied JCL, so the JCL must not include a JOB statement. To submit JCL that already contains its own JOB statement, use
submitJobWithSuppliedJobcard(String).- Parameters:
jcl- - The JCL to submit. Must not include the JOB statement, unless submitted usingsubmitJobWithSuppliedJobcard(String)jobname- -IZosBatchJobnameA provisioned jobname, if null, a new unique jobname will be provisioned.- Returns:
IZosBatchJobA representation of the zOS Batch Job- Throws:
ZosBatchException
-
submitJob
@NotNull @NotNull IZosBatchJob submitJob(@NotNull @NotNull String jcl, IZosBatchJobname jobname, ZosBatchJobcard jobCard) throws ZosBatchException Submit a job.The Manager generates a JOB statement and puts it in front of the supplied JCL, so the JCL must not include a JOB statement. To submit JCL that already contains its own JOB statement, use
submitJobWithSuppliedJobcard(String).- Parameters:
jcl- - The JCL to submit. Must not include the JOB statement, unless submitted usingsubmitJobWithSuppliedJobcard(String)jobname- -IZosBatchJobnameA provisioned jobname, if null, a new unique jobname will be provisioned.- Returns:
IZosBatchJobA representation of the zOS Batch Job- Throws:
ZosBatchException
-
submitJobWithSuppliedJobcard
@NotNull @NotNull IZosBatchJob submitJobWithSuppliedJobcard(@NotNull @NotNull String jcl) throws ZosBatchException Submit a job using JCL that contains its own JOB statement, for example a member of a JCL library.The JCL is submitted as supplied. The Manager does not generate a JOB statement, so:
- the job name is taken from the supplied JOB statement, converted to upper case,
and is returned by
IZosBatchJob.getJobname(). A Galasa provisioned jobname is not used. The same job name is used to track the job, soIZosBatchJob.waitForJob()and the retrieval of spool files work as usual. Jobs submitted with the same job name by tests running at the same time are distinguished by their job IDs. - the values that are set on a
ZosBatchJobcard, and the default input class, message class and message level from the CPS properties, are not applied. Everything required must be specified in the supplied JOB statement.
//*) must be the JOB statement,//jobname JOB .... The statement can be continued over several records. If a valid JOB statement is not found, aZosBatchExceptionis thrown and the JCL is not submitted. Only the first JOB statement is considered if the JCL contains more than one.If the CPS property
zosbatch.batchjob.[imageid].use.sysaffis true, a/*JOBPARM SYSAFF=[imageid]record is inserted immediately after the last record of the JOB statement. It is not inserted if the supplied JCL already contains a/*JOBPARMrecord that specifiesSYSAFF=.The supplied JCL is stored in the test results archive in the same way as for
submitJob(String, IZosBatchJobname).- Parameters:
jcl- - The JCL to submit. Must start with a JOB statement- Returns:
IZosBatchJobA representation of the zOS Batch Job- Throws:
ZosBatchException- if the JCL does not start with a valid JOB statement or the job cannot be submitted
- the job name is taken from the supplied JOB statement, converted to upper case,
and is returned by
-
getJobs
Return a list of zOS Batch jobs with the given jobname and/or the owner. Jobname and owner can be the full value or use the * wild card.- Parameters:
jobname- - The jobname. If null, defaults to *owner- - The User ID of the job owner. If null, defaults to the user ID of the requester. Use * for all owners.- Returns:
- a
ListofIZosBatchJobobjects with the given jobname prefix - Throws:
ZosBatchException
-