Overview
- What Is Rexx?
- Rexx is scripting language that originated on the IBM VM/CMS
operating system. You'll find it on most IBM operating systems,
including PC-DOS 7 and OS/2. It also comes in free and
commercial versions for many systems including MS-DOS and Unix.
- Portability
- Rexx is available on many platforms. Rexx scripts are
fairly portable if you don't rely on system-dependent commands.
There is an ANSI standard for Rexx (X3J18) based on the book
"The Rexx Language" by Mike Cowlishaw (who designed Rexx).
- Pros and Cons
- Pros: Rexx is pretty portable from PC's up to big
mainframes. Cons: it's an IBM-ish language, almost unknown in
the UNIX and Microsoft worlds.
- How To Get It
- It comes as part of most IBM operating systems (PC-DOS 7,
OS/2.) You can get free versions from the Internet.
- Libero Supports
- Libero supports a portable Rexx syntax.
Working With Rexx
- Schema: lrschema.Rex.
- Program model: Rexx program.
- Good for: large Rexx programs.
- Files used/made: Own work in myprog.mod;
generates program called myprog.rx.
- Module functions:
module_function_name:
- Private functions:
private_function_name : (note the space before ':')
- Naming style: Any except -style=cobol.
- Limits: Standard Libero limits, and system memory.
All tables are defined dynamically at runtime.
- Development cycle: Run lr after you change
the dialog or .mod file. When you add a new module,
run lr, then edit the .mod file, then run lr
again. Don't change the generated Rexx script except for tests
- you'll lose your changes.
Example of code
Code fragments:
/****************** MODULE FUNCTION NAME ******************/
module_function_name:
Return /* All modules end in Return */
private_function_name :
the_next_event = ok_event
Call raise_exception (error_event)
Return
A fuller example.