October 20

0 comments

What is the RPG Open Access Handler all about?

By NickLitten

October 20, 2013

Access, Open, RPG, RPGOA

What is RPG open Access ?

Rational® Open Access: RPG Edition provides a way for RPG programmers to use the simple and well-understood RPG I/O model to access resources and devices that are not directly supported by RPG.

Open Access opens up RPG’s file I/O capabilities, allowing anyone to write innovative I/O handlers to access other devices and resources such as:

  1. Rpg open accessBrowsers
  2. Mobile devices
  3. Cloud computing resources
  4. Web services
  5. External databases
  6. XML files
  7. Spreadsheets
  8. And more

An Open Access application has three parts:

  1. An RPG program that uses standard RPG coding to define an Open Access file and use I/O operations against the file.
  2. A handler procedure or program that is called by Open Access to handle the I/O operations for the file.
  3. The resource or device that the handler is using or communicating with.

Open Access is the linkage between parts 1 and 2. Licenced program 5733-OAR is required to use Open Access at runtime. Open Access is a full-featured version of the limited support provided by RPG SPECIAL files. It provides a way for RPG programmers to use the simple and well-understood RPG I/O model to access devices that are not directly supported by RPG.

When the HANDLER keyword is specified on a File specification, the RPG compiler will generate code to use the specified handling procedure for I/O operations to the file rather than generating code to call the system’s data management functions. The HANDLER keyword can be used for any RPG device, DISK, PRINTER, or WORKSTN. The provider of the handling procedure can choose the RPG device-type that best fits the function that the handler provides. For example, a user-interface application could map to a WORKSTN file, an Excel document could map to a PRINTER file, and a Web service could map to a keyed DISK file.

To obtain the runtime enablement for these capabilities, customers should order IBM Rational Open Access: RPG Edition (5733-OAR). Which means you have to purchase as a separate Product.

Simply RPG Open Access mean, for example, instead of doing an EXFMT to the green screen you could do it to a web browser.

What is a HANDLER?

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Join the IBM i Community for FREE Presentations, Lessons, Hints and Tips

>