Whew! I just finished working on a major software feature for my ultra-conservative corporate customer. It provides me with one great reason to use EGL, and specifically, the EGL Development Toolkit (EDT).
I was asked to do the (seemingly) impossible: Duplicate an existing process to create form letters. A few thousand different forms needed to be converted to the new process. While BIRT might have been a general solution to the problem of producing PDFs, there wasn't enough time. I've used BIRT successfully. Generally, I would recommend it. But, designing a few thousand BIRT reports didn't seem to be the right answer.
I used EGL to prototype the PDF generation process. While the development environment was strictly Rational Business Developer, I chose EDT as the tool to build the prototype. And, I'm really glad I did. EDT provides a New | External Type feature, to generate external types from an existing Java library. I imported the iTextPdf library (at www.itextpdf.com). I bought the electronic book: iText in Action.
Within a few minutes, I generated my first PDF. It wasn't much. Writing the code in EGL made it easy to think about the problem in high-level, business-logic terms. I was able to change my mind several times while exploring different designs without the complexity of refactoring Java source code. And yet, external types enable me to use the off-the-shelf iTextPdf library, with all of its power to read and write PDFs.
I connected my PDF generator to a frame library (Framing Software, XVCL) to store key-value pairs in an SQL database. In this specific case, an analysis of a few thousand forms showed a very distinctive pattern and consistency of purpose for the form letters. Knowing exactly what needed to be produced, I was able to create a custom form letter editor. The letter editor provides a mechanism for variable substitution (lifted directly from Apache Ant).
And then, it hit me. The original form letters were composed with Microsoft Word and stored in an open document format. Tapping again into the power of EGL and external types, I imported the text (but not formatting) of the existing form letters into the frame table, using an EGL business logic library. With the text of the form letter in the editor, it was (relatively) quick and easy to add formatting to recreate the original form.
Importing from Microsoft Word to a BIRT report is beyond my technical skill at the moment. This turned out to be the right answer to the specific problem facing the customer. They needed a new way of generating form letters in their production system and, with demands from their customers, they only had thirty days to do it.
Working with EGL alone, I wouldn't be able to finish the project. And working with Java alone, I wouldn't be able to quickly build a succession of prototypes, trying and working through different design ideas.
The best design was selected and imported into Rational Business Developer. While the syntax is similar, EGL written with EDT did not simply drop into the customer's version of RBD. It had to be reworked, especially lack of support for a question mark (?) at the end to indicate a nullable type. At the end of thirty days, end-users were generating customizable PDFs using production web application.
Now, that's a good reason to use EGL. What do you think?
Showing posts with label edt. Show all posts
Showing posts with label edt. Show all posts
Friday, August 16, 2013
Tuesday, January 29, 2013
Essential EGL+Batch - Lesson 04 Date
Essential EGL+Batch - Lesson 03 Library Variable
Saturday, January 26, 2013
Essential EGL+Batch - Installing EDT on Linux
Essential EGL+Batch - Installing EDT on Linux is now available on my YouTube channel. In this lesson, we download and install EGL Development Tools version 0.8.2 on Linux 32-bit.
While I am featuring OpenSUSE Linux version 11.1 in this video, it applies to Linux in general.
Essential EGL+Batch is a video series featuring EGL Development Tools (EDT) version 0.8.
Transcript:
Welcome to Essential EGL+Batch. This series features EGL Development Tools version 0.8. In this lesson, we’re going to (1) download and (2) install the EGL Development Tools on Linux. We’re going to assume that you have met the system requirements for EDT, such as a Java Runtime Environment version 6 or greater.
What you want to do is to open your favorite web browser and in the location field you want to type in www dot eclipse dot org, which brings you to the main page. And then, you want to select projects, And then, you want to select the list of all projects. Now, there’s a lot of projects at the eclipse dot org web site. We want to go to the section on tools, we want to find the section on tools and then select the EGL Development Tools.
EGL Development Tools enables you to bring up an EGL+Batch environment.
Now, on the EGL Development Tools page, we want to go to Downloads. And then, on the Downloads page, we’ll scroll down and we’re looking for the all-in-one package for our platform. And in this case, we’ll be installing EGL Development Tools on Linux 32-bit.
We click on that link and it brings us to a page where we want to find a mirror that’s close to our location on the Internet. And my favorite mirror is the Georgia Tech Software Library because I’m located near Georgia Tech. We want to save the file.
This file downloads in about six minutes on my computer. I sped that up so you don’t have to wait for six minutes of video.
So the download is complete. The name of the file is eglweb hyphen zero eight two hyphen linux hyphen gtk dot tar dot gz.
Now, to be able to use a GZ-compressed TAR-compatible archive, we want to uncompress and unarchive it. From a command line, I’ll create a new directory called “egl web”. I’ll use the tar command with the X, V, Z and F options to uncompress and unarchive the file.
There! With the file uncompressed and unarchived, I need to switch to the superuser to make the EGL Development Tools available for all users. So, I’m going to change directories to slash opt slash eclipse dot org. I’m going to use the move command to change the name of the eclipse directory to eglweb. Now, if I go into eglweb what I’m looking for is the eclipse command and there it is.
So, now, I can go back to my account. And, I’ll switch to slash opt slash eclipse dot org slash eglweb. And, I’ll start Eclipse with dot slash eclipse. And, that starts the EGL Development Tools.
I’ll accept the default directory by pressing the OK button.
This has been another lesson in the series Essential EGL Batch. Thanks for watching!
While I am featuring OpenSUSE Linux version 11.1 in this video, it applies to Linux in general.
Essential EGL+Batch is a video series featuring EGL Development Tools (EDT) version 0.8.
Transcript:
Welcome to Essential EGL+Batch. This series features EGL Development Tools version 0.8. In this lesson, we’re going to (1) download and (2) install the EGL Development Tools on Linux. We’re going to assume that you have met the system requirements for EDT, such as a Java Runtime Environment version 6 or greater.
What you want to do is to open your favorite web browser and in the location field you want to type in www dot eclipse dot org, which brings you to the main page. And then, you want to select projects, And then, you want to select the list of all projects. Now, there’s a lot of projects at the eclipse dot org web site. We want to go to the section on tools, we want to find the section on tools and then select the EGL Development Tools.
EGL Development Tools enables you to bring up an EGL+Batch environment.
Now, on the EGL Development Tools page, we want to go to Downloads. And then, on the Downloads page, we’ll scroll down and we’re looking for the all-in-one package for our platform. And in this case, we’ll be installing EGL Development Tools on Linux 32-bit.
We click on that link and it brings us to a page where we want to find a mirror that’s close to our location on the Internet. And my favorite mirror is the Georgia Tech Software Library because I’m located near Georgia Tech. We want to save the file.
This file downloads in about six minutes on my computer. I sped that up so you don’t have to wait for six minutes of video.
So the download is complete. The name of the file is eglweb hyphen zero eight two hyphen linux hyphen gtk dot tar dot gz.
Now, to be able to use a GZ-compressed TAR-compatible archive, we want to uncompress and unarchive it. From a command line, I’ll create a new directory called “egl web”. I’ll use the tar command with the X, V, Z and F options to uncompress and unarchive the file.
There! With the file uncompressed and unarchived, I need to switch to the superuser to make the EGL Development Tools available for all users. So, I’m going to change directories to slash opt slash eclipse dot org. I’m going to use the move command to change the name of the eclipse directory to eglweb. Now, if I go into eglweb what I’m looking for is the eclipse command and there it is.
So, now, I can go back to my account. And, I’ll switch to slash opt slash eclipse dot org slash eglweb. And, I’ll start Eclipse with dot slash eclipse. And, that starts the EGL Development Tools.
I’ll accept the default directory by pressing the OK button.
This has been another lesson in the series Essential EGL Batch. Thanks for watching!
Thursday, January 17, 2013
Essential EGL+Batch - Lesson 02 Library
Here is the source code for Lesson02.egl:
package lab.lesson02;
program Lesson02
function main()
SysLib.writeStdout("Lesson 02");
demo();
end
private function demo()
functionName string = "demo";
BatchLib.startFunction(functionName);
BatchLib.endFunction(functionName);
end
end
Here is the source code for BatchLib.egl:
package lab.lesson02;
library BatchLib
private const PREFIX_START string = "START ";
private const PREFIX_END string = "END ";
function startFunction(name string in)
message string = PREFIX_START :: name;
SysLib.writeStdout(message);
end
function endFunction(name string in)
message string = PREFIX_END :: name;
SysLib.writeStdout(message);
end
end
Thanks for watching!
Thanks for watching!
Essential EGL+Batch - Lesson 01
package lab.lesson01;
program Lesson01
function main()
SysLib.writeStdout("Lesson 01 - 0.0.0");
end
end
Thanks for watching!
New Video Series: Essential EGL+Batch
Starting out with EGL? Don't try to learn too much too soon. This video series is intentionally limited to the very simple EGL+Batch model. In this model, you run a program in a runnable Java Archive from a command line. You only need a Java Virtual Machine, such as provided by Java Runtime Environment 6.
With this model, you can do important production work, such as import/export information into a JDBC-compatible database, such as DB2, SQL Server or Oracle. You can validate existing data. You can write, debug and test business logic in a library before it is used by a web service provider.
With this model, you can learn the development tools, such as the IDE, editor and generator. You can learn the most important features of the the language, such as built-in types, parts, control structures, records, arrays, dictionaries, delegates and more. You can learn to work with the Eclipse debugger.
At first, you do not need to learn additional technologies. Once you have learned the basics, you can then go on to learn more complex models, such as EGL Rich UI, web service provider, EGL+JSF. You can go on to learn the complexities of the full JEE application server.
This tutorial features EGL Development Tools (EDT), an Eclipse project. We'll use version 0.8. Install EDT on Linux or Windows. In lesson 01, create a basic project, create a package, write a program, run a program, debug a program, create a runnable Java archive, run a program from a command line. In lesson 02, write a library, learn about the built-in type called string, learn about the const and private keywords, use the debugger to find and fix a bug.
Thanks for watching!
With this model, you can do important production work, such as import/export information into a JDBC-compatible database, such as DB2, SQL Server or Oracle. You can validate existing data. You can write, debug and test business logic in a library before it is used by a web service provider.
With this model, you can learn the development tools, such as the IDE, editor and generator. You can learn the most important features of the the language, such as built-in types, parts, control structures, records, arrays, dictionaries, delegates and more. You can learn to work with the Eclipse debugger.
At first, you do not need to learn additional technologies. Once you have learned the basics, you can then go on to learn more complex models, such as EGL Rich UI, web service provider, EGL+JSF. You can go on to learn the complexities of the full JEE application server.
This tutorial features EGL Development Tools (EDT), an Eclipse project. We'll use version 0.8. Install EDT on Linux or Windows. In lesson 01, create a basic project, create a package, write a program, run a program, debug a program, create a runnable Java archive, run a program from a command line. In lesson 02, write a library, learn about the built-in type called string, learn about the const and private keywords, use the debugger to find and fix a bug.
Thanks for watching!
Subscribe to:
Posts (Atom)