Ok, Rick. Thanks.
On Wed, Jun 2, 2010 at 12:46 AM, Rick Hillegas <[email protected]> wrote: > Nirmal Fernando wrote: >> >> Hi All, >> >> I'm getting ant compilation errors, when I used "enum" keyword in a >> new class, under derby code. >> I'm using jdk 1.6. >> >> How can I get rid of this? >> >> Thanks. >> >> >> > > Hi Nirmal, > > Most of Derby code is expected to run on jdk 1.4. That means the code cannot > contain language features which were introduced in Java 5. In addition, the > code should not reference libraries which were introduced in Java 5 or Java > 6. There are some exceptions to these rules. That is, there is some code > which only runs on more recent VMs and which is loaded only if the VM is > advanced enough. It sounds as though you are trying to use Java 5 features > in a piece of code which ought to run on jdk 1.4. Probably the best solution > would be to rewrite your code to avoid the Java 5 features. > > Hope this helps, > -Rick > -- Best Regards, Nirmal C.S.Nirmal J. Fernando Department of Computer Science & Engineering, Faculty of Engineering, University of Moratuwa, Sri Lanka.
