HolonU
Database
Structure
Views
Searching
Versions

Database

Holon stores the source in a database/repository

Why?

A program is a (large) collection of similar items. For example: The Holon program contains about 330 procedures and 30 global variables and arrays.

Databases are a good place to store collections. We use databases for our collections of addresses, books, CDs, videos, etc. Why do programmers insist on handling the program units in text files?

Well, not all do: Smalltalk handles OO source and code in a database. I have kept my procedural source and code in a database since 1989.

Handling source in a database can significantly reduce the accidental complexity of programming (F. Brooks).

The database in Holon is a linear list of records with the following fields:

 

Fields in Holon

name -- the name/title of the item.

type -- the type of the item: module, section or unit

comment -- the comment/text of an item.

source -- the source code of a unit.

who -- author of the item

date -- date of last change.

next -- link to next item, see structure.

list -- link to lower level items, see structure.

active -- link to the active item, see structure.

Additional fields for HolonPlus

version -- the current version number of the unit.

changes -- a list of the version numbers of changes.

oldversions -- previous versions of the unit are kept in the database in a separate list. The field points to the end of the list (most recent old version).

test -- stores optional test code for the unit.

Additional fields for the HolonTForth compiler

compcode -- stores executable code, compiler code, or objecttype of a unit.

 

External source files mirror the database

Holon maintains an external source file for every module, in tune with the database. Whenever you add or change a unit, the corresponding source file is immediately updated. Therefore you can at any time load the set of source files into the external compiler/interpreter and test your program.

If you use Holon to write a Tcl program, the source files are created with the extension .tcl. The file name is the name of the module in the browser. If you use Holon for a different programming language, select the corresponding file extension in the setup screen of Holon.

 


Fred Brooks  in "No Silver Bullet: Essence and Accidents of Software Engineering":

"Perhaps the biggest gain yet to be realized from programming environments is the use of integrated database systems to keep track of the myriad details that must be recalled accurately by the individual programmer and kept current for a group of collaborators on a single system."