K. Ari Krupnikov wrote:
Is there a Batik equivalent of
javax.xml.transform.sax.TransformerHandler, a class that can accept SAX
events and transcode them into an image?
No, but there isn't much point. Just build a Batik DOM (use our
DOM Implementation) and pass that into the transcoders. SVG has
lots of forward/backward references so it's not like you can just
parse and toss, in general you need the whole tree.
TranscoderInput(XMLReader) doesn't do what I'm looking for -- it takes a
reader and calls parse() on it. What I have is a class (not an
XMLReader) that reports SAX events that correspond to an SVG document,
but there is no way to control when it starts reporting them; there is
no parse() method to call. The class I have is similar to
javax.xml.transform.sax.SAXResult: you can set a content handler, but
you don't control the parsing.
In JAXP, the solution to this is TransformerHandler which implements
ContentHandler, instead of taking an XMLReader in the constructor. I
can't find a similar mechanism in the Batik JavaDocs. Have I overlooked
something? Is there another way to do what I need?
Ari.
---------------------------------------------------------------------
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]