commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simon <>
Subject Re: Digester API doubt
Date Wed, 21 Nov 2007 22:44:20 GMT

On Wed, 2007-11-21 at 08:21 -0800, akiraleon123 wrote:
> Hi All,
> Hopefully this should be an easier one.
> I am using digester rules in the form of an xml file. Also, i have an
> xmlfilter that i need to feed into the digester. So, i need to have an API
> that accommodates both the URL for rules and the xml filter.
> There is no setter for xmlreader/filter or to the URL on Digester. I 'd
> appreciate if you can let me know of a way.

When using the plain Digester java API, this can be done easily.

As I mentioned earlier, Digester is just a SAX event handler. You can
create a parser instance yourself using the normal JAXP apis and
configure it however you want (including filters etc).

When everything else is configured, set the digester instance as the
event handler for that parser instance then tell the parser to start

I haven't done this with xmlrules as I don't use it much. But it looks
like xmlrules.DigesterLoader.createDigester will parse a config file and
return a configured Digester instance ready for passing to a parser.



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message