Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 82098 invoked from network); 1 Jun 2010 19:19:13 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 1 Jun 2010 19:19:13 -0000 Received: (qmail 51943 invoked by uid 500); 1 Jun 2010 19:19:12 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 51920 invoked by uid 500); 1 Jun 2010 19:19:12 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 51913 invoked by uid 99); 1 Jun 2010 19:19:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 01 Jun 2010 19:19:12 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=10.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS,UNPARSEABLE_RELAY X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [148.87.113.121] (HELO rcsinet10.oracle.com) (148.87.113.121) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 01 Jun 2010 19:19:03 +0000 Received: from acsinet15.oracle.com (acsinet15.oracle.com [141.146.126.227]) by rcsinet10.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id o51JIdoU006380 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 1 Jun 2010 19:18:41 GMT Received: from acsmt353.oracle.com (acsmt353.oracle.com [141.146.40.153]) by acsinet15.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id o51HwASK009431 for ; Tue, 1 Jun 2010 19:18:38 GMT Received: from abhmt014.oracle.com by acsmt354.oracle.com with ESMTP id 287401561275419820; Tue, 01 Jun 2010 12:17:00 -0700 Received: from richard-hillegas-computer.local (/129.150.0.112) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 01 Jun 2010 12:17:00 -0700 Message-ID: <4C055CAA.6010303@oracle.com> Date: Tue, 01 Jun 2010 12:16:58 -0700 From: Rick Hillegas User-Agent: Thunderbird 2.0.0.24 (Macintosh/20100228) MIME-Version: 1.0 To: derby-dev@db.apache.org Subject: Re: Using enum keyword in derby source files References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Auth-Type: Internal IP X-Source-IP: acsinet15.oracle.com [141.146.126.227] X-CT-RefId: str=0001.0A090205.4C055D11.017A:SCFMA922111,ss=1,fgs=0 X-Virus-Checked: Checked by ClamAV on apache.org 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