I need to know if those libraries mentioned in the title are compatible between each other. What I need to do is to change libraries: from net.sf.jxls to org.jxls 2.10.0 (and therefore adapt the implementation that was made using jxls-core 1.0.6). I'm working with java 8.
According to the implementation that I need to adapt, jxls is used by first instanciating and XLSTransformer object: XLSTransformer transformer = new XLSTransformer(); Then, the method 'transformXLS(...)' is called which receives an InputStream as parameter and a Map, and returns a Workbook object.
Is there a similar method or some kind of 'work-around' in jxls 2.10.0 to perform exactly the same? What I need to know is a way to return a Workbook object using jxls 2.10.0 in order to adapt the implementation done with jxls-core 1.0.6
While jxls1 does not directly support POI4, it is easy to modify it for this purpose.
You basically have to edit these classes (in jxls-core):
You need minor changes on them, e.g.:
XLSTransformer.java: line 484, change
to
so basically all changes are minor changes. You can find the jxls1 code with POI 4 support here: https://github.com/infofabrik/reportserver/tree/main/jxls-src
We are also working on sending this code to the jxls team. But you can of course use the classes available in the link.