Encoding arbitrary literals in RDF/XML

Dear all,

We're currently discussing a literal serialization issue on the
Sesame/openrdf.org forum[1]. Reason for this discussion is that XML does
not support the full range of Unicode characters. More specifically,
the issue concerns the null character (hex value 0x0). From what I've
learned about Unicode in the past days, I understand that this is a
perfectly legal Unicode character, but the XML specs do not allow you to
include it in an XML document. Support for these kinds of exotic
characters has been increased in XML 1.1, but it still doesn't include
the full range.

A workaround that I have been thinking about is to encode such literals
in hex or base64 and to include an attribute in the surrounding element
that indicates this. This sounds like a bit of a hack, though, and I'm
not sure whether this is completely standards compliant. Therefore, I
would highly appreciate any feedback or suggestions on how to solve this
issue.

Regards,

Arjohn

[1] http://www.openrdf.org/forum/mvnforum/viewthread?thread=241#946

-- 
arjohn.kampman@aduna.biz
Aduna BV - http://aduna.biz/
Prinses Julianaplein 14-b, 3817 CS Amersfoort, The Netherlands
tel. +31-(0)33-4659987  fax. +31-(0)33-4659987

Received on Wednesday, 22 September 2004 14:30:36 UTC