Identifiers (or names) are created by a declaration. They are referenced by various statements. EXPRESS does not require declaration before reference, therefore the reference can come after or before the place where the declaration is given. The usual way of referring to a thing is to simply write its name. However, there are situations where a more elaborate reference — called a qualified reference — is needed. Some qualified names can be quite long. The Alias statement (13.2) can be used to simplify matters when the qualified name gets too clumsy to work with conveniently. A scope is a region of the source within which a name is visible. References to a name are legal in its scope but are illegal outside it. Scopes can be thought of as boxes nested within other boxes as illustrated by Figure 12.1. EXPRESS assumes that there is a giant box called the ‘universe’ which surrounds every other scope. All of the standard identifiers (Integer, Real... Abs, Usedln...) and all schemas are in the scope of the universe. As an example Figure 12.2 gives an inventory of the full names of the things shown in Figure 12.1 (but note that ‘universe’ is never specifically written). Although it may seem that some of the ‘given’ names are duplicates (AnAttribute for instance), when the full name is written out every name is unique. Name uniqueness is a requirement of EXPRESS. Peer names are visible to one another. The picture shows peer names as the ones inside the same box. The same effect is shown in the inventory by tracing common name elements from left to right until a name difference is found. Peer names are the ones at the level where the difference occurs. Visibility to other names starts at some point in the name chain. Every name along the path (reading from right to left) and their peers are visible. In the picture, start inside some box and jump outside. The names in that outer box are visible. Then jump to the next outer box, etc., until there are no more outer boxes. As an example, ASchema. AnotherEntity. AnotherAttribute (‘Universe’ will no longer be used) can ‘see’ the things shown in Figure 12.3. In fact, references can to their simple names can be used.
Oxford Scholarship Online requires a subscription or purchase to access the full text of books within the service. Public users can however freely search the site and view the abstracts and keywords for each book and chapter.
If you think you should have access to this title, please contact your librarian.