Hi Brian,
I don't think it's documented but you should be able to set a grammar pool
on the DOMConfiguration, something like:
Document document = ...;
DOMConfiguration config = document.getDomConfig();
org.apache.xerces.xni.grammars.XMLGrammarPool pool = ...;
...
config.setParameter("
http://apache.org/xml/properties/internal/grammar-pool", pool);
config.setParameter("validate", Boolean.TRUE);
...
"Brian Nielsen" <[EMAIL PROTECTED]> wrote on 05/07/2005 07:27:01 AM:
>
> I've used both caching grammars in a grammarPool and XML Schema
validation
> of in memory documents with DOM Level 3 'normalize', but I can't figure
out
> how to combine these. I want to create a Web Service handler for Axis,
that
> is initialized with a grammarPool, which is used to validate the
> request/response messages. By doing this the performance overhead of
parsing
> the grammars are done only once, and it can be used as a 'cheap XML
message
> firewall'.
>
> The easiest way would be to add the grammarPool to the domConfiguration
for
> the in memory document, but I've only found the 'schema-location'
property.
>
> Thanks for any advice in advance.
>
> Brgds Brian
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: [EMAIL PROTECTED]
E-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]