xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel López <D.Lo...@uib.es>
Subject Re: svg-20001102.dtd not found. (I give up)
Date Fri, 17 Aug 2001 07:32:56 GMT

If anyone finds an answer to this problem, I would really appreciate it
if he/she sent it directly to my as I've given up and I'm also
unsubscribing from the list. It seems to be a problem with the entity
resolver that the parser is using, I have even tried to follow the
problem in batik source but I don't have the time to track this down
myself with the scarce knowledge that I have about how it works.

Daniel López wrote:
> Hi,
> I'm trying to process an SVG file inside a servlet to show a JPEG image
> and after dealing with a couple of XML parser incompatibility issues,
> I've stumbled into this error. When I process the SVG file, a sample
> file provided with the batik-1.1rc, I get the error:
> java.io.IOException: File
> "jndi://D_/Apps/Test/Test/Test/WEB-INF/lib/batik-svg-dom.jar/org/apache/batik/dom/svg/resources/svg-20001102.dtd"
> not found.
> The file batik-svg-dom.jar is in the classpath and it is exactly in
> D:/Apps/Test/Test/Test/WEB-INF/lib/, I also checked to see that the dtd
> file is in there and indeed, it is. Any clues?
> This is how I'm processing the file, extratec from the sample files and
> some messages from this list archive:
> //****
>    // create a JPEG transcoder
>    JPEGTranscoder t = new JPEGTranscoder();
>    // set the transcoding hints
>    t.addTranscodingHint(JPEGTranscoder.KEY_XML_PARSER_CLASSNAME,
>                         "org.apache.crimson.parser.XMLReaderImpl");
>    t.addTranscodingHint(JPEGTranscoder.KEY_QUALITY,
>                         new Float(.8));
>    // create the transcoder input
>    SAXSVGDocumentFactory svgFactory = new
> SAXSVGDocumentFactory("org.apache.xerces.parsers.SAXParser");
>    String svgNS = SVGDOMImplementation.SVG_NAMESPACE_URI;
>    // Input is the sample file batik3D.svg, read as an InputStream
>    Document document =
> svgFactory.createDocument(svgNS,xmlSource.getInputStream());
>    TranscoderInput input = new TranscoderInput(document);
>    // create the transcoder output
>    response.setContentType("image/jpeg");
>    TranscoderOutput output = new
> TranscoderOutput(response.getOutputStream());
>    // generate/show the image
>    t.transcode(input, output);
> //****
> Any clues what might be going wrong?
> Thanks in advance,
> D.

To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-users-help@xml.apache.org

View raw message