What is a command processor?

TSO/E provides commands that you can use to perform a wide variety of tasks. For example, you can use TSO/E commands to define and maintain data sets, and write and test programs.

You can write command processors to replace or add to this set of commands. By writing your own command processors, your installation can add to or modify TSO/E to better suit the needs of its users.

A command processor is a program (written in assembler language, PL/1, or compiled REXX then linked into a load module) that receives control when a user at a terminal enters a command name. It is given control by the terminal monitor program (TMP), a program that provides an interface between terminal users and command processors, and has access to many system services.

The main difference between command processors and other programs is that when a command processor is invoked, it is passed a command processor parameter list (CPPL) that gives the program access to information about the caller and to system services.

Command processors must be able to communicate with the user at the terminal, as well as respond to abnormal terminations and attention interruptions. Command processors can recognize subcommand names entered by the terminal user and then load and pass control to the appropriate subcommand processor.

To write a command processor, you can use many of the services documented in z/OS TSO/E Programming Services. For example, you can use the TSO/E service facility (IKJEFTSR) to invoke other commands, CLISTs or programs. Writing a command processor provides guidelines about which TSO/E services to use, and how to write, test, and install a command processor.