BlackBox Resources

Component Pascal is a clean, light-weight, object-oriented language suited to component software development. The BlackBox Component Framework (BCF) is a cross-platform development platform targeted to Windows 3.1/95/NT and Macintosh architectures. Commercial and free education versions of BlackBox Component Builder are available from Oberon Microsystems.

The following software is available here:


Non-blocking TCP Streams Module

This module implements true non-blocking TCP streams using the CommStreams framework. The reference implementation (CommTCP) is only non-blocking AFTER a connection has been established, and can block the framework for a significant time during the establishment of a TCP connection. In some situations (eg. web proxy servers) this is unacceptable.

The solution to this problem is to use the asynchronous functions provided by Winsock. Module CommTCPAsync allows TCP host-name resolution and connection establishment to be performed as background tasks. This is done in a way that is compatible with the CommStreams framework.

BlackBox StdCoded File (26K)


Port of the Coco/R Compiler Compiler

This is a port of Hanspeter Mössenböck's Coco/R system. Coco/R is a language for generating compilers from attributed EBNF grammars. This can best be described as a "conservative" port: since the original code did not use type-bound procedures, it is almost entirely compatible with the syntax of Component Pascal. However, it is written for a classical Oberon system (V4 Oberon) and so relies on modules that are not part of BCF.

Instead of re-writing Coco, I have implemented equivalents of the Oberon Text modules that use BlackBox TextModels. This means that the entire port requires only a few changes to the original source files.

This distribution includes two papers by Mössenböck (in postscript format) which are essential reading in order to understand the system. Please see the additional comments in the file Coco/Docu/Coco. For more information on Coco/R, see:

BlackBox StdCoded File (328K)

HTTP Client and Server Utilities

This is a collection of modules for creating HTTP servers and clients. It provides low-level buffering of network streams, allowing ASCII files to be easily sent and retrieved via a TCP/IP channels.

An unusual feature of the HTTP server implementation is that a single server can function both as origin server and proxy server. I developed this design to allow me to experiment with dynamic document rewriting. An intelligent proxy can dynamically create content as the user explores the web and merge this content with external HTML docuemnts "on-the-fly" as they are retreived. Here is an example of this sort of application.

Note that this is not a "quality" release, as I haven't had time to properly structure and document many functions. This code has served its purpose and will not be developed further (by me, anyway). However, the server functions are reasonably modular. New facilities can be added fairly easily by implementing HTTP.Handlers and HTTP.Filters. See Dbu/Docu/Manual for more details.

Gzipped Tar File (41K) (for Blackbox 1.3, updated 27/04/2000)
Gzipped Tar File (41K) (for Blackbox 1.4 beta release, updated 11/06/2001)
Blackbox StdCoded File (56K) This patch to the 1.4 beta version gives 1.4 release compatability (contributed by A. McIntosh).


PrivGraph - Display and manipulate directed graphs

I developed this code for a serious application, but it can also be a lot of fun to play with.

This view implements an automatic layout of directed graphs using a force-directed placement algorithm. The algorithm is fast enough to give real-time layout for up to a few hundred nodes on a CPU with hardware floating-point support. Layout is performed in a 3 dimensional volume; optionally, this may be constrained to a 2 dimensional plane. The display volume can be rotated, nodes can be moved, and new nodes and edges can be added using the mouse.

This view demonstrates a few interesting features of the Blackbox framework.

It may also be a useful example for someone interested in displaying or manipulating 3D data. See Priv/Docu/Graph for details. Before extracting the included files, please check that they don't overwrite any of your own Priv files (eg. source code or Priv/Rsrc/Strings).

Blackbox StdCoded file (48K)


RemoteCompiler - Operate the Blackbox compiler via HTTP

The Blackbox compiler and linker are normally invoked by the user within a graphical environment. Unfortunately, the interfaces to these processes are not consistent. This makes it difficult to build Component Pascal software without a significant amount of intervention by the user (ie. lots of selecting and clicking with the mouse).

This package implements a HTTP interface to the Blackbox compiler and linker. A remote-compiler server runs as a background task within the normal Blackbox graphical environment. A command-line client utility allows requests to be POSTed to the server via HTTP. If server and client share common source and target directories (eg. they are on the same machine), the "make" utility can be used to automate the production of software. The client is written in standard "C" and so can be used on platforms such as Win32 and Unix (tested under the Cygwin environment and Linux).

For documentation see, "cpc/readme.txt" and "Priv/Mod/RemoteCompiler.odc".

Blackbox StdCoded Server source (10K)
Gzipped Client Source and Executables (218K)
This package also requires the Dbu Subsystem.


Last Updated 14 November 2001