Getting Started with Elisa

Using EDS




Language Description

1. Lexical Elements
2. Basic Data Types and Expressions
3. Definitions
4. Streams
5. Backtracking
6. Statements and Special Expressions
7. Arrays
8. Lists
9. Descriptors
10. Components
11. Collections
12. Generic Components
13. Terms
14. Categories
15. Types 

16. Built-in Definitions
17. Higher-order Definitions

18. External Interfaces


Data Structures

1. Sequences
2. Examples involving Lists
3. Trees
4. Graphs
5. Searching State Spaces
6. Language Processing
7. Knowledge Representations          



1. Introduction
2. What are Domain Definitions?

3.  Sorts of Domain Definitions

4.  Manipulations of Domain Definitions

5.  Translating Domain Definitions

6.  Dialogue Sessions

7.  Example of Concentric Circles

8.  Example of Domain Substitution applied to Concentric Circles

9.  Example of an Order Processing Application

10.Example of an Airport Information System

11.Example of a Rental Boat Business

12.Benefits of Domain Definitions


Back Home Up Next

6. Dialogue Sessions

Based on the skeleton program we are able to set-up a dialogue session with the system. In our case this will be a dialogue with the Elisa Development System. Because we start with an “empty” program we need first to feed the system with some information about a specific application. In following steps we may use this information in dialogues with the system. To demonstrate these steps we will return so our Family application.  Because the skeleton program is still very general we need to feed it with data about a specific family. (Figure 3 ).  

include “Family.txt”;

father = newPerson(“John”, “04-10-1965”, Male);

mother = newPerson(“Liza”, “08-05-1968”, Female);

child1 = newPerson(“Ann” , “20-07-1994”, Female);

child2 = newPerson(“Peter”,”15-03-1998”, Male);

children = {child1, child2};

family1 = newFamily(father, mother, children);  

Figure 3:  Specific Family Data

The first line of the session indicates that the skeleton program as generated by the metaprocessor should be included in the program.

   The following lines contain calls of  functions that are defined in the skeleton program (see Figure 2). For example, newPerson and newFamily are defined in the skeleton program. Curly brackets { } are used to collect elements in a list.

   After feeding the system with some basic information about a Family we can now ask the system what it knows about the family by querying the system with: family1?    

   The answer is shown in Figure 4. The result is a Family-tree showing the structure of the tree and its contents.  

include "Family14.txt";
father = newPerson("John", "04-10-1965", Male);
mother = newPerson("Liza", "08-05-1968", Female);
child1 = newPerson("Ann" , "20-07-1994", Female);
child2 = newPerson("Peter","15-03-1998", Male); 
children = {child1, child2};
Fam1 = newFamily(father, mother,children);
Family:[Father = Person:[Name = "John";
                         BirthDate = "04-10-1965";
                         Sex = Male];
        Mother = Person:[Name = "Liza";
                         BirthDate = "08-05-1968";
                         Sex = Female];
        Children = { Person:[Name = "Ann";
                             BirthDate = "20-07-1994";
                             Sex = Female], 
                     Person:[Name = "Peter";
                             BirthDate = "15-03-1998";
                             Sex = Male]}]

Figure 4: Querying the system with: family1?

Based on this information the user can now answer questions like: Are the data structures right? Are the values right? This exercise shows how the system gives formatted output based on the information gathered by the metaprocessor, the compiler, and the run-time system. This facility provides high-level debugging and verification support and is of great help in the testing and maintenance phases. 

Back Home Up Next

  Part 6: Metaprogramming   Dialogue Sessions


Home | Highlights of Elisa | Integrating Different Paradigms | Getting Started with Elisa | Demo's  | What is Domain Orientation | Bibliography | Copyright | News | Contact | Contents

Language Description:

Lexical Elements | Basic Data Types and Expressions | Definitions | Streams | Backtracking | Statements and Special Expressions | Arrays | Lists | Descriptors | Components | Collections | Generic Components | Terms | Categories | Types | Built-in Definitions | Higher-order Definitions | External Interfaces | Index 

Data Structures: Sequences | Examples involving Lists | Trees | Graphs | Searching State Spaces | Language Processing | Knowledge Representations
Domain Modeling:

Domain Modeling | Concepts | Domain Definitions | Domain Operations | Domain Implementations | Systems | Case study: an Order processing system | Case study: an Airport Support system | Domain Orientation versus Object Orientation

Design Patterns:

Introduction | Abstract Factory | Builder | Factory Method | Prototype | Singleton | Adapter | Bridge | Composite | Decorator | Facade | Flyweight | Proxy | Chain of Responsibility | Command | Interpreter | Iterator | Mediator | Memento | Observer | State | Strategy | Template Method | Visitor 


click tracking

This page was last modified on 19-05-2015 14:30:33   

free hit counter