Re: [Fwd: Uses of DSSSL]

Subject: Re: [Fwd: Uses of DSSSL]
From: David Megginson <dmeggins@xxxxxxxxxx>
Date: Sat, 28 Jun 1997 07:34:30 -0400
W. Eliot Kimber writes:

 > I for one see no reason to ever use Perl and NSGMLS again to do
 > non-formatting transforms of SGML documents.  I can do pretty much
 > everything want with Jade's SGML transform back end and do it much faster
 > than with Perl (both in the time it takes to write the code and the time it
 > takes to run).  I have several such processes lying about that I plan to
 > re-implement using DSSSL.

I prefer Jade to Perl for most of my work, but there are still three
compelling reasons to use Perl instead of the current version of Jade:

1. To handle SGML documents larger than about 1/3 of available memory
   (when you're processing the ESIS with Perl, you can construct a
   script which uses memory based only on the depth of the element
   tree, not on its total node count).

2. To add information from other sources (database fetches, Internet
   connections, other programs on the operating system etc.) during
   the transform.

3. To do complex string manipulation based on regular expressions.

The first limitation will disappear when someone creates an on-disk
or database groves implementation for Jade, but in that case, Jade
will run _much_ more slowly.  The third limitation will diminish (not
really disappear) when Jade introduces regular expressions and
auxiliary groves.  

The second limitation is trickier.  It would not be too difficult to
hard-code, say, a specific SQL database client library in Jade, but it
would be useful only for a limited range of users (even ODBC is
useless outside of the MS world, and, some would argue, barely useful
within it).

The typical solution would be to allow Jade to dynamically load
libraries and bind Scheme functions to external subroutines, but in
that case, it would be difficult to keep Jade side-effect free, James
would have to maintain a boat-load of system-specific code for binding
DLLs (one set for Linux, one set for Windows, one set for HPUX, etc.),
and Jade will move from DSSSL-with-extensions to DSSSL-inspired.

What I'd like to see is SDQL functions available from Perl, Guile,
Tcl, etc.:

  use DSSSL::Groves;

  $grove = new Grove("mydoc.sgml");
  $document = $grove.currentRoot();
  $rootElement = $document.nodeProperty('document-element');
  print "The GI of the root element is " . $rootElement.gi() . "\n";

  1;


All the best,


David

-- 
David Megginson                 ak117@xxxxxxxxxxxxxxxxxxx
Microstar Software Ltd.         dmeggins@xxxxxxxxxxxxx
University of Ottawa            dmeggins@xxxxxxxxxx
        http://www.uottawa.ca/~dmeggins

 DSSSList info and archive:  http://www.mulberrytech.com/dsssl/dssslist


Current Thread