# Rexx Example Loading and Using NetRexx Implemented Command Handlers

Hint: if you wish to look at the ooRexx code with syntax highlighting, then you can use the free and open-source editor `"[g]vim"`, which is available for practically all platforms and can be downloaded from its homepage at http://www.vim.org/.

. <directory> (List of this directory)
  Display all of this directory's files and directories.
.. <directory> (List of parent directory)
  Display all of the parent directory's files and directories.
testAddNetRexxRedirectingCommandHandler.rex
  A Rexx demonstration program to show how to add and use a Rexx command handler implemented in NetRexx (Java).

  The companion NetRexx program (implementing the Rexx command handler) is: NetRexxRedirectingCommandHandler.nrx. Among other things it defines the commands

  - HELLO
  - INFO
  - LOWERCASE [text]
    ... if "text" is omitted, then redirected "input" gets processed, result is written to "output", if redirected, else to redirected "error"
  - PING
  - ROT13 [text]
    ... if "text" is omitted, then redirected "input" gets processed, result is written to "output", if redirected, reprocessed data is written to "error", if redirected
  - UPPERCASE [text]
    ... if "text" is omitted, then redirected "input" gets processed, result is written to "output", if redirected, else to redirected "error"
  and demonstrates how to create failure and error conditions in the command handler if no or an unknown command gets issued by the Rexx program.

  To compile the NetRexx program enter the following command on the command line:

          nrc -compile NetRexxRedirectingCommandHandler.nrx

  To run enter the following command on the command line:

          rexx testAddRedirectingCommandHandler.rex

Rony G. Flatscher, 2022-08-28, Wien/Vienna, Austria, Europe