4.4 Editing at Group Level

4.4.1 Group Editing

Manipulation of the fragment group structure is done in the group editor. It is possible to insert or delete fragment forms, modify the names of the fragment forms, or edit the properties of the fragment group e.g. the ORIGIN, INCLUDE and BODY properties. Editing of properties is done using a property editor that is a structure editor on the properties. This editor is activated by means of the 'Fragments:Edit ORIGIN, INCLUDEs etc...' command.

4.4.2 Fragmenting

The fragment system provides facilities for splitting a BETA program into several parts in order to support separation of interface and implementation, variant configuration or separate compilation. The code editor supports this kind of fragmenting.

If, for example, a fragment form is going to be divided into an interface part and an implementation part the, SLOTs menu is very useful. Consider the small program hello:

Figure 32

[15kb 731x566 GIF]

Let say we want to create a BODY file called 'hellobody' that contains the DoPart of the hello pattern. First we create the BODY file using the 'SLOTs:Create Implementation File...'.

Figure 33

[15kb 731x566 GIF]

Notice that this new file has ORIGIN in hello. If we double-click on this ORIGIN, we return to the hello file, and we see that the property: 'BODY hellobody' has been inserted.

Figure 34

[16kb 731x566 GIF]

Now we are ready to hide the implementation of the hello pattern. This is done by means of the 'SLOTs:Hide Implementation...' command. For each DoPart in the selection you are asked whether to create a DoPart SLOT and move it to the BODY file.

Figure 35

[3kb 303x148 GIF]

We accept and the result is:

Figure 36

[16kb 731x566 GIF]
and the BODY file looks like:

Figure 37

[16kb 731x566 GIF]

There are alternative ways to fragmentize BETA programs in mjolner.


Mjolner Integrated Development Tool - Tutorial
© 1991-2004 Mjølner Informatics
[Modified: Monday March 11th 2002 at 16:16]