Weeeelll.
I believe that if you really wanted* to do this then you
might be able to do it by generating XMLDocumentHandler events
and plugging an XMLSchemaValidator into the back of your
generator.  You could* then plug a ContentHandler into the
back of that, but you're getting extremely xerces specific
and I still question the wisdom of the approach...  In your
original message you asked about an "identity transformation".
What did you mean by this?
Regards,
Huw

*I've never tried this and I would definitely not do it 
myself.



-----Original Message-----
From: Verachten Bruno [mailto:[EMAIL PROTECTED]
Sent: 04 January 2005 09:18
To: [EMAIL PROTECTED]
Subject: RE: Using Xerces as a validating parser with SAX events


Hi,

> When you say you "will modify it so that it generates SAX events"
> I guess you mean that you are going to remove the functionality that
> currently generates XML as text.  I guess you want to do that for
> performance reasons(?) or because you have some other downstream
> processing that you want to connect to(?).

In fact, I want to keep the functionality that generates XML as text,
but I want to be able to check (while generating) that the XML I
generate is valid against a schema.
I thought that generating SAX events on top of that was a good way to
plug a validating parser in.

> To get down to code for a moment (always clearer I think), suppose
> you have an object "fred" and a class that generates XML (Generator).
> I suppose at the moment you do something like:
[...]

> and somehow get a SAX validator involved.  Frankly I wouldn't 
> try this, it appears to be a huge amount of effort for marginal
> benefit (unless I'm missing something in what you are trying
> to achieve).  
I just don't know, I thought it was something easy that I just
couldn't find.

Anyway, thanks for your mail.

Bruno Verachten

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to