Skip to main content

 

IBM JZOS Batch Toolkit for z/OS SDKs - Sample Java Programs and Javadoc, Version 2.3.0

(last updated June, 2009)

  
dblue_rule.gif

Sample Java programs for the IBM JZOS toolkit:

  • jzos_sample_2.3.0.zip (source and compiled Java samples) Download

Javadoc for the IBM JZOS toolkit:

  • jzos_2.3.0_javadoc.zip (javadoc source) Download
grey_rule.gif

A summary of sample programs (all in package com.ibm.jzos.sample) follows:

DynallocCopyDataset

Sample program that uses BPXWDYN to dynamically allocate a new dataset with the same attributes as a given dataset, and then copy the original to the new dataset. The name of the source dataset and target dataset names are given as arguments.


FileFactoryCopy

Sample program that uses the FileFactory class to copy a text file or dataset. The input and output file names are given as arguments to main, and they may be either POSIX (HFS) file names or MVS dataset names.


HelloWorld

Simple class that says hello on System.out and System.err.


PdsLister

Sample program that lists a PDS directory.


PeekOSMemory

Sample program that dumps 500 bytes from the CVT to System.out.


ShowJavaProperties

Simple class used to display Java system properties and selected system environment variables.


ZFileCopy

Sample program that uses the ZFile class to copy an MVS dataset in record mode from DD INPUT to DD OUTPUT.


ZFileSDS

Sample program that inserts, updates, locates, and deletes records in a VSAM KSDS using a JZOS ZFile.


ZFilePrint

Sample program that prints an EBCDIC MVS dataset pointed to by //INPUT DD to System.out (stdout).


grey_rule.gif

Samples added in JZOS 2.2.1


MvsConsoleInteraction

This sample shows how JZOS can be used to interact with the MVS console.


MvsConsoleWrapper

This sample demonstrates a main program that can be used to wrap another main program while redirecting System.in and System.out to the MVS console.


CatalogSearchSample

Sample program that uses CatalogSearch, LOCATE and OBTAIN to display information about datasets matching a filter key.


MvsJobOutput

Sample program which reads all sysout data for a MvsJob (jobname and jobid), and writes the output to a specified Writer.


MvsJobSubmitter

Sample program which submits a job to the internal reader, returning a MvsJob object containing the jobname and jobid.


fields.Format5DSCB

fields.Format5DSCBBase

fields.FOrmat5Extent

Sample classes which use the com.ibm.jzos.fields converter classes to map a z/OS format 5 DSCB into a java record.


fields.Smf83BaseRecord

fields.Smf83Product

fields.Smf83Record

fields.Smf83Security

Sample classes which use the com.ibm.jzos.fields converter classes to map some components of an Smf83 record.


 

suncup.gif