My idea was to use a java5 compiler supporting java 1.4 runtime.
PersisterResolver is checking for the availability of the class by a ClassLoader operation. if the class is not available it won't use Enumeration.
I will be doing some tests today to validate this.
And I will separate jdk1.5 sourcecode from jdk1.4 in such way that if you use a JVM 1.4 you could compile it without enumeration.
You could use jbossretro to produce a 1.4 compatible binary. Being able to compile under j2se14 is not as relevant as being able to run under j2se14 in my view.
If you compile with JDK 5, the produced binary is compatible with JDK 1.4. I'm not using any Java5 specific feature, so I don't need to retroweave the code.
The issue is if you want to develop using JDK 1.4 you will get compilation exceptions.