db-jdo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mcai...@apache.org
Subject svn commit: r703533 - in /db/jdo/branches/2.2: api2-legacy/src/java/javax/jdo/ tck2-legacy/ tck2-legacy/src/conf/ tck2-legacy/src/java/org/apache/jdo/tck/util/signature/
Date Fri, 10 Oct 2008 17:44:56 GMT
Author: mcaisse
Date: Fri Oct 10 10:44:56 2008
New Revision: 703533

URL: http://svn.apache.org/viewvc?rev=703533&view=rev
Log:
Added some missing things to api2-legacy.

Modified:
    db/jdo/branches/2.2/api2-legacy/src/java/javax/jdo/Constants.java
    db/jdo/branches/2.2/tck2-legacy/project.xml
    db/jdo/branches/2.2/tck2-legacy/src/conf/iut-pmf.properties
    db/jdo/branches/2.2/tck2-legacy/src/conf/jdo-2_2-signatures.txt
    db/jdo/branches/2.2/tck2-legacy/src/java/org/apache/jdo/tck/util/signature/SignatureVerifier.java

Modified: db/jdo/branches/2.2/api2-legacy/src/java/javax/jdo/Constants.java
URL: http://svn.apache.org/viewvc/db/jdo/branches/2.2/api2-legacy/src/java/javax/jdo/Constants.java?rev=703533&r1=703532&r2=703533&view=diff
==============================================================================
--- db/jdo/branches/2.2/api2-legacy/src/java/javax/jdo/Constants.java (original)
+++ db/jdo/branches/2.2/api2-legacy/src/java/javax/jdo/Constants.java Fri Oct 10 10:44:56
2008
@@ -21,6 +21,7 @@
  * Constant values used in JDO.
  *
  * @since 2.1
