Developing EGL applications

Enterprise Generation Language (EGL) is a programming language that you can use to focus on business problems instead of software technologies. Within the Rational® development environment, you can use EGL wizards and other tools to write complex applications with minimal effort.

Rather than running EGL applications directly, you use EGL code to generate Java™ or COBOL programs that run on a variety of platforms.

You can use EGL in a number of ways to create applications with fully interactive web pages and database support.

EGL supports service-oriented architecture (SOA), so you can create or take advantage of reusable programs in widely distributed domains. You can also make a multi-tiered approach to architecture by using EGL, dividing function between the workstation of the user (client), the server, and outside services. You can divide work between dynamic web pages, such as Java Server Pages, or JSPs and underlying programs written in any number of languages.

Generated code

You can use EGL to create the following types of generated code:
  • A Java program can generate for any of several supported platforms. You can deploy the program outside of J2EE or in the context of any of the following J2EE containers:
    • J2EE application client
    • J2EE web application
    • EJB container; in this case, you also generate an EJB session bean

    You can call an EGL-generated Java program in an EGL web service if the program is non-interactive. The program in this case can deploy inside or outside of J2EE. Also, you can call a program that runs in CICS® batch mode from an EGL service or EGL web service.

  • A non-interactive COBOL program can generate to run on CICS for z/OS®, on z/OS batch mode outside of CICS, or on iSeries®. Also, a COBOL program can generate to run on IMS™, either as a message processing program (MPP) or as a batch message program (BMP).

In addition, you can use EGL to define a web application that has the following characteristics:

For details on this specialized support for web applications, see the topic "JSF Handler part" in the EGL Language Reference.

You also can update a VGWebTransaction program, although the best practice is to use Handler parts for developing web applications. EGL includes the this program type to support migration of a VisualAge® Generator program type, which allows developers to structure a web application as if the code were running in a non-web environment. The VGWebTransaction program retrieves data, displays data, accepts user input, and post-processes data, whereas most applications built with PageHandler parts forward control from one web page to the next.

A VGWebTransaction program is a main program (not a called program). If the program generates for a Java environment such as Windows 2000/NT/XP, the program runs outside of J2EE.

You can also use EGL to generate a Java wrapper. For details on the use of Java wrappers, see the topics "Java wrapper" and "Java wrapper classes" in the list of related topics at the end of this topic.

Service-oriented development

The idea of service-oriented architecture (SOA) is similar to the concepts of the application program interface (API) and the custom library of common functions: you can use all three to reuse capabilities. Services can be located in widely distributed domains. SOA provides standards for locating and using calls to these functions, either locally or over the Internet.

EGL supports the use of services through service program parts and interfaces.

Multi-tiered applications

EGL also supports the division of labor between the types of software in an application. Applications typically take a multi-tiered approach to architecture, dividing functions between the workstation of the user (client), the server, and outside services. They can also divide functions between dynamic web pages, such as Java Server Pages, or JSPs and underlying programs written in any number of languages.

You can think about a tiered structure as the Model-View-Controller (MVC) approach. Like other architectural schemes, the tiered structure helps you think about aspects of the application as conceptual units. In its simplest form, the MVC manages the input from a user interface (UI) such as a web page. It passes the input (such as a customer number) to a program that models the solution to a business problem (such as storing and retrieving customer information). The model then returns information (such as a customer record) to the view component (back to the web page).

Hello World program

To start using EGL now, run the EGL "Hello World" tutorial. The "Hello World" program serves a number of purposes:
  • It allows you to start using the language tools.
  • It introduces the baseline concepts of the language.
  • It associates a physical activity with new concepts to help you retain what you learn.

To access this tutorial, see “Create a hello world program with EGL.”