Custom-built iText version required by JasperReports library?

纵然是瞬间 提交于 2019-12-24 10:45:06

问题


I tried to add jasper reports library (net.sf.jasperreports:jasperreports:5.2.0) as a maven dependency to my project , unfortunately one of it's dependencies com.lowagie:itext:2.1.7.js2 is a little bit untypical and cannot be located in maven central. I've found, however, that it's available at http://jasperreports.sourceforge.net/maven2/com/lowagie/itext/ .

My questions are:

  1. What is the purpose of jaspersoft custom-build of iText? Patches?

  2. Is it safe to use regular iText library, version 2.1.7 found in maven central repo?


回答1:


Since the iText license changed from MPL/LGPL Jasper Report couldn't upgrade. So according to the LGPL they supplied a jar file with their changes.

You may ask what changes are:

  • they added a pom.xml (not relevant in your case)
  • they did a minor change to the ant.properties for their own version numbering (not relevant in your case)
  • patched the PdfGraphics2D.java file (fixed a transparency bug)

The change is about the currentFillGState, Lines 1089, 1490, 1616-1628.

What this means for you is difficult to tell but you have the following possibilities:

  1. exchange the patched.jar with the default and run (extensive) tests
  2. add the patched.jar to your repository
  3. add the public jasper report repo to your repo (http://jasperreports.sourceforge.net/maven2)
  4. and as others pointed out ask jr folks for further details, e.g. here would be a start: http://community.jaspersoft.com/jasperreports-library/issues/2594-0


来源:https://stackoverflow.com/questions/17743418/custom-built-itext-version-required-by-jasperreports-library

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!