+ * @version 2.2
  */
 public interface Constants {
 
@@ -121,6 +122,14 @@
     static String PMF_ATTRIBUTE_OPTIMISTIC
         = "optimistic";
     /**
+     * The name of the persistence manager factory element's "readonly"
+     * attribute.
+     *
+     * @since 2.2
+     */
+    static String PMF_ATTRIBUTE_READONLY
+        = "readonly";
+    /**
      * The name of the persistence manager factory element's "retain-values"
      * attribute.
      *
@@ -547,6 +556,14 @@
     static String PROPERTY_OPTIMISTIC
         = "javax.jdo.option.Optimistic";
     /**
+     * "javax.jdo.option.ReadOnly"
+     *
+     * @see PersistenceManagerFactory#getReadOnly()
+     * @since 2.2
+     */
+    static String PROPERTY_READONLY
+        = "javax.jdo.option.ReadOnly";
+    /**
      * "javax.jdo.option.RetainValues"
      *
      * @see PersistenceManagerFactory#getRetainValues()
@@ -595,6 +612,53 @@
     static String PROPERTY_MULTITHREADED
         = "javax.jdo.option.Multithreaded";
     /**
+     * "javax.jdo.option.TransactionIsolationLevel"
+     *
+     * @since 2.2
+     */
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL
+        = "javax.jdo.option.TransactionIsolationLevel";
+    /**
+     * "javax.jdo.option.TransactionIsolationLevel.read-uncommitted"
+     *
+     * @see PersistenceManagerFactory#supportedOptions()
+     * @since 2.2
+     */
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_READ_UNCOMMITTED
+        = "javax.jdo.option.TransactionIsolationLevel.read-uncommitted";
+    /**
+     * "javax.jdo.option.TransactionIsolationLevel.read-committed"
+     *
+     * @see PersistenceManagerFactory#supportedOptions()
+     * @since 2.2
+     */
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_READ_COMMITTED
+        = "javax.jdo.option.TransactionIsolationLevel.read-committed";
+    /**
+     * "javax.jdo.option.TransactionIsolationLevel.repeatable-read"
+     *
+     * @see PersistenceManagerFactory#supportedOptions()
+     * @since 2.2
+     */
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_REPEATABLE_READ
+        = "javax.jdo.option.TransactionIsolationLevel.repeatable-read";
+    /**
+     * "javax.jdo.option.TransactionIsolationLevel.snapshot"
+     *
+     * @see PersistenceManagerFactory#supportedOptions()
+     * @since 2.2
+     */
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_SNAPSHOT
+        = "javax.jdo.option.TransactionIsolationLevel.snapshot";
+    /**
+     * "javax.jdo.option.TransactionIsolationLevel.serializable"
+     *
+     * @see PersistenceManagerFactory#supportedOptions()
+     * @since 2.2
+     */
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_SERIALIZABLE
+        = "javax.jdo.option.TransactionIsolationLevel.serializable";
+    /**
      * "javax.jdo.option.DetachAllOnCommit"
      *
      * @see PersistenceManagerFactory#getDetachAllOnCommit()
@@ -789,7 +853,7 @@
      * @since 2.1
      */
     static String JDOCONFIG_DTD_RESOURCE
-        = "javax/jdo/jdoconfig_2_1.dtd";
+        = "javax/jdo/jdoconfig_2_2.dtd";
 
     /**
      * The name of the resource for the XML schema of the standard JDO
@@ -798,7 +862,7 @@
      * @since 2.1
      */
     static String JDOCONFIG_XSD_RESOURCE
-        = "javax/jdo/jdoconfig_2_1.xsd";
+        = "javax/jdo/jdoconfig_2_2.xsd";
 
     /**
      * The name of the resource for the DTD of the standard JDO metadata file.
@@ -806,7 +870,7 @@
      * @since 2.1
      */
     static String JDO_DTD_RESOURCE
-        = "javax/jdo/jdo_2_0.dtd";
+        = "javax/jdo/jdo_2_2.dtd";
 
     /**
      * The name of the resource for the XML schema of the standard JDO
@@ -815,7 +879,7 @@
      * @since 2.1
      */
     static String JDO_XSD_RESOURCE
-        = "javax/jdo/jdo_2_1.xsd";
+        = "javax/jdo/jdo_2_2.xsd";
 
     /**
      * The name of the resource for the DTD of the standard JDO
@@ -824,7 +888,7 @@
      * @since 2.1
      */
     static String ORM_DTD_RESOURCE
-        = "javax/jdo/orm_2_0.dtd";
+        = "javax/jdo/orm_2_2.dtd";
 
     /**
      * The name of the resource for the XML schema of the standard JDO
@@ -833,7 +897,7 @@
      * @since 2.1
      */
     static String ORM_XSD_RESOURCE
-        = "javax/jdo/orm_2_1.xsd";
+        = "javax/jdo/orm_2_2.xsd";
 
     /**
      * The name of the resource for the DTD of the standard JDO query
@@ -842,7 +906,7 @@
      * @since 2.1
      */
     static String JDOQUERY_DTD_RESOURCE
-        = "javax/jdo/jdoquery_2_0.dtd";
+        = "javax/jdo/jdoquery_2_2.dtd";
 
     /**
      * The name of the resource for the XML schema of the standard JDO query
@@ -851,7 +915,7 @@
      * @since 2.1
      */
     static String JDOQUERY_XSD_RESOURCE
-        = "javax/jdo/jdoquery_2_1.xsd";
+        = "javax/jdo/jdoquery_2_2.xsd";
 
     /**
      * The name of the anonymous PersistenceManagerFactory, which
@@ -906,4 +970,5 @@
      * @since 2.2
      */
     public static final String TX_SERIALIZABLE = "serializable"; 
+
 }

Modified: db/jdo/branches/2.2/tck2-legacy/project.xml
URL: http://svn.apache.org/viewvc/db/jdo/branches/2.2/tck2-legacy/project.xml?rev=703533&r1=703532&r2=703533&view=diff
==============================================================================
--- db/jdo/branches/2.2/tck2-legacy/project.xml (original)
+++ db/jdo/branches/2.2/tck2-legacy/project.xml Fri Oct 10 10:44:56 2008
@@ -59,19 +59,19 @@
         <dependency>
             <groupId>org.datanucleus</groupId>
             <artifactId>datanucleus-core</artifactId>
