John Hewson created PDFBOX-2387:
-----------------------------------

             Summary: ImageIOUtil, JPEGUtil, TIFFUtil and MetaUtil are not 
needed in "pdfbox"
                 Key: PDFBOX-2387
                 URL: https://issues.apache.org/jira/browse/PDFBOX-2387
             Project: PDFBox
          Issue Type: Improvement
            Reporter: John Hewson


The classes ImageIOUtil, JPEGUtil, TIFFUtil and MetaUtil are not needed in the 
"pdfbox" module. All usages of ImageIOUtil in the "pdfbox" module can be safely 
replaced with Java's ImageIO. That's over 650 lines of imaging code which we 
don't need.

ImageIOUtil and friends are only needed by classes in the "tools" module, which 
write image files to disk. Ultimately the ImageIOUtil class is just a bandaid 
for Java ImageIO's bugs, which while helpful, isn't a necessary part of the 
PDFBox core.

Obviously ImageIOUtil is useful to downstream consumers of PDFBox, but it 
doesn't belong in the core "pdfbox" module, where it introduces unnecessary 
complexity, so we should move it into the "tools" module along with JPEGUtil, 
TIFFUtil and MetaUtil.

We might want to consider doing this with other utility classes which probably 
don't belong in the "pdfbox" core such as TextToPDF, PrintPDF, WriteDecodedDoc, 
etc. - basically anything with a main() method. But we'll deal with that later.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to