1. The idea
1.1 Graphical representation of a program
1.2 A flat view ?
1.3 A dead end
1.4 Cheating ?
1.4.1 Adding functionality
1.4.2 Object orientation
1.4.3 Fiddling with function pointers
1.5 Context oriented programming
1.5.1 Sharing information within a level
1.5.2 Calling a function from a lower level
1.5.3 Definition of a level or a tree
2. Building blocks
3. Reusing modules in different context
Top Up

1.5.3 Definition of a level or a tree


The first level in our graph is made of 4 components: The main module the dialog module, the report module, and the printing module.

In fact, except for the main, none of the other modules are really part of the level. They are called in this level and play together but each of them is defined in its own tree, generally one or more level below.

So what is a level. The level is defined by the following components

  • The collection of modules used in the level. Well, not the collection, but way they are used.
  • The information only visible within that level. Think of a level as a simple function with local variables.
  • The glue used to interconnect the modules together. This glue is made of C++ code.
Top Up

One big HTML document