-            <version>1.0-SNAPSHOT</version>
+            <version>1.0.1</version>
             <url>http://www.datanucleus.org/downloads/maven-nightly</url>
         </dependency>
         <dependency>
             <groupId>org.datanucleus</groupId>
             <artifactId>datanucleus-rdbms</artifactId>
-            <version>1.0-SNAPSHOT</version>
+            <version>1.0.1</version>
             <url>http://www.datanucleus.org/downloads/maven-nightly</url>
         </dependency>
         <dependency>
             <groupId>org.datanucleus</groupId>
             <artifactId>datanucleus-enhancer</artifactId>
-            <version>1.0-SNAPSHOT</version>
+            <version>1.0.1</version>
             <url>http://www.datanucleus.org/downloads/maven-nightly</url>
         </dependency>
         <dependency>
@@ -123,7 +123,7 @@
         <dependency>
             <groupId>org.datanucleus</groupId>
             <artifactId>datanucleus-connectionpool</artifactId>
-            <version>1.0-SNAPSHOT</version>
+            <version>1.0.0</version>
             <url>http://www.datanucleus.org/downloads/maven-nightly</url>
         </dependency>
         <dependency>

Modified: db/jdo/branches/2.2/tck2-legacy/src/conf/iut-pmf.properties
URL: http://svn.apache.org/viewvc/db/jdo/branches/2.2/tck2-legacy/src/conf/iut-pmf.properties?rev=703533&r1=703532&r2=703533&view=diff
==============================================================================
--- db/jdo/branches/2.2/tck2-legacy/src/conf/iut-pmf.properties (original)
+++ db/jdo/branches/2.2/tck2-legacy/src/conf/iut-pmf.properties Fri Oct 10 10:44:56 2008
@@ -27,8 +27,8 @@
 javax.jdo.option.Optimistic=false
 javax.jdo.option.RetainValues=false
 javax.jdo.option.RestoreValues=false
-javax.jdo.option.Mapping=derby
 
+datanucleus.metadata.validate=false
 datanucleus.validateTables=false
 datanucleus.validateConstraints=false
 datanucleus.autoCreateSchema=false
@@ -37,5 +37,7 @@
 datanucleus.autoCreateColumns=false
 datanucleus.rdbms.CheckExistTablesOrViews=false
 datanucleus.autoStartMechanism=None
+#datanucleus.initializePrimaryKeyColumnInfo=true
 #datanucleus.connectionPoolingType=DBCP
 datanucleus.connectionPoolingType=C3P0
+datanucleus.implementationCreatorName=asm

