EGL (programming language): Difference between revisions

Content deleted Content added
FrescoBot (talk | contribs)
Rescuing 1 sources and tagging 0 as dead.) #IABot (v2.0.9.5
 
(34 intermediate revisions by 22 users not shown)
Line 1:
{{refimprove|date=January 2017}}
{{Infobox programming language
[[de:|name = EGL<br />(Enterprise Generation Language]])
|logo =
|paradigm =
|year =
|designer =
|developer = [[IBM]]
|latest_release_version =
|latest_release_date =
|typing =
|implementations =
|dialects =
|influenced_by =
|influenced =
|current version =
|operating_system =
|license = [[Eclipse Public License]]
|website = {{URL|http://www.eclipse.org/edt/}}
}}
'''EGL''' (Enterprise Generation Language), originally developed by [[IBM]] and now available as the EDT (EGL Development Tools)<ref>[http://www.eclipse.org/edt/ EDT (EGL Development Tools)]</ref> Open[[open Sourcesource]] project under the [[EPL (Eclipse Public License)]] (EPL), is a programming technology designed to meet the challenges of modern, multi-platform application development by providing a common language and programming model across languages, frameworks, and runtime platforms. The language borrows concepts familiar to anyone using statically typed languages like Java, COBOL, C, etc. However, it borrows the concept of Stereotype from UML (Universal Modeling Language) that is not typically found in statically typed programming languages.
 
==Overview==
'''EGL''' (Enterprise Generation Language), originally developed by IBM and now available as the [http://www.eclipse.org/edt/ EDT (EGL Development Tools)] Open Source project under the [[EPL (Eclipse Public License)]] , is a programming technology designed to meet the challenges of modern, multi-platform application development by providing a common language and programming model across languages, frameworks, and runtime platforms. The language borrows concepts familiar to anyone using statically typed languages like Java, COBOL, C, etc. However, it borrows the concept of Stereotype from UML (Universal Modeling Language) that is not typically found in statically typed programming languages.
The language borrows concepts familiar to anyone using statically typed languages like [[Java (programming language)|Java]], [[COBOL]], [[C (programming language)|C]], etc. However, it borrows the concept of [[Stereotype (UML)|stereotype]] from [[Unified Modeling Language]] (UML) that is not typically found in statically typed programming languages. In a nutshell, EGL is a higher-level, universal application development language.
 
EGL is similar in syntax to other common languages so it can be learned by application developers with similar previous programming background. EGL application development abstractions shield programmers from the technical interfaces of systems and middleware allowing them to focus on building business functionality.
In a nutshell, EGL is a higher-level, universal application development language.
EGL applications and services are written, tested and debugged at the EGL source level, and once they are satisfactorily functionally tested they can be compiled into [[COBOL]], Java, or [[JavaScript]] code to support deployment of business applications that can run in any of the following environments:
 
*Platforms with a [[Java virtual machine]], such as [[Microsoft Windows]], [[Linux]], and [[UNIX]] running JVM, for example in the context of a Java EE servlet container ([[IBM WebSphere Application Server]], [[Apache Tomcat]], [[GlassFish]])
EGL is similar in syntax to other common languages so it can be learned by application developers with similar previous programming background. EGL application development abstractions shield programmers from the technical interfaces of systems and middleware allowing them to focus on building business functionality.
EGL applications and services are written, tested and debugged at the EGL source level, and once they are satisfactorily functionally tested they can be compiled into [[COBOL]], Java, or JavaScript code to support deployment of business applications that can run in any of the following environments:
 
*[[Microsoft Windows]], [[Linux]], [[UNIX]] running JVM, for example in the context of a Java EE servlet container ([[IBM WebSphere Application Server]], [[Apache Tomcat]], [[GlassFish]])
*[[IBM System z]]: [[CICS Transaction Server]], [[IBM Information Management System|IMS]], [[z/OS]] Batch, [[UNIX System Services]], WebSphere Application Server, [[z/VSE]], Linux
*[[IBM SystemPower iSystems]]: [[IBM i5/OSi]], IBM WebSphere Application Server, [[Apache Tomcat]], Integrated Web Application Server for i
*[[Web browsers]] supporting JavaScript, such as [[Internet Explorer]], [[Firefox]], and [[Safari (web browser)|Safari]] browsers, for [[Ajax (programming)|Ajax]] [[Rich web application|rich web applications ]]
 
== Code examples ==
 
'''=== Program''' ===
An EGL Program part is a generatable logic part with one entry point. Each Program part contains a main() function, which represents the logic that runs at program start up. A program can include other functions and can access functions that are outside of the program. The function main() can invoke those other functions. ProgramsProgram functions are composed of a set of EGL statements, variables, and constants.
 
<syntaxhighlight lang="pascal" line highlight="5">
An EGL Program part is a generatable logic part with one entry point. Each Program part contains a main() function, which represents the logic that runs at program start up. A program can include other functions and can access functions that are outside of the program. The function main() can invoke those other functions. Programs functions are composed of a set of EGL statements, variables, and constants.
 
<source lang="java">
Program HelloWorld
 
Line 26 ⟶ 45:
myName string = "John";
sayHello(myName);
end
 
function sayHello(name String in)
Line 33 ⟶ 52:
 
end
</syntaxhighlight>
</source>
 
'''=== Record''' ===
An EGL Record part defines a set of data elements. In this example, a record with the name '''''CustomerRecord''''' is defined with 6 fields.
 
<syntaxhighlight lang="pascal">
An EGL Record part defines a set of data elements. In this example, a record with the name '''''CustomerRecord''''' is defined with 6 fields.
 
<source lang="java">
Record CustomerRecord type BasicRecord
customerNumber INT;
Line 48 ⟶ 66:
customerBalance MONEY;
end
</syntaxhighlight>
</source>
 
EGL has a specialized type of record called '''''SQLRecord''''' that is used to exchange data with a relational database.
 
<sourcesyntaxhighlight lang="javatext">
record Employee type sqlRecord { tableNames =[["Employee"]], keyItems =[EMPNO]}
 
record Employee type sqlRecord { tableNames =[["Employee"]
], keyItems =[EMPNO]}
EMPNUMBER string{ column = "EMPNO", maxLen = 6};
FIRSTNME string{ sqlVariableLen = yes, maxLen = 12};
Line 65 ⟶ 81:
end
 
</syntaxhighlight>
</source>
 
* In this example, the record '''''Employee''''' is bound to a table (or view) named '''''Employee'''''.
 
'''Service'''
 
'''=== Service''' ===
An EGL Service part contains public functions meant to be accessed from other applications or systems. In this example, a service with two functions is defined.
 
<syntaxhighlight lang="pascal" line highlight="1,5,11">
<source lang="java">
package com.mycompany.services;
 
Line 94 ⟶ 109:
 
end
</syntaxhighlight>
</source>
 
* In EGL, code is organized in packages (like [[Java (programming language)]])
* The first function, ''getEmployees'', returns an array of records populated from the records in a database.
* The second function, ''addEmployee'' adds a new record to the database and returns a true or false depending on whether the record was added successfully.
 
'''=== RUIHandler''' ===
 
The main component of a Rich UI application is a Rich UI handler part. These parts are generated into JavaScript.
 
<syntaxhighlight lang="javascript" line highlight="8">
<source lang="java">
package com.mycompany.ui;
 
Line 112 ⟶ 126:
import dojo.widgets.DojoGridColumn;
 
handler EmployeeView type RUIhandler { initialUI = [ grid ],
onConstructionFunction = start,
], onConstructionFunction = start, cssFile = "main.css" }
 
grid DojoGrid { behaviors = [ ], headerBehaviors = [ ], columns = [
Line 131 ⟶ 146:
end
</syntaxhighlight>
</source>
 
== Web 2.0 with EGL ==
In December 2008, IBM introduced new technology, EGL Rich UI, to simplify the creation of [[Web 2.0]]-style [[Rich Internetweb Applicationsapplication|rich web applications]]. This technology simplifies development by hiding the complexities of [[Ajax (programming)|Ajax]], [[JavaScript]], [[REST]], and [[SOAP]] from the developer, which enables them to focus on the business requirement and not on the underlying technologies.
 
== Commercial Productsproducts ==
In December 2008, IBM introduced new technology, EGL Rich UI, to simplify the creation of [[Web 2.0]]-style [[Rich Internet Applications]]. This technology simplifies development by hiding the complexities of [[Ajax (programming)|Ajax]], [[JavaScript]], [[REST]], and [[SOAP]] from the developer, which enables them to focus on the business requirement and not on the underlying technologies.
EGL programming tools are available as an Eclipse-based<ref>[http://www.eclipse.org Eclipse]-based</ref> commercial product, the [[IBM Rational Business Developer Extension | Rational Business Developer]] and also in the EGL edition of [[Rational Developer for System z]].
 
EGL is a target language for modernization of legacy applications because of the language semantics affinity with procedural languages and legacy [[4GL|4th generation languages]]:
== Commercial Products ==
* a set of conversion tools available within the [[IBM Rational Business Developer Extension | Rational Business Developer]] product provide automated the conversion from older and stabilized IBM and [[Informix]] [[4GL|4th generation languages]]
* a set of IBM service offerings and complementary products (Rational Migration Extension for Natural, Rational Migration Extension for System i, Rational Migration Extension for CA-products) provide the ability to convert from [[NATURAL|Software AG Natural]] and from, [[IBM RPG]], CA Cool:Gen and CA Ideal/Datacom to EGL
 
Tools for searching large EGL code bases, comparing individual EGL files for changes, and detecting duplicated code are available from [Semantic Designs<ref>{{Cite web |url=http://www.semanticdesigns.com/Products/LanguageTools/EGLTools.html |title=Semantic Designs] |access-date=2010-08-13 |archive-date=2011-07-16 |archive-url=https://web.archive.org/web/20110716035836/http://www.semanticdesigns.com/Products/LanguageTools/EGLTools.html |url-status=dead }}</ref>
EGL programming tools are available as an [http://www.eclipse.org Eclipse]-based commercial product, the [[IBM Rational Business Developer Extension | Rational Business Developer]] and also in the EGL edition of [[Rational Developer for System z]].
 
==References==
EGL is a target language for modernization of legacy applications because of the language semantics affinity with procedural languages and legacy [[4GL|4th generation languages]]:
{{Reflist}}
* a set of conversion tools available within the [[IBM Rational Business Developer Extension | Rational Business Developer]] product provide automated the conversion from older and stabilized IBM and [[Informix]] [[4GL|4th generation languages]]
* a set of IBM service offerings and complementary products (Rational Migration Extension for Natural, Rational Migration Extension for System i) provide the ability to convert from [[NATURAL|Software AG Natural]] and from [[IBM RPG]] to EGL
 
==Further reading==
Tools for searching large EGL code bases, comparing individual EGL files for changes, and detecting duplicated code are available from [http://www.semanticdesigns.com/Products/LanguageTools/EGLTools.html Semantic Designs]
* Enterprise Web 2.0 with EGL, {{ISBN |978-1-58347-091-6}}.
 
* Developing Web 2.0 Applications with EGL for IBM i, {{ISBN |978-1-58347-089-3}}.
The [http://www.clearblade.com/index.php/solutions/m-katana-egl Katana-EGL Rich UI Framework] from ClearBlade delivers a jump start and rapid prototyping for EGL Web 2.0 and Mobile applications.
 
==External links==
Line 155 ⟶ 173:
* [http://www.eclipse.org/edt/ Eclipse EGL Development Tools (EDT) Project] - an open implementation at [[Eclipse (software)|Eclipse]]
 
{{IBM FOSS}}
==Books on EGL==
* Enterprise Web 2.0 with EGL, ISBN 978-1-58347-091-6.
* Developing Web 2.0 Applications with EGL for IBM i, ISBN 978-1-58347-089-3.
 
 
[[Category:Fourth-generation programming languages]]
[[Category:IBM software]]
[[Category:Scripting languages]]
[[Category:4GL]]
 
[[de:Enterprise Generation Language]]
[[ja:Enterprise Generation Language]]
[[ru:EGL]]