A few days ago, I started writing a PNG module for JHOVE, partly to keep my Java skills up, partly to help me understand the PNG format. After a while I noticed there already is code for a PNG module and has been for a long time. I must have added it to SourceForge. According to a note in the code, Gian Uberto Lauri at Engineering Ingengeria Informatica S.p.a. created it in 2006. A good amount of work clearly went into it, but it won’t compile. It’s located in a non-source code directory (extramodules/it/eng/jhove/module/png/PngModule.java), so I had to copy it to src/java to try it out.

Some of the problems are minor. It has some constructor calls that are wrong but can be fixed by adding a bunch of null arguments. One issue is weird. Several variables are declared as type “Booolean,” with three o’s. This can’t be a typo, not if the developer tried to compile it even once. It could be a customized variant of Boolean that didn’t make it into JHOVE. Update: It looks like an annotated Boolean. The constructor takes two arguments, a boolean value and an explanatory string.

Just from reading the code, it looks as if the author didn’t really get to metadata extraction, but the code is well-organized and wouldn’t be hard to build on. On the other hand, I’ve made some progress on my own code (it can tell a PNG from a non-PNG and walk through all the chunks), so it might make more sense to continue with that and lift from the earlier code as needed.

I wish I could remember the circumstances of my putting it in there.

JHOVE 1.12, by the way, was supposed to have been out late last year, and the last that I talked to Carl Wilson, it was very close to release. I don’t know what’s happened since then, but OPF seems to be very understaffed, so probably other priorities forced delaying the release.

Comments are closed.