Modified: db/jdo/branches/2.2/tck2-legacy/src/conf/jdo-2_2-signatures.txt
URL: http://svn.apache.org/viewvc/db/jdo/branches/2.2/tck2-legacy/src/conf/jdo-2_2-signatures.txt?rev=703533&r1=703532&r2=703533&view=diff
==============================================================================
--- db/jdo/branches/2.2/tck2-legacy/src/conf/jdo-2_2-signatures.txt (original)
+++ db/jdo/branches/2.2/tck2-legacy/src/conf/jdo-2_2-signatures.txt Fri Oct 10 10:44:56 2008
@@ -1,3 +1,20 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ * 
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software 
+ * distributed under the License is distributed on an "AS IS" BASIS, 
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
+ * See the License for the specific language governing permissions and 
+ * limitations under the License.
+ */
+
 public interface javax.jdo.Constants {
     static String SERVICE_LOOKUP_PMF_RESOURCE_NAME
         = "META-INF/services/javax.jdo.PersistenceManagerFactory";
@@ -59,6 +76,8 @@
         = "name";
     static String PROPERTY_ATTRIBUTE_VALUE
         = "value";
+    static String PMF_ATTRIBUTE_READONLY
+        = "readonly";
     static String ELEMENT_INSTANCE_LIFECYCLE_LISTENER
         = "instance-lifecycle-listener";
     static String INSTANCE_LIFECYCLE_LISTENER_ATTRIBUTE_LISTENER
@@ -129,6 +148,8 @@
         = "javax.jdo.PersistenceManagerFactoryClass";
     static String PROPERTY_OPTIMISTIC
         = "javax.jdo.option.Optimistic";
+    static String PROPERTY_READONLY
+        = "javax.jdo.option.ReadOnly";
     static String PROPERTY_RETAIN_VALUES
         = "javax.jdo.option.RetainValues";
     static String PROPERTY_RESTORE_VALUES
@@ -141,6 +162,18 @@
         = "javax.jdo.option.NontransactionalWrite";
     static String PROPERTY_MULTITHREADED
         = "javax.jdo.option.Multithreaded";
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL
+        = "javax.jdo.option.TransactionIsolationLevel";
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_READ_UNCOMMITTED
+        = "javax.jdo.option.TransactionIsolationLevel.read-uncommitted";
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_READ_COMMITTED
+        = "javax.jdo.option.TransactionIsolationLevel.read-committed";
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_REPEATABLE_READ
+        = "javax.jdo.option.TransactionIsolationLevel.repeatable-read";
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_SNAPSHOT
+        = "javax.jdo.option.TransactionIsolationLevel.snapshot";
+    static String PROPERTY_TRANSACTION_ISOLATION_LEVEL_SERIALIZABLE
+        = "javax.jdo.option.TransactionIsolationLevel.serializable";
     static String PROPERTY_DETACH_ALL_ON_COMMIT
         = "javax.jdo.option.DetachAllOnCommit";
     static String PROPERTY_COPY_ON_ATTACH
@@ -184,23 +217,28 @@
     static String RESOURCE_LOCAL
         = "RESOURCE_LOCAL";
     static String JDOCONFIG_DTD_RESOURCE
-        = "javax/jdo/jdoconfig_2_1.dtd";
+        = "javax/jdo/jdoconfig_2_2.dtd";
     static String JDOCONFIG_XSD_RESOURCE
-        = "javax/jdo/jdoconfig_2_1.xsd";
+        = "javax/jdo/jdoconfig_2_2.xsd";
     static String JDO_DTD_RESOURCE
-        = "javax/jdo/jdo_2_0.dtd";
+        = "javax/jdo/jdo_2_2.dtd";
     static String JDO_XSD_RESOURCE
-        = "javax/jdo/jdo_2_1.xsd";
+        = "javax/jdo/jdo_2_2.xsd";
     static String ORM_DTD_RESOURCE
-        = "javax/jdo/orm_2_0.dtd";
+        = "javax/jdo/orm_2_2.dtd";
     static String ORM_XSD_RESOURCE
-        = "javax/jdo/orm_2_1.xsd";
+        = "javax/jdo/orm_2_2.xsd";
     static String JDOQUERY_DTD_RESOURCE
-        = "javax/jdo/jdoquery_2_0.dtd";
+        = "javax/jdo/jdoquery_2_2.dtd";
     static String JDOQUERY_XSD_RESOURCE
-        = "javax/jdo/jdoquery_2_1.xsd";
+        = "javax/jdo/jdoquery_2_2.xsd";
     static String ANONYMOUS_PERSISTENCE_MANAGER_FACTORY_NAME
         = "";
+    public static final String TX_READ_UNCOMMITTED = "read-uncommitted"; 
+    public static final String TX_READ_COMMITTED = "read-committed"; 
+    public static final String TX_REPEATABLE_READ = "repeatable-read"; 
+    public static final String TX_SNAPSHOT = "snapshot"; 
+    public static final String TX_SERIALIZABLE = "serializable";
 }
 
 public interface javax.jdo.datastore.DataStoreCache {
@@ -717,6 +755,7 @@
     public void flush();
     public void checkConsistency();
     public javax.jdo.FetchPlan getFetchPlan();
+    javax.jdo.FetchGroup getFetchGroup(Class cls, String name);
     public Object newInstance(Class pcClass);
     public java.util.Date getServerDate();
     public javax.jdo.datastore.Sequence getSequence(String name);
@@ -778,11 +817,18 @@
     public void setTransactionType(java.lang.String);
     public void setReadOnly(boolean flag);
     public boolean getReadOnly();
+    public void setTransactionIsolationLevel(String);
+    public String getTransactionIsolationLevel();
     public java.util.Properties getProperties();
     public java.util.Collection supportedOptions();
     public javax.jdo.datastore.DataStoreCache getDataStoreCache();
     public void addInstanceLifecycleListener(javax.jdo.listener.InstanceLifecycleListener
listener, Class[] classes);
     public void removeInstanceLifecycleListener(javax.jdo.listener.InstanceLifecycleListener
listener);
+    void addFetchGroups(javax.jdo.FetchGroup[] groups);
+    void removeFetchGroups(javax.jdo.FetchGroup[] groups);
+    void removeAllFetchGroups();
+    javax.jdo.FetchGroup getFetchGroup(Class cls, String name);
+    java.util.Set getFetchGroups();
 }
 
 public interface javax.jdo.Query extends java.io.Serializable {
@@ -1056,6 +1102,8 @@
     public boolean getRestoreValues();
     public void setOptimistic(boolean optimistic);
     public boolean getOptimistic();
+    void setIsolationLevel(String level);
+    String getIsolationLevel();
     public void setSynchronization(javax.transaction.Synchronization sync);
     public javax.transaction.Synchronization getSynchronization();
     public javax.jdo.PersistenceManager getPersistenceManager();

Modified: db/jdo/branches/2.2/tck2-legacy/src/java/org/apache/jdo/tck/util/signature/SignatureVerifier.java
URL: http://svn.apache.org/viewvc/db/jdo/branches/2.2/tck2-legacy/src/java/org/apache/jdo/tck/util/signature/SignatureVerifier.java?rev=703533&r1=703532&r2=703533&view=diff
==============================================================================
--- db/jdo/branches/2.2/tck2-legacy/src/java/org/apache/jdo/tck/util/signature/SignatureVerifier.java
(original)
+++ db/jdo/branches/2.2/tck2-legacy/src/java/org/apache/jdo/tck/util/signature/SignatureVerifier.java
Fri Oct 10 10:44:56 2008
@@ -618,25 +618,74 @@
             nextToken = t;
         }
 
