Askemos 2000 (Archive)
home · features · download · archive
BALL · DSSSL · NameSpaceDSSSL · SXML · XML
AskemosServer · LLD · SXML · XPath · test

SXML

See also http://www196.pair.com/lisovsky/xml/index.html This code needs myenv-rscheme.scm and catch-error.scm

(C) public domain - see: http://www.geocrawler.com/archives/3/15235/2002/1/0/7705636/

BALL makes SXML is available in NameSpaceDSSSL. When DSSSL expressions return SXML conformant data these are expanded in the internal representation. Please note, that the expansion incures an additional traversal of the data. This and the prefix-embedding of SXML might incure undesired preformance loss. SXML elements may only ever occure as return value, not mixed as "inner" data structures. To expand the latter use (sxml sxml-tree). However it is possible to mix ordinary XML result tree fragments, e.g., as returned by make element or xsl-variable among SXML nodes.

For turtorial see: http://schematics.sourceforge.net/scheme-uk/xml.html and http://sjamaan.ath.cx/temporary/sxslt.pdf Note: be careful the sxpath functions are not optimal. When in doubt concerning performance try to get along with the DSSSL functions. They are faster.

Bugs

The sxml implementation in ball failes on annotations (namespace declarations) given at the document root (*TOP*) level: namespace declarations for these declarations are only included in the result tree, if the position of the annotations is specified:

          
(sxml '(*TOP*
        (@ (*NAMESPACES* (foo "http://foo.org/foobar")))
        (foo:bar (@ (@))
          (zoo:baz (@ (@ (*NAMESPACES* (zoo "http://foo.org/foobaz"))))))
        ))

         

results in

<foo:bar xmlns:foo="http://foo.org/foobar">
 <zoo:baz xmlns:zoo="http://foo.org/foobaz"></zoo:baz>
</foo:bar>

while

(sxml '(*TOP*
        (@ (*NAMESPACES* (foo "http://foo.org/foobar")))
        (foo:bar (@)
          (zoo:baz (@ (@ (*NAMESPACES* (zoo "http://foo.org/foobaz"))))))
        ))

is beeing serialised as (note the missing namespace foo)

<bar>
 <zoo:baz xmlns:zoo="http://foo.org/foobaz"></zoo:baz>
</bar>

Since those declarations could go there anyway, it's recommended to put declarations always in the attributes list of the document element.

future of xml

Beware: the XML standard version 1.1 will break SXML, since "Unicode will continue to grow past version 4.0, further changes to XML can be avoided by allowing almost any character, including those not yet assigned, in names".





border
last modification: Tue, 06 Feb 2007 13:17:21 +0100
authors: Adc5dd0c30f6e63932811ed60e019bb2d,
document identifier: A849640f672ed0df0958abc0712110f3c
delivered to Aef0d978f436fb1ff96bdf0b273e983af at Mon, 21 May 2012 23:29:58 +0200
short comments


rss

pdf :: context view

search



24 Apr 2004 DefineInsecureMode
12 Dez 2010 FreeBSD
07 Dez 2010 BALLFeatures
05 Dez 2010 ByzantineAgreement
04 Dez 2010 SQLITE
03 Dez 2010 SRS
12 Okt 2010 WebDAV
12 Sep 2010 SQL
16 Jun 2010 BALL
16 Jun 2010 CouchDB
16 Jun 2010 AskemosServer
07 Mai 2010 SystemRequirements
30 Mar 2010 ProjectsOnThePlate
30 Mar 2010 AskemosResources
30 Mar 2010 RSchemeInstall
30 Mar 2010 INSTALL
30 Mar 2010 ChickenScheme
debug-access.scm
27 Nov 2009 subscriber
development
12 Jul 2009 test
01 Jul 2009 TrustCenter
27 Dez 2008 JKomG
26 Dez 2008 FanOut
26 Dez 2008 MIME
NetBSD
NOTE
02 Mai 2006 AskemosTopMenu
18 Nov 2008 StorageAdaptor
18 Nov 2008 PStoreStorageAdapt
18 Nov 2008 OperationTips
15 Nov 2008 PCRE
04 Nov 2008 ProgrammingLanguag
09 Sep 2008 RelatedProjects
23 Jul 2008 ModuleStructure05
17 Jun 2008 NEWS
17 Jun 2008 HTML
17 Jun 2008 ACM
22 Mai 2008 HTTP
22 Mai 2008 BOSH
10 Mai 2008 AskemosBibliograph
10 Mai 2008 JerrysDreamAbstrac
20 Apr 2008 XSLT
11 Mar 2008 CodingStyle
10 Mar 2008
09 Mar 2008 MIMEConverter
BSD
07 Mar 2008 XML
06 Mar 2008 SRFI
01 Mar 2008 RFC4810
01 Mar 2008 RFC4998






Add


home · features · download · archive