This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
Re: Kawa interface to TreeList?
- To: Jocelyn Paine <popx at pop3 dot ifs dot org dot uk>
- Subject: Re: Kawa interface to TreeList?
- From: Per Bothner <per at bothner dot com>
- Date: 07 Aug 2001 12:55:20 -0700
- Cc: kawa at sourceware dot cygnus dot com
- References: <Pine.LNX.4.10.10108060418040.30103-100000@pop3.ifs.org.uk>
Jocelyn Paine <popx@pop3.ifs.org.uk> writes:
> Are there plans to provide Kawa selectors and constructors for
> manipulating TreeLists? It would be useful for manipulating the
> structures generated by Per's XML parser.
There are a couple of convenient functions for constructing TreeLists.
Here is the limited documentation I just wrote:
- Function: make-element tag [attribute ...] child ...
Create a representation of a XML element, corresponding to
<TAG ATTRIBUTE...>CHILD...</TAG>
The result is a `TreeList', though if the result context is a
consumer the result is instead "written" to the consumer. Thus
nested calls to `make-element' only result in a single `TreeList'.
More generally, whether an ATTRIBUTE or CHILD is includded by
copying or by reference is (for now) undefined. The TAG should
currently be a symbol, though in the future it should be a
qualified name. An ATTRIBUTE is typically a call to
`amke-attribute', but it can be any attribute-valued expression.
- Function: make-attribute name value...
Create an "attribute", which is a name-value pair. For now, NAME
should be a symbol
The xquery implementation used (the Java implementation) of these.
--
--Per Bothner
per@bothner.com http://www.bothner.com/per/