All kind of functionality is available as commands. As a model you can think of them as the commands you can enter on the shell. commands implement the basic or atomic functions of a software package. Business processes are a kind of scripts, which combines several commands to an application.
Commands are the building blocks of your application. Commands will be available in several versions: as a real shell command line command. As a C-function, as a window. All of these versions are based on the same C-function. They represent just different user interfaces.
Because of the shell user interface it is possible to write bash-scripts, which combines the commands of your application. This makes it easy to write batches or test scripts.
Commands can be combined in traditional C-code and in a pipe fashion. They also can be combined with GNU/Linux commands inside a C-program. Although this is less efficient, because the GNU/Linux command will start its own process, it allows you to combine your commands with everything already found on GNU/Linux.
Commands have three data structures to handle:
Command can have both input and output, then called filter. They can have no input then called source. Or they have no output, called sink. Commands having neither input nor output are called function.
An application can use sequencing of commands. That is one command is executed and then another is executed independently of the former one.
Another way to combine commands is to pipe them: in this case the output of the first command is automatically handled by the second command as input.
Command con work in single record or in list mode. In single record mode only one instance of the input and/or output data is handled. In list mode many input/output records are handled.
Data commands are commands that read data from outside the application or write data to the outer world. For each data structure there are commands to retrieve data corresponding to such a structure and those writing data for this structure. The simplest way to think of the world outside the application is to think of files. Writing data records to a file writes this data out off the application. For each data structure there is a data command to read this kind of data from and to a file.
For the same data structure the data can be written in various formats: Fixed length records, comma separated data, XML and others. But Berkeley DB, mySQL and other databases are just other formats of the same data structure handled by the same data command. Which format is chosen is controlled by options.
So the data structure is the logical description of one data record. The data format is the way one record is read or written. Sometimes the data format is also called data base.
For example, if their is a data structure named address. Then there are the data commands readAddress and writeAddress. When using the command line interface you can load a comma separated file into a Berkley DB by:
readAddress --commaSeparated | writeAddress --berkleyDb
Here piping of the shell is used and is possible, as for each command there is a command line version. Used inside a C program piping is conceptually the same, but is used with a different syntax. And it will not create additional processes.
A special place to write data to and read it from is a humans brain. To read/write data in/from brains, data commands have special data formats called brain format. Brain formats are GTK, curses and HTML. Thus you can also say: a brain format is a window or a screen. There is a special command line brain format, which prompts a user for data input for reading. It writes data to stdout using syntax highlighting like ls --color.
So:
readAddress --mySql | writeAddress --brainGtk
will display an address in a gtk graphical window in single record mode, and display a list of addresses in a graphical window in list mode.
Hence windows are just a special form of a data base or data format, to which data is written or read from.
All data formats and all modes are automatically generated out of a data record specification.