-        /**
-         * Skips any "white space" and returns whether there are more
+       /**
+         * Skips any "white space" and /* style comments
+         * and returns whether there are more
          * characters to be parsed.
          */
         protected boolean skip() throws IOException {
-            char c;
-            do {
-                ir.mark(1);
-                int i;
-                if ((i = ir.read()) < 0) {
+            Character c;
+            Character cnext;
+            // Permitted states are white, commentSlashStar, commentSlashSlash
+            String state = "white";
+            final Character SLASH = new Character('/');
+            final Character STAR = new Character('*');
+            while (true) {
+                c = peek();
+                if (c == null)
                     return false;
-                }            
-                c = (char)i;
-            } while (Character.isWhitespace(c));
+                if (state.equals("commentSlashStar") && STAR.equals(c)) {
+                    cnext = peek();
+                    if (cnext == null)
+                        return false;
+                    if (SLASH.equals(cnext)) {
+                        state = "white";
+                    }
+                    continue;
+                }
+                if (state.equals("white")) {
+                    if (SLASH.equals(c)) {
+                        cnext = peek();
+                        if (cnext == null)
+                            return false;
+                        if (STAR.equals(cnext)) {
+                            state = "commentSlashStar";
+                            continue;
+                        }
+                        if (SLASH.equals(cnext)) {
+                            state = "commentSlashSlash";
+                            continue;
+                        }
+                    }
+                    if (!Character.isWhitespace(c.charValue())) {
+                        break;
+                    }
+                }
+                if (state.equals("commentSlashSlash")
+                    && (c.charValue() == Character.LINE_SEPARATOR
+                        || c.charValue() == '\n'
+                        || c.charValue() == '\r')) {
+                    state = "white";
+                    continue;
+                }
+            }
             ir.reset();
             return true;
         }
 
         /**
+         * Returns next char, or null if there is none
+         */
+        protected Character peek() throws IOException {
+            ir.mark(1);
+            int i;
+            if ((i = ir.read()) < 0) {
+                return null;
+            }            
+            return Character.valueOf((char)i);
+        }
+
+        /**
          * Scans for an (unqualified) identifier.
          * @return <code>null</code> if the next token is not an identifier
          */



Mime
View raw message