[devintroduction0]    Introduction

The OpenBUGS software is writen in the language Component Pascal (CP) a slight refinement of Oberon2 which is an object orientated developement of Modula2. Like Modula2 CP is a modular programming language, each module having a well defined interface. CP is a type safe garbage collected language with features in common with Java. CP software consists of a number of modules that are loaded and linked as needed at run time. The tools to develope CP software are available (free of charge) from Oberonmicrosystems at www.oberon.ch. They are called "BlackBox". The OpenBUGS software has been developed with version 1.5 of the BlackBox tools. The BlackBox distribution contains a component framework of precompiled CP modules, a complete description of the CP language plus an extensive tutorial on the use of the BlackBox tools. OpenBUGS and in particular its graphical user interface WinBUGS makes heavy use of the the BlackBox component framework. The BlackBox tools are unique to Windows but can be run under WINE on Intel based Linux computers. CP source code can also be compiled to Java Byte Code or .Net assemblies using alternative tools from GardensPoint at www.citi.qut.edu.au/research/plas/projects/cp_files/index.jsp .

There are two versions of the OpenBUGS software on the web: the runtime version and the source code version. If you just want to run OpenBUGS the runtime version is all you require. If you want to understand OpenBUGS and develope / modify the software you will need the source code version plus the BlackBox tools.

The OpenBUGS software consists of a (large) number of files organised in a set of subsystems. The current OpenBUGS software contains the following subsystems: Bugs, Compare, Correl, Deviance, Doodle, Graph, Html, Lindev, Maps, Math, Monitors, Plots, Ranks, Samples, Spatial, Summary, Updater plus the Examples and Manuals subdirectories. The runtime version of the OpenBUGS software also contains the BlackBox subsystems Form, Host, Ole, Std, System , Text, Win and Xhtml from Oberonmicrosystems. The source code and documentation files for these subsystems are included with the BlackBox tools.
Oberonmicrosystems has made BlackBox available under the Lazy Cat open source license.

Subsystem usually contains five subdirectories /Mod, /Rsrc, /Code, /Sym and /Docu. The "source" code of OpenBUGS consists of two type of file: the CP source code in subdirectories /Mod and the resources in subdirectories /Rsrc. The resource directories contain such things as dialog boxes, menu systems, error messages and configuration files. The run time code of BUGS consists of compiled binary code files in subdirectories /Code and the same resources (as the source code) in subdirectories /Rsrc. The /Code subdirectory contains the compiled binary code in a form akin to dynamic link libraries called ocf files (Oberon code files) but also includes extensive meta information. The /Sym subdirectories contain the interfaces for the CP modules in machine readable form called osf (Oberon symbol files). Both the ocf and osf files are produced by the compiler from the CP source code.The interface of a module is specified in the source code using a simple mark up language. If a CP module imports another module the symbol file of the imported module is needed by the compiler. The symbol files are not needed to run the BUGS software and conversely the ocf are not needed to compile the CP source code but are needed to run the BUGS software. The /Docu of a subsystem contain software documentation.

The source code and documentation for the OpenBUGS software is in odc files (oberon document files), the native document format of BlackBox. This document format can be translated automatically into HTML or ascii.

BlackBox uses the subsystem name as a prefix to the module name and uses this prefix to determine the physical location of the module in the file system. For example the module SamplesIndex has CP source code in file Index.odc in subdirectory Samples/Mod and when compiled will produce the code file Index.ocf in subdirectory Samples/Code and and the interface file Index.osf in subdirectory Samples/Sym. The documentation for the module SamplesIndex should be called Index.odc and placed in subdirectory Samples/Docu. The BlackBox developement tools use this prefix naming convention to locate relevent information.