<HTML><FONT FACE=arial,helvetica><FONT  SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0">Strangely Noel's reply was the first I saw of MJR's message, though<BR>
I have not read his original post as well, via the list's archive.<BR>
<BR>
In a message dated 7/26/2002 10:06:51 AM Central Daylight Time, noelwelsh@yahoo.com writes:<BR>
<BR>
<BLOCKQUOTE TYPE=CITE style="BORDER-LEFT: #0000ff 2px solid; MARGIN-LEFT: 5px; MARGIN-RIGHT: 0px; PADDING-LEFT: 5px">--- MJ Ray &lt;markj@cloaked.freeserve.co.uk&gt; wrote:<BR>
&gt; &gt; The WebIt! collection supports the creation and<BR>
&gt; processing of XML, HTML, and <BR>
&gt; &gt; CSS using Scheme. The core of WebIt! is RS-XML, an<BR>
&gt; abstract datatype for XML.<BR>
<BR>
I'm interested in WebIt! as a replacement for the<BR>
hacky syntax-case transformation system I have put<BR>
into SchemeDoc (yes MJ, I'm still working (slowly) on<BR>
it!)</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0"></BLOCKQUOTE><BR>
<BR>
</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0">Great!<BR>
</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0"><BR>
</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0"><BLOCKQUOTE TYPE=CITE style="BORDER-LEFT: #0000ff 2px solid; MARGIN-LEFT: 5px; MARGIN-RIGHT: 0px; PADDING-LEFT: 5px">Some docs on the schema definition part of the<BR>
library would be nice.&nbsp; I have no intention of writing<BR>
an XML Schema for SchemeDoc just to translate it into<BR>
Scheme!</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0"></BLOCKQUOTE><BR>
</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0"><BR>
</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0">That is one big hole right now in the library's documentation. I will<BR>
fix that this weekend.<BR>
</FONT><FONT  COLOR="#000000" style="BACKGROUND-COLOR: #ffffff" SIZE=2 FAMILY="SANSSERIF" FACE="Arial" LANG="0"><BR>
<BLOCKQUOTE TYPE=CITE style="BORDER-LEFT: #0000ff 2px solid; MARGIN-LEFT: 5px; MARGIN-RIGHT: 0px; PADDING-LEFT: 5px">&gt; I sent you some queries about this, especially<BR>
&gt; asking how it compares to<BR>
&gt; SSAX-SXML and the match.ss currently in PLT-Scheme. </BLOCKQUOTE><BR>
<BR>
Noel is dead on with both comments. I'll add a few other points:<BR>
<BR>
re: match--<BR>
A difference between my matcher and match.ss<BR>
is that I specify the pattern in terms of the data constructors,<BR>
match.ss specifies the pattern in terms of the data. With s-exprs,<BR>
you would write an xml-rules pattern for a list as (cons ,v1 (cons ,v2 '()),<BR>
rather than (,v1 ,v2). Now obviously you would never want to write<BR>
patterns for lists this way (in terms of cons calls), but for XML, you would <BR>
never want to have to write the pattern in terms of the underlying data<BR>
structure. First, it would be less natural looking-- the underlying data<BR>
is actually a tree of structures. Second, you would expose really ugly<BR>
things, like namespace urls. I had originally thought to extend either<BR>
PLT's match or the Indiana match to use WebIt!'s constructor's as<BR>
pattern for matching XML, but in the end I liked the syntax-rules style<BR>
of patterns better.<BR>
<BR>
Noel, I think, stated what is really the big philosophic difference between<BR>
SXML and WebIt!- the generated constructors versus the more dynamic<BR>
s-expr representation of SXML. But a few other comments:<BR>
<BR>
SXML and WebIt! are very similar ADT's for XML- though with very<BR>
different concrete types. One thing I do not have is an equivalent of SXML's<BR>
auxillary nodes, though I have not had a need for them yet. I could probably<BR>
have used SXML as the underlying data type beneath WebIt! constructor's.<BR>
But I really prefer working with structures instead. It bothers me that once<BR>
(href "something") has been extracted from a (@ ...) node, there is no way<BR>
to tell whether it is an attribute or an element. In WebIt!, there are separate<BR>
structures: xml-attribute and xml-element. On the other hand, SXML can<BR>
be a much more compact representation- which could matter a lot when you <BR>
are dealing with megabytes (or gigabytes?) of XML.<BR>
<BR>
As a "surface API" one of the benefits of WebIt! is it's treatment of XML namespaces.<BR>
Elements and attributes are always constructed to include their expanded names<BR>
(e.g. {http://w3c.org/schemas/html}:a), but these inconvenient namespace uri<BR>
are hidden away behind a constructor like h4:a. Working with expanded names in<BR>
an s-expression-based SXML is nasty, and yet so is using namespace prefixes:<BR>
depending on the mapping of prefixes to uri's (somewhere else in the SXML tree),<BR>
a:tag and b:tag could in fact be the same element type. In WebIt!, comparisons<BR>
and matching are always in terms of the expanded names. namespace prefixes<BR>
are significant only in *output* of XML.<BR>
<BR>
SSAX is another matter. It is *the* XML parser. WebIt! currently does not have a <BR>
parser- though a parser was the first thing I wrote (a year and a half ago). The plan <BR>
is that I will create a WebIt! instantiation of SSAX, along the lines of the SSAX-&gt;SXML<BR>
parser, but producing WebIt! structures. (By the way- if you are interested in<BR>
using WebIt! but need an XML parser, write to me. You might get this moved up<BR>
my to-do list!)<BR>
<BR>
Jim<BR>
</FONT></HTML>