Re: SVG rasterizer 1.8 - NoClassDefFoundError when exporting PDF
Martin Gainty <[email protected]> Sun, 11 Dec 2016 13:19:36 +0000
| Newsgroups | gmane.text.xml.batik.user |
|---|---|
| Message-ID | <DM5PR14MB17700CE4F9DD309C834092B8AE990@DM5PR14MB1770.namprd14.prod.outlook.com> |
--_000_DM5PR14MB17700CE4F9DD309C834092B8AE990DM5PR14MB1770namp_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable ________________________________ From: Jan Tosovsky <[email protected]> Sent: Saturday, December 10, 2016 7:12 AM To: [email protected] Subject: RE: SVG rasterizer 1.8 - NoClassDefFoundError when exporting PDF On 2016-12-09 Jan Tosovsky wrote: > On 2016-12-08 Michael Harris wrote: > > On 2016-12-07 Jan Tosovsky wrote: > > > > > > I've tried to convert my SVG file using Batik rasterizer using the > > > following command, but it ends with NoClassDefFoundError: > > > > > > D:\batik-1.8>java -Xmx512m -jar batik-rasterizer-1.8.jar -m > > > application/pdf horologium.svg > > > > > > Exception in thread "main" java.lang.NoClassDefFoundError: > > > org/apache/batik/dom/svg/SVGDOMImplementation at > > > ... > > > > > > There is a SVGDOMImplementation in 1.8, but for some reason it was > > moved to org.apache.batik.anim.dom. > > > > See: https://stackoverflow.com/questions/30092651/where-has-org- [https://cdn.sstatic.net/Sites/stackoverflow/img/[email protected]?v= =3D73d79a89bded]<https://stackoverflow.com/questions/30092651/where-has-org= -> Where has org.apache.batik.dom.svg.SVGDOMImplementation gone?<https://stack= overflow.com/questions/30092651/where-has-org-> stackoverflow.com In the documentation for batik, it shows how to get an instance of the DOM = implementation from the class org.apache.batik.dom.svg.SVGDOMImplementation= . However, after downloading Batik 1.8 from th... > apache- > > batik-dom-svg-svgdomimplementation-gone/30250306#30250306 > > Thanks for confirmation. So this change was not apparently propagated > to the PDF rasterizer :-( > To be honest, moving SVG DOM implementation into 'anim' package and moreove= r 'anim' module is questionable. As a developer I would be surprised by the request to include 'anim' module dependency in case I need to generate PDF even there is no animation in my SVG file. MG>refactoring artifacts to be repackaged into a different package is *supp= osed to follow spec change* e.g. MG>DOM spec version 4 specified 19 Nov 2015 in https://www.w3.org/TR/dom/ W3C DOM4 - World Wide Web Consortium<https://www.w3.org/TR/dom/> www.w3.org This document was published by the HTML Working Group as a Recommendation. = If you wish to make comments regarding this document in a manner that is tr= acked by the W3C ... MG>for any other reason then you as a software professional and apache memb= er should ask why? MG>https://issues.apache.org/jira/browse/BATIK-1169?jql=3Dproject%20%3D%20B= ATIK <https://issues.apache.org/jira/browse/BATIK-1169?jql=3Dproject%20%3D%20BAT= IK>MG>please let me know what the response is I'd rather expect to have a separate module svd-dom-impl with this stuff. And for consistency to rename svg-dom to svg-dom-api. Jan --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --_000_DM5PR14MB17700CE4F9DD309C834092B8AE990DM5PR14MB1770namp_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable <html> <head> <meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Diso-8859-= 1"> <style type=3D"text/css" style=3D"display:none;"><!-- P {margin-top:0;margi= n-bottom:0;} --></style> </head> <body dir=3D"ltr"> <div id=3D"divtagdefaultwrapper" style=3D"font-size:12pt;color:#000000;font= -family:Arial,Helvetica,sans-serif;" dir=3D"ltr"> <p><br> </p> <div style=3D"color: rgb(0, 0, 0);"> <div> <hr tabindex=3D"-1" style=3D"display:inline-block; width:98%"> <div id=3D"x_divRplyFwdMsg" dir=3D"ltr"><font face=3D"Calibri, sans-serif" = color=3D"#000000" style=3D"font-size:11pt"><b>From:</b> Jan Tosovsky <j.= [email protected]><br> <b>Sent:</b> Saturday, December 10, 2016 7:12 AM<br> <b>To:</b> [email protected]<br> <b>Subject:</b> RE: SVG rasterizer 1.8 - NoClassDefFoundError when exportin= g PDF</font> <div> </div> </div> </div> <font size=3D"2"><span style=3D"font-size:10pt;"> <div class=3D"PlainText">On 2016-12-09 Jan Tosovsky wrote:<br> > On 2016-12-08 Michael Harris wrote:<br> > > On 2016-12-07 Jan Tosovsky wrote:<br> > > ><br> > > > I've tried to convert my SVG file using Batik rasterizer usi= ng the<br> > > > following command, but it ends with NoClassDefFoundError:<br= > > > ><br> > > > D:\batik-1.8>java -Xmx512m -jar batik-rasterizer-1.8.jar = -m<br> > > > application/pdf horologium.svg<br> > > ><br> > > > Exception in thread "main" java.lang.NoClassDefFou= ndError:<br> > > > org/apache/batik/dom/svg/SVGDOMImplementat= ion at<br> > > > ...<br> > ><br> > ><br> > > There is a SVGDOMImplementation in 1.8, but for some reason it wa= s<br> > > moved to org.apache.batik.anim.dom.<br> > ><br> > > See: <a href=3D"https://stackoverflow.com/questions/30092651/wher= e-has-org-" id=3D"LPlnk310425" previewremoved=3D"true"> https://stackoverflow.com/questions/30092651/where-has-org-</a> <div id=3D"LPBorder_GT_14814618977040.5146238003278589" style=3D"margin-bot= tom: 20px; overflow: auto; width: 100%; text-indent: 0px;"> <table id=3D"LPContainer_14814618976920.2146040583202906" cellspacing=3D"0"= style=3D"width: 90%; background-color: rgb(255, 255, 255); position: relat= ive; overflow: auto; padding-top: 20px; padding-bottom: 20px; margin-top: 2= 0px; border-top: 1px dotted rgb(200, 200, 200); border-bottom: 1px dotted r= gb(200, 200, 200);"> <tbody> <tr valign=3D"top" style=3D"border-spacing: 0px;"> <td id=3D"ImageCell_14814618976960.44232016973494415" colspan=3D"1" style= =3D"width: 250px; position: relative; display: table-cell; padding-right: 2= 0px;"> <div id=3D"LPImageContainer_14814618976960.6814412358747388" style=3D"backg= round-color: rgb(255, 255, 255); height: 250px; position: relative; margin:= auto; display: table; width: 250px;"> <a id=3D"LPImageAnchor_14814618976980.793509195188352" href=3D"https://stac= koverflow.com/questions/30092651/where-has-org-" target=3D"_blank" style=3D= "display: table-cell; text-align: center;"><img aria-label=3D"Preview image= with link selected. Double-tap to open the link." id=3D"LPThumbnailImageID= _14814618976980.7515930981506176" width=3D"250" height=3D"250" style=3D"dis= play: inline-block; max-width: 250px; max-height: 250px; height: 250px; wid= th: 250px; border-width: 0px; vertical-align: bottom;" src=3D"https://cdn.s= static.net/Sites/stackoverflow/img/[email protected]?v=3D73d79a89bded"= ></a></div> </td> <td id=3D"TextCell_14814618976990.06860069656330636" colspan=3D"2" style=3D= "vertical-align: top; position: relative; padding: 0px; display: table-cell= ;"> <div id=3D"LPRemovePreviewContainer_14814618976990.5762286584992817"></div> <div id=3D"LPTitle_14814618976990.5644072341515038" style=3D"top: 0px; colo= r: rgb(0, 120, 215); font-weight: normal; font-size: 21px; font-family: wf_= segoe-ui_light, "Segoe UI Light", "Segoe WP Light", &qu= ot;Segoe UI", "Segoe WP", Tahoma, Arial, sans-serif; line-he= ight: 21px;"> <a id=3D"LPUrlAnchor_14814618977000.8558982765701291" href=3D"https://stack= overflow.com/questions/30092651/where-has-org-" target=3D"_blank" style=3D"= text-decoration: none;">Where has org.apache.batik.dom.svg.SVGDOMImplementa= tion gone?</a></div> <div id=3D"LPMetadata_14814618977010.7769494662398442" style=3D"margin: 10p= x 0px 16px; color: rgb(102, 102, 102); font-weight: normal; font-family: wf= _segoe-ui_normal, "Segoe UI", "Segoe WP", Tahoma, Arial= , sans-serif; font-size: 14px; line-height: 14px;"> stackoverflow.com</div> <div id=3D"LPDescription_14814618977020.4524321007133765" style=3D"display:= block; color: rgb(102, 102, 102); font-weight: normal; font-family: wf_seg= oe-ui_normal, "Segoe UI", "Segoe WP", Tahoma, Arial, sa= ns-serif; font-size: 14px; line-height: 20px; max-height: 100px; overflow: = hidden;"> In the documentation for batik, it shows how to get an instance of the DOM = implementation from the class org.apache.batik.dom.svg.SVGDOMImplementation= . However, after downloading Batik 1.8 from th...</div> </td> </tr> </tbody> </table> </div> <br> <br> > apache-<br> > > batik-dom-svg-svgdomimplementation-gone/30250306#30250306<br> > <br> > Thanks for confirmation. So this change was not apparently propagated<= br> > to the PDF rasterizer :-(<br> > <br> <br> To be honest, moving SVG DOM implementation into 'anim' package and moreove= r<br> 'anim' module is questionable. As a developer I would be surprised by the<b= r> request to include 'anim' module dependency in case I need to generate PDF<= br> even there is no animation in my SVG file.</div> <div class=3D"PlainText"><br> </div> <div class=3D"PlainText">MG>refactoring artifacts to be repackaged into = a different package is *supposed to follow spec change* e.g.</div> <div class=3D"PlainText"><br> MG>DOM spec version 4 specified 19 Nov 2015 in <a href=3D"https://w= ww.w3.org/TR/dom/" class=3D"OWAAutoLink" id=3D"LPlnk585879" previewremoved= =3D"true">https://www.w3.org/TR/dom/</a> <div id=3D"LPBorder_GT_14814620473670.23910252073928473" style=3D"margin-bo= ttom: 20px; overflow: auto; width: 100%; text-indent: 0px;"> <table id=3D"LPContainer_14814620473550.7968534535007834" cellspacing=3D"0"= style=3D"width: 90%; background-color: rgb(255, 255, 255); position: relat= ive; overflow: auto; padding-top: 20px; padding-bottom: 20px; margin-top: 2= 0px; border-top: 1px dotted rgb(200, 200, 200); border-bottom: 1px dotted r= gb(200, 200, 200);"> <tbody> <tr valign=3D"top" style=3D"border-spacing: 0px;"> <td id=3D"TextCell_14814620473590.6009142506313256" colspan=3D"2" style=3D"= vertical-align: top; position: relative; padding: 0px; display: table-cell;= "> <div id=3D"LPRemovePreviewContainer_14814620473600.5434384623862791"></div> <div id=3D"LPTitle_14814620473600.3266236737283885" style=3D"top: 0px; colo= r: rgb(0, 120, 215); font-weight: normal; font-size: 21px; font-family: wf_= segoe-ui_light, "Segoe UI Light", "Segoe WP Light", &qu= ot;Segoe UI", "Segoe WP", Tahoma, Arial, sans-serif; line-he= ight: 21px;"> <a id=3D"LPUrlAnchor_14814620473620.7010988069269666" href=3D"https://www.w= 3.org/TR/dom/" target=3D"_blank" style=3D"text-decoration: none;">W3C DOM4 = - World Wide Web Consortium</a></div> <div id=3D"LPMetadata_14814620473630.5853357561754164" style=3D"margin: 10p= x 0px 16px; color: rgb(102, 102, 102); font-weight: normal; font-family: wf= _segoe-ui_normal, "Segoe UI", "Segoe WP", Tahoma, Arial= , sans-serif; font-size: 14px; line-height: 14px;"> www.w3.org</div> <div id=3D"LPDescription_14814620473650.7303856405023141" style=3D"display:= block; color: rgb(102, 102, 102); font-weight: normal; font-family: wf_seg= oe-ui_normal, "Segoe UI", "Segoe WP", Tahoma, Arial, sa= ns-serif; font-size: 14px; line-height: 20px; max-height: 100px; overflow: = hidden;"> This document was published by the HTML Working Group as a Recommendation. = If you wish to make comments regarding this document in a manner that is tr= acked by the W3C ...</div> </td> </tr> </tbody> </table> </div> <br> MG>for any other reason then you as a software professional and apache m= ember should ask why?</div> <div class=3D"PlainText"><br> </div> <div class=3D"PlainText">MG><a href=3D"https://issues.apache.org/jira/br= owse/BATIK-1169?jql=3Dproject%20%3D%20BATIK" class=3D"OWAAutoLink" id=3D"LP= lnk969419" previewremoved=3D"true">https://issues.apache.org/jira/browse/BA= TIK-1169?jql=3Dproject%20%3D%20BATIK</a></div> <div class=3D"PlainText"><br> </div> <div class=3D"PlainText"><a href=3D"https://issues.apache.org/jira/browse/B= ATIK-1169?jql=3Dproject%20%3D%20BATIK" class=3D"OWAAutoLink" previewremoved= =3D"true"></a>MG>please let me know what the response is<br> <br> I'd rather expect to have a separate module svd-dom-impl with this stuff.<b= r> And for consistency to rename svg-dom to svg-dom-api.<br> <br> Jan<br> <br> <br> ---------------------------------------------------------------------<br> To unsubscribe, e-mail: [email protected]<br> For additional commands, e-mail: [email protected]<br= > <br> </div> </span></font></div> </div> </body> </html> --_000_DM5PR14MB17700CE4F9DD309C834092B8AE990DM5PR14MB1770namp_--