Stereotypes

In everyday use, a stereotype is a pattern of characteristics that you can use to make assumptions about a person. In the Unified Modeling Language (UML; a graphical language for modeling business processes), a stereotype adds characteristic information to a more general pattern.

EGL uses the term in much the same way. In EGL you can specialize a custom part definition by referring to one of a set of predefined stereotypes. Each of these modifiers brings unique properties to a part and triggers different behaviors when EGL uses a variable based on that part.

For example, when you say Record Customer you declare a basic record. You specialize the record by stereotyping it, as follows:
Record Customer type SQLRecord
...
end

When you then declare a variable based on that part, that variable gains properties specific to working with a relational database. Additionally, when you include that variable in an EGL data access statement, the behavior of the statement reflects the stereotyping of the record, such as generating SQL statements from the EGL code.

Syntax

Syntax for a stereotype
part
A Record, Handler, Program, or any other part except a DataItem or Service.
name
A name you assign to part.
stereotype
The list of stereotypes available depends on the part you are customizing.

Feedback