>> I was thinking there might be an easy way to generate Enumeration
>> classes on the fly - In that case I could have used Java Enumerations,
>> if given; or simply have generated them.
I'm sure it would be far easier to treat Java enums and non-Java enums
as separate cases.
> You can use a byte code generation tool like BCEL.
BCEL is evil. ASM is much better.
> Or if you are on Java 1.6 you can simply compile
> Java source code (you can do memory->memory instead
> of file->file).
Well, you can compile Java with earlier versions of the JDK (or just
tools.jar) anyway. 1.6 just gives a standardised interface for doing that.
Tom Hawtin
Arne Vajhøj - 09 Jun 2007 19:09 GMT
>>> I was thinking there might be an easy way to generate Enumeration
>>> classes on the fly - In that case I could have used Java
[quoted text clipped - 6 lines]
>
> BCEL is evil. ASM is much better.
:-)
>> Or if you are on Java 1.6 you can simply compile
>> Java source code (you can do memory->memory instead
>> of file->file).
>
> Well, you can compile Java with earlier versions of the JDK (or just
> tools.jar) anyway. 1.6 just gives a standardised interface for doing that.
Also memory->memory ?
Arne