Re: Scripts with Saxon

Subject: Re: Scripts with Saxon
From: Mike Brown <mike@xxxxxxxx>
Date: Thu, 29 Jun 2000 13:17:56 -0600 (MDT)
> I need to do some processing of data in an XML file.
> The data is an image stored as HEX - i.e. every byte
> is encoded as 2 hexadecimal digits.
> With a little help (actually a lot) from this list
> I have outputted the data to a file which is processed
> afterwards with a C-program.
> Now I would like to know if it's possible to accomplish
> this processing within a stylesheet.
> I've been told that this is possible with MSXML
>   1 Is that true?
>   2 Can it be done with Saxon?

I doubt it. The translation of pairs of characters to placeholder
characters that, when serialized, will be the bytes you want doesn't sound
too difficult in theory. But since the trees are XML-based, they
technically aren't allowed to contain those certain characters that are
not allowed in XML documents, i.e. U-00000000 through U-00000008, which
you'd pretty much need if you're going to use them as placeholders for
0x00 through 0x08 bytes, for example.

However in practice I'm not sure how Saxon would behave if you used an
extension function to produce a String that contains the disallowed
characters. Would it let them exist in the string object in the result
tree? If so, how would it serialize them, with the text output method?
Does the spec say anything about it?  Mike Kay? Halp!

   - Mike
Mike J. Brown, software engineer at         My XML/XSL resources: in Denver, Colorado, USA 

 XSL-List info and archive:

Current Thread