RE: OO and scripting

Subject: RE: OO and scripting
From: "Jonathan Borden" <jborden@xxxxxxxxxxxx>
Date: Tue, 11 May 1999 21:50:26 -0400
Paul Prescod wrote:

> Dave LeBlanc said:
> > I personally think <script> ought to be in XML itself - I can imagine
> > using it to allow a document to convey (via it's DTD for example) how
> > a receiving processor is supposed to manipulate it. Very object
> > oriented.

	David is having a very hard time understanding XSL. There is nothing
preventing anyone from scripting the DOM via Javascript and hence performing
whatever iterative processing is desired. XSL does not prevent this, despite
his protests. Perhaps the problem is in the understanding of machines and
languages in general. An excellent general text about how to think about
programming and machine languages is: Structure and Interpretation of
Computer Programs by Abelson and Sussman, MIT Press.

	I quote:

"We must constantly turn to new languages to express our ideas more
effectively. Establishing new languages is a powerful strategy for
controlling complexity in engineering design; we can often enhance our
ability to deal with a complex problem by adopting a new language that
enables us to describe (and hence think about) the problem in a different
way,..." p. 359

> I have been told that Tim Berners-Lee was late for a keynote at one of the
> early WWW conferences because he was in a big argument with Alan Kay (of
> Smalltalk fame). Alan was trying to convince him that the Web was totally
> broken and should instead be based on intelligent objects floating between
> servers, sort of like RMI or a big, distributed smalltalk engine.
> I wasn't there but I see this story as incredibly important because it
> demonstrates the two different views of the world. On the one side is
> Alan, data and code are the same -- mix'em up. On the other side is Tim,
> data is data, code works on data. Code can be viewed as data but should
> not be mixed with the primary data.

	And quote again:

"It is no exaggeration to regard this as the most fundamental idea in

	The evaluator, which determines the meaning of expressions in a programming
language, is just another program." p. 360

	Code is data which conforms to a specific language defined by the parsing
rules of the language. An XML document is data in a language which conforms
to the schema of the document. The problem with such code is not that it is
code (because code is just data), rather that the parsing rules for the
particular language are often contained in a binary blob (a compiler or
interpreter) or a silicon wafer (a processor). Part of why I see as a great
hope for XML is that it is the closest thing we have for a common syntax ...
i.e. one parser, one DOM.

	XSL itself is great not because it has anything particularly new to add to
the field of transformation languages, or styling languages, not to
criticize the efforts *at all*, rather because it accomplishes, or is
intended to accomplish this within the common syntax of XML. For example,
given DSSSL, what is the need for XSL except that it is XML?

	The idea that there is any real difference between 'agents' which are just
documents/files containing executable instructions and data, and say HTML
files, which are just documents containing data and frequently executable
instructions e.g. Javascript, escapes me.

Jonathan Borden

 XSL-List info and archive:

Current Thread