openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mik...@apache.org
Subject svn commit: r757280 [4/23] - in /openjpa/branches/1.0.x: openjpa-examples/src/main/java/hellojpa/ openjpa-examples/src/main/java/relations/ openjpa-jdbc-5/src/main/java/org/apache/openjpa/jdbc/meta/strats/ openjpa-jdbc/src/main/java/org/apache/openjpa/...
Date Sun, 22 Mar 2009 23:45:35 GMT
Modified: openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/ManagedClassSubclasser.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/ManagedClassSubclasser.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/ManagedClassSubclasser.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/ManagedClassSubclasser.java Sun Mar 22 23:45:15 2009
@@ -1,280 +1,280 @@
-/*
- * 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.
- */
-package org.apache.openjpa.enhance;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import org.apache.openjpa.conf.OpenJPAConfiguration;
-import org.apache.openjpa.lib.log.Log;
-import org.apache.openjpa.lib.util.BytecodeWriter;
-import org.apache.openjpa.lib.util.JavaVersions;
-import org.apache.openjpa.lib.util.Localizer;
-import org.apache.openjpa.lib.util.Localizer.Message;
-import org.apache.openjpa.meta.ClassMetaData;
-import org.apache.openjpa.meta.FieldMetaData;
-import org.apache.openjpa.meta.JavaTypes;
-import org.apache.openjpa.util.GeneratedClasses;
-import org.apache.openjpa.util.ImplHelper;
-import org.apache.openjpa.util.InternalException;
-import org.apache.openjpa.util.UserException;
-import serp.bytecode.BCClass;
-
-/**
- * Redefines the method bodies of existing unenhanced classes to make them
- * notify state managers of mutations.
- *
- * @since 1.0.0
- */
-public class ManagedClassSubclasser {
-    private static final Localizer _loc = Localizer.forPackage(
-        ManagedClassSubclasser.class);
-
-    /**
-     * For each element in <code>classes</code>, creates and registers a
-     * new subclass that implements {@link PersistenceCapable}, and prepares
-     * OpenJPA to handle new instances of the unenhanced type. If this is
-     * invoked in a Java 6 environment, this method will redefine the methods
-     * for each class in the argument list such that field accesses are
-     * intercepted in-line. If invoked in a Java 5 environment, this
-     * redefinition is not possible; in these contexts, when using field
-     * access, OpenJPA will need to do state comparisons to detect any change
-     * to any instance at any time, and when using property access, OpenJPA
-     * will need to do state comparisons to detect changes to newly inserted
-     * instances after a flush has been called.
-     *
-     * @return the new subclasses, or <code>null</code> if <code>classes</code>
-     * is <code>null</code>.
-     * @throws UserException if <code>conf</code> requires build-time
-     * enhancement and <code>classes</code> includes unenhanced types.
-     *
-     * @since 1.0.0
-     */
-    public static List<Class> prepareUnenhancedClasses(
-        final OpenJPAConfiguration conf,
-        final Collection<? extends Class> classes,
-        final ClassLoader envLoader) {
-        if (classes == null)
-            return null;
-        if (classes.size() == 0)
-            return Collections.EMPTY_LIST;
-
-        Log log = conf.getLog(OpenJPAConfiguration.LOG_ENHANCE);
-        if (conf.getRuntimeUnenhancedClassesConstant()
-            != RuntimeUnenhancedClasssesModes.SUPPORTED) {
-            Collection unenhanced = new ArrayList();
-            for (Class cls : classes)
-                if (!PersistenceCapable.class.isAssignableFrom(cls))
-                    unenhanced.add(cls);
-            if (unenhanced.size() > 0) {
-                Message msg = _loc.get("runtime-optimization-disabled",
-                    unenhanced);
-                if (conf.getRuntimeUnenhancedClassesConstant()
-                    == RuntimeUnenhancedClasssesModes.WARN)
-                    log.warn(msg);
-                else
-                    throw new UserException(msg);
-            }
-            return null;
-        }
-
-        boolean redefine = ClassRedefiner.canRedefineClasses();
-        if (redefine)
-            log.info(_loc.get("enhance-and-subclass-and-redef-start",
-                classes));
-        else
-            log.info(_loc.get("enhance-and-subclass-no-redef-start",
-                classes));
-
-        final Map<Class, byte[]> map = new HashMap<Class, byte[]>();
-        final List subs = new ArrayList(classes.size());
-        final List ints = new ArrayList(classes.size());
-        Set<Class> unspecified = null;
-        for (Iterator iter = classes.iterator(); iter.hasNext(); ) {
-            final Class cls = (Class) iter.next();
-            final PCEnhancer enhancer = new PCEnhancer(conf, cls);
-
-            enhancer.setBytecodeWriter(new BytecodeWriter() {
-                public void write(BCClass bc) throws IOException {
-                    ManagedClassSubclasser.write(bc, enhancer, map,
-                        cls, subs, ints);
-                }
-            });
-            if (redefine)
-                enhancer.setRedefine(true);
-            enhancer.setCreateSubclass(true);
-            enhancer.setAddDefaultConstructor(true);
-
-            // set this before enhancement as well as after since enhancement
-            // uses a different metadata repository, and the metadata config
-            // matters in the enhancement contract. Don't do any warning here,
-            // since we'll issue warnings when we do the final metadata
-            // reconfiguration at the end of this method.
-            configureMetaData(enhancer.getMetaData(), conf, redefine, false);
-
-            unspecified = collectRelatedUnspecifiedTypes(enhancer.getMetaData(),
-                classes, unspecified);
-
-            int runResult = enhancer.run();
-            if (runResult == PCEnhancer.ENHANCE_PC) {
-                try {
-                    enhancer.record();
-                } catch (IOException e) {
-                    // our impl of BytecodeWriter doesn't throw IOException
-                    throw new InternalException(e);
-                }
-            }
-        }
-
-        if (unspecified != null && !unspecified.isEmpty())
-            throw new UserException(_loc.get("unspecified-unenhanced-types",
-                classes, unspecified));
-
-        ClassRedefiner.redefineClasses(conf, map);
-        for (Class cls : map.keySet()) {
-            setIntercepting(conf, envLoader, cls);
-            configureMetaData(conf, envLoader, cls, redefine);
-        }
-        for (Class cls : (Collection<Class>) subs)
-            configureMetaData(conf, envLoader, cls, redefine);
-        for (Class cls : (Collection<Class>) ints)
-            setIntercepting(conf, envLoader, cls);
-
-        return subs;
-    }
-
-    private static Set<Class> collectRelatedUnspecifiedTypes(ClassMetaData meta,
-        Collection<? extends Class> classes, Set<Class> unspecified) {
-        unspecified = collectUnspecifiedType(meta.getPCSuperclass(), classes,
-            unspecified);
-
-        for (FieldMetaData fmd : meta.getFields()) {
-            if (fmd.isTransient())
-                continue;
-            if (fmd.isTypePC())
-                unspecified = collectUnspecifiedType(fmd.getType(), classes,
-                    unspecified);
-            if (fmd.getElement() != null && fmd.getElement().isTypePC())
-                unspecified = collectUnspecifiedType(fmd.getElement().getType(),
-                    classes, unspecified);
-            if (fmd.getKey() != null && fmd.getKey().isTypePC())
-                unspecified = collectUnspecifiedType(fmd.getKey().getType(),
-                    classes, unspecified);
-            if (fmd.getValue() != null && fmd.getValue().isTypePC())
-                unspecified = collectUnspecifiedType(fmd.getValue().getType(),
-                    classes, unspecified);
-        }
-        return unspecified;
-    }
-
-    private static Set<Class> collectUnspecifiedType(Class cls,
-        Collection<? extends Class> classes, Set<Class> unspecified) {
-        if (cls != null && !classes.contains(cls)
-            && !ImplHelper.isManagedType(null, cls)) {
-            if (unspecified == null)
-                unspecified = new HashSet<Class>();
-            unspecified.add(cls);
-        }
-        return unspecified;
-    }
-
-    private static void configureMetaData(OpenJPAConfiguration conf,
-        ClassLoader envLoader, Class cls, boolean redefineAvailable) {
-        ClassMetaData meta = conf.getMetaDataRepositoryInstance()
-            .getMetaData(cls, envLoader, true);
-        configureMetaData(meta, conf, redefineAvailable, true);
-    }
-
-    private static void configureMetaData(ClassMetaData meta,
-        OpenJPAConfiguration conf, boolean redefineAvailable, boolean warn) {
-
-        setDetachedState(meta);
-
-        if (warn && meta.getAccessType() == ClassMetaData.ACCESS_FIELD
-            && !redefineAvailable) {
-            // only warn about declared fields; superclass fields will be
-            // warned about when the superclass is handled
-            for (FieldMetaData fmd : meta.getDeclaredFields()) {
-                switch (fmd.getTypeCode()) {
-                    case JavaTypes.COLLECTION:
-                    case JavaTypes.MAP:
-                        // we can lazily load these, since we own the
-                        // relationship container
-                        break;
-                    default:
-                        if (!fmd.isInDefaultFetchGroup()
-                            && !(fmd.isVersion() || fmd.isPrimaryKey())) {
-                            Log log = conf.getLog(
-                                OpenJPAConfiguration.LOG_ENHANCE);
-                            log.warn(_loc.get("subclasser-fetch-group-override",
-                                meta.getDescribedType().getName(),
-                                fmd.getName()));
-                            fmd.setInDefaultFetchGroup(true);
-                        }
-                }
-            }
-        }
-    }
-
-    private static void write(BCClass bc, PCEnhancer enhancer,
-        Map<Class, byte[]> map, Class cls, List subs, List ints)
-        throws IOException {
-
-        if (bc == enhancer.getManagedTypeBytecode()) {
-            // if it was already defined, don't put it in the map,
-            // but do set the metadata accordingly.
-            if (enhancer.isAlreadyRedefined())
-                ints.add(bc.getType());
-            else if (JavaVersions.VERSION >= 5)
-                map.put(bc.getType(), bc.toByteArray());
-        } else {
-            if (!enhancer.isAlreadySubclassed()) {
-                // this is the new subclass
-                ClassLoader loader = GeneratedClasses.getMostDerivedLoader(
-                    cls, PersistenceCapable.class);
-                subs.add(GeneratedClasses.loadBCClass(bc, loader));
-            }
-        }
-    }
-
-    private static void setIntercepting(OpenJPAConfiguration conf,
-        ClassLoader envLoader, Class cls) {
-        ClassMetaData meta = conf.getMetaDataRepositoryInstance()
-            .getMetaData(cls, envLoader, true);
-        meta.setIntercepting(true);
-    }
-
-    /**
-     * If the metadata is configured to use a synthetic
-     * detached state, reset it to not use a detached
-     * state field, since we can't add fields when redefining.
-     */
-    private static void setDetachedState(ClassMetaData meta) {
-        if (ClassMetaData.SYNTHETIC.equals(meta.getDetachedState()))
-            meta.setDetachedState(null);
-    }
-}
+/*
+ * 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.
+ */
+package org.apache.openjpa.enhance;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import org.apache.openjpa.conf.OpenJPAConfiguration;
+import org.apache.openjpa.lib.log.Log;
+import org.apache.openjpa.lib.util.BytecodeWriter;
+import org.apache.openjpa.lib.util.JavaVersions;
+import org.apache.openjpa.lib.util.Localizer;
+import org.apache.openjpa.lib.util.Localizer.Message;
+import org.apache.openjpa.meta.ClassMetaData;
+import org.apache.openjpa.meta.FieldMetaData;
+import org.apache.openjpa.meta.JavaTypes;
+import org.apache.openjpa.util.GeneratedClasses;
+import org.apache.openjpa.util.ImplHelper;
+import org.apache.openjpa.util.InternalException;
+import org.apache.openjpa.util.UserException;
+import serp.bytecode.BCClass;
+
+/**
+ * Redefines the method bodies of existing unenhanced classes to make them
+ * notify state managers of mutations.
+ *
+ * @since 1.0.0
+ */
+public class ManagedClassSubclasser {
+    private static final Localizer _loc = Localizer.forPackage(
+        ManagedClassSubclasser.class);
+
+    /**
+     * For each element in <code>classes</code>, creates and registers a
+     * new subclass that implements {@link PersistenceCapable}, and prepares
+     * OpenJPA to handle new instances of the unenhanced type. If this is
+     * invoked in a Java 6 environment, this method will redefine the methods
+     * for each class in the argument list such that field accesses are
+     * intercepted in-line. If invoked in a Java 5 environment, this
+     * redefinition is not possible; in these contexts, when using field
+     * access, OpenJPA will need to do state comparisons to detect any change
+     * to any instance at any time, and when using property access, OpenJPA
+     * will need to do state comparisons to detect changes to newly inserted
+     * instances after a flush has been called.
+     *
+     * @return the new subclasses, or <code>null</code> if <code>classes</code>
+     * is <code>null</code>.
+     * @throws UserException if <code>conf</code> requires build-time
+     * enhancement and <code>classes</code> includes unenhanced types.
+     *
+     * @since 1.0.0
+     */
+    public static List<Class> prepareUnenhancedClasses(
+        final OpenJPAConfiguration conf,
+        final Collection<? extends Class> classes,
+        final ClassLoader envLoader) {
+        if (classes == null)
+            return null;
+        if (classes.size() == 0)
+            return Collections.EMPTY_LIST;
+
+        Log log = conf.getLog(OpenJPAConfiguration.LOG_ENHANCE);
+        if (conf.getRuntimeUnenhancedClassesConstant()
+            != RuntimeUnenhancedClasssesModes.SUPPORTED) {
+            Collection unenhanced = new ArrayList();
+            for (Class cls : classes)
+                if (!PersistenceCapable.class.isAssignableFrom(cls))
+                    unenhanced.add(cls);
+            if (unenhanced.size() > 0) {
+                Message msg = _loc.get("runtime-optimization-disabled",
+                    unenhanced);
+                if (conf.getRuntimeUnenhancedClassesConstant()
+                    == RuntimeUnenhancedClasssesModes.WARN)
+                    log.warn(msg);
+                else
+                    throw new UserException(msg);
+            }
+            return null;
+        }
+
+        boolean redefine = ClassRedefiner.canRedefineClasses();
+        if (redefine)
+            log.info(_loc.get("enhance-and-subclass-and-redef-start",
+                classes));
+        else
+            log.info(_loc.get("enhance-and-subclass-no-redef-start",
+                classes));
+
+        final Map<Class, byte[]> map = new HashMap<Class, byte[]>();
+        final List subs = new ArrayList(classes.size());
+        final List ints = new ArrayList(classes.size());
+        Set<Class> unspecified = null;
+        for (Iterator iter = classes.iterator(); iter.hasNext(); ) {
+            final Class cls = (Class) iter.next();
+            final PCEnhancer enhancer = new PCEnhancer(conf, cls);
+
+            enhancer.setBytecodeWriter(new BytecodeWriter() {
+                public void write(BCClass bc) throws IOException {
+                    ManagedClassSubclasser.write(bc, enhancer, map,
+                        cls, subs, ints);
+                }
+            });
+            if (redefine)
+                enhancer.setRedefine(true);
+            enhancer.setCreateSubclass(true);
+            enhancer.setAddDefaultConstructor(true);
+
+            // set this before enhancement as well as after since enhancement
+            // uses a different metadata repository, and the metadata config
+            // matters in the enhancement contract. Don't do any warning here,
+            // since we'll issue warnings when we do the final metadata
+            // reconfiguration at the end of this method.
+            configureMetaData(enhancer.getMetaData(), conf, redefine, false);
+
+            unspecified = collectRelatedUnspecifiedTypes(enhancer.getMetaData(),
+                classes, unspecified);
+
+            int runResult = enhancer.run();
+            if (runResult == PCEnhancer.ENHANCE_PC) {
+                try {
+                    enhancer.record();
+                } catch (IOException e) {
+                    // our impl of BytecodeWriter doesn't throw IOException
+                    throw new InternalException(e);
+                }
+            }
+        }
+
+        if (unspecified != null && !unspecified.isEmpty())
+            throw new UserException(_loc.get("unspecified-unenhanced-types",
+                classes, unspecified));
+
+        ClassRedefiner.redefineClasses(conf, map);
+        for (Class cls : map.keySet()) {
+            setIntercepting(conf, envLoader, cls);
+            configureMetaData(conf, envLoader, cls, redefine);
+        }
+        for (Class cls : (Collection<Class>) subs)
+            configureMetaData(conf, envLoader, cls, redefine);
+        for (Class cls : (Collection<Class>) ints)
+            setIntercepting(conf, envLoader, cls);
+
+        return subs;
+    }
+
+    private static Set<Class> collectRelatedUnspecifiedTypes(ClassMetaData meta,
+        Collection<? extends Class> classes, Set<Class> unspecified) {
+        unspecified = collectUnspecifiedType(meta.getPCSuperclass(), classes,
+            unspecified);
+
+        for (FieldMetaData fmd : meta.getFields()) {
+            if (fmd.isTransient())
+                continue;
+            if (fmd.isTypePC())
+                unspecified = collectUnspecifiedType(fmd.getType(), classes,
+                    unspecified);
+            if (fmd.getElement() != null && fmd.getElement().isTypePC())
+                unspecified = collectUnspecifiedType(fmd.getElement().getType(),
+                    classes, unspecified);
+            if (fmd.getKey() != null && fmd.getKey().isTypePC())
+                unspecified = collectUnspecifiedType(fmd.getKey().getType(),
+                    classes, unspecified);
+            if (fmd.getValue() != null && fmd.getValue().isTypePC())
+                unspecified = collectUnspecifiedType(fmd.getValue().getType(),
+                    classes, unspecified);
+        }
+        return unspecified;
+    }
+
+    private static Set<Class> collectUnspecifiedType(Class cls,
+        Collection<? extends Class> classes, Set<Class> unspecified) {
+        if (cls != null && !classes.contains(cls)
+            && !ImplHelper.isManagedType(null, cls)) {
+            if (unspecified == null)
+                unspecified = new HashSet<Class>();
+            unspecified.add(cls);
+        }
+        return unspecified;
+    }
+
+    private static void configureMetaData(OpenJPAConfiguration conf,
+        ClassLoader envLoader, Class cls, boolean redefineAvailable) {
+        ClassMetaData meta = conf.getMetaDataRepositoryInstance()
+            .getMetaData(cls, envLoader, true);
+        configureMetaData(meta, conf, redefineAvailable, true);
+    }
+
+    private static void configureMetaData(ClassMetaData meta,
+        OpenJPAConfiguration conf, boolean redefineAvailable, boolean warn) {
+
+        setDetachedState(meta);
+
+        if (warn && meta.getAccessType() == ClassMetaData.ACCESS_FIELD
+            && !redefineAvailable) {
+            // only warn about declared fields; superclass fields will be
+            // warned about when the superclass is handled
+            for (FieldMetaData fmd : meta.getDeclaredFields()) {
+                switch (fmd.getTypeCode()) {
+                    case JavaTypes.COLLECTION:
+                    case JavaTypes.MAP:
+                        // we can lazily load these, since we own the
+                        // relationship container
+                        break;
+                    default:
+                        if (!fmd.isInDefaultFetchGroup()
+                            && !(fmd.isVersion() || fmd.isPrimaryKey())) {
+                            Log log = conf.getLog(
+                                OpenJPAConfiguration.LOG_ENHANCE);
+                            log.warn(_loc.get("subclasser-fetch-group-override",
+                                meta.getDescribedType().getName(),
+                                fmd.getName()));
+                            fmd.setInDefaultFetchGroup(true);
+                        }
+                }
+            }
+        }
+    }
+
+    private static void write(BCClass bc, PCEnhancer enhancer,
+        Map<Class, byte[]> map, Class cls, List subs, List ints)
+        throws IOException {
+
+        if (bc == enhancer.getManagedTypeBytecode()) {
+            // if it was already defined, don't put it in the map,
+            // but do set the metadata accordingly.
+            if (enhancer.isAlreadyRedefined())
+                ints.add(bc.getType());
+            else if (JavaVersions.VERSION >= 5)
+                map.put(bc.getType(), bc.toByteArray());
+        } else {
+            if (!enhancer.isAlreadySubclassed()) {
+                // this is the new subclass
+                ClassLoader loader = GeneratedClasses.getMostDerivedLoader(
+                    cls, PersistenceCapable.class);
+                subs.add(GeneratedClasses.loadBCClass(bc, loader));
+            }
+        }
+    }
+
+    private static void setIntercepting(OpenJPAConfiguration conf,
+        ClassLoader envLoader, Class cls) {
+        ClassMetaData meta = conf.getMetaDataRepositoryInstance()
+            .getMetaData(cls, envLoader, true);
+        meta.setIntercepting(true);
+    }
+
+    /**
+     * If the metadata is configured to use a synthetic
+     * detached state, reset it to not use a detached
+     * state field, since we can't add fields when redefining.
+     */
+    private static void setDetachedState(ClassMetaData meta) {
+        if (ClassMetaData.SYNTHETIC.equals(meta.getDetachedState()))
+            meta.setDetachedState(null);
+    }
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/ManagedClassSubclasser.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel-5/src/main/java/org/apache/openjpa/enhance/PCEnhancerAgent.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel-5/src/test/java/org/apache/openjpa/enhance/TestGetDeclaredMethod.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel-5/src/test/java/org/apache/openjpa/enhance/TestGetDeclaredMethod.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel-5/src/test/java/org/apache/openjpa/enhance/TestGetDeclaredMethod.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel-5/src/test/java/org/apache/openjpa/enhance/TestGetDeclaredMethod.java Sun Mar 22 23:45:15 2009
@@ -1,93 +1,93 @@
-/*
- * 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.
- */
-package org.apache.openjpa.enhance;
-
-import java.lang.reflect.Method;
-import java.util.List;
-import java.util.ArrayList;
-
-import junit.framework.TestCase;
-
-/**
- * Tests that {@link Reflection#getDeclaredMethod(Class, String, Class)}
- * returns the most-derived class's method when called from a type hierarchy.
- * See OPENJPA-251.
- */
-public class TestGetDeclaredMethod extends TestCase {
-
-    public void testGetDeclaredMethod() {
-        Method meth =
-            Reflection.getDeclaredMethod(Impl.class, "getObject", null);
-        assertEquals(Impl.class, meth.getDeclaringClass());
-        assertEquals(String.class, meth.getReturnType());
-    }
-
-    public void testMostDerived() throws NoSuchMethodException {
-        Method impl = Impl.class.getDeclaredMethod("getObject", null);
-        Method iface = Iface.class.getDeclaredMethod("getObject", null);
-        Method other = Other.class.getDeclaredMethod("getObject", null);
-        assertEquals(Impl.class, Reflection.mostDerived(impl, iface)
-            .getDeclaringClass());
-        assertEquals(Impl.class, Reflection.mostDerived(iface, impl)
-            .getDeclaringClass());
-        try {
-            Reflection.mostDerived(iface, other);
-            fail("'iface' and 'other' are not from related types");
-        } catch (IllegalArgumentException e) {
-            // expected
-        }
-    }
-
-    public void testGenerics() throws NoSuchMethodException {
-        List<Method> meths = new ArrayList<Method>();
-        for (Method meth : GenericsImpl.class.getDeclaredMethods()) {
-            if ("getObject".equals(meth.getName()))
-                meths.add(meth);
-        }
-        assertEquals(2, meths.size());
-        assertEquals(String.class, Reflection.mostDerived(meths.get(0),
-            meths.get(1)).getReturnType());
-    }
-    
-    interface Iface {
-        Object getObject();
-    }
-
-    static class Impl implements Iface {
-        public String getObject() {
-            return "string";
-        }
-    }
-
-    static class Other {
-        public String getObject() {
-            return "other";
-        }
-    }
-
-    interface GenericsIface<T> {
-        public T getObject();
-    }
-
-    static class GenericsImpl implements GenericsIface {
-        public String getObject() {
-            return null;
-        }
-    }
-}
+/*
+ * 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.
+ */
+package org.apache.openjpa.enhance;
+
+import java.lang.reflect.Method;
+import java.util.List;
+import java.util.ArrayList;
+
+import junit.framework.TestCase;
+
+/**
+ * Tests that {@link Reflection#getDeclaredMethod(Class, String, Class)}
+ * returns the most-derived class's method when called from a type hierarchy.
+ * See OPENJPA-251.
+ */
+public class TestGetDeclaredMethod extends TestCase {
+
+    public void testGetDeclaredMethod() {
+        Method meth =
+            Reflection.getDeclaredMethod(Impl.class, "getObject", null);
+        assertEquals(Impl.class, meth.getDeclaringClass());
+        assertEquals(String.class, meth.getReturnType());
+    }
+
+    public void testMostDerived() throws NoSuchMethodException {
+        Method impl = Impl.class.getDeclaredMethod("getObject", null);
+        Method iface = Iface.class.getDeclaredMethod("getObject", null);
+        Method other = Other.class.getDeclaredMethod("getObject", null);
+        assertEquals(Impl.class, Reflection.mostDerived(impl, iface)
+            .getDeclaringClass());
+        assertEquals(Impl.class, Reflection.mostDerived(iface, impl)
+            .getDeclaringClass());
+        try {
+            Reflection.mostDerived(iface, other);
+            fail("'iface' and 'other' are not from related types");
+        } catch (IllegalArgumentException e) {
+            // expected
+        }
+    }
+
+    public void testGenerics() throws NoSuchMethodException {
+        List<Method> meths = new ArrayList<Method>();
+        for (Method meth : GenericsImpl.class.getDeclaredMethods()) {
+            if ("getObject".equals(meth.getName()))
+                meths.add(meth);
+        }
+        assertEquals(2, meths.size());
+        assertEquals(String.class, Reflection.mostDerived(meths.get(0),
+            meths.get(1)).getReturnType());
+    }
+    
+    interface Iface {
+        Object getObject();
+    }
+
+    static class Impl implements Iface {
+        public String getObject() {
+            return "string";
+        }
+    }
+
+    static class Other {
+        public String getObject() {
+            return "other";
+        }
+    }
+
+    interface GenericsIface<T> {
+        public T getObject();
+    }
+
+    static class GenericsImpl implements GenericsIface {
+        public String getObject() {
+            return null;
+        }
+    }
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel-5/src/test/java/org/apache/openjpa/enhance/TestGetDeclaredMethod.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/abstractstore/AbstractStoreBrokerFactory.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/abstractstore/AbstractStoreManager.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ant/ApplicationIdToolTask.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ant/MetaDataToolTask.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ant/PCEnhancerTask.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/AutoDetachValue.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/BrokerFactoryValue.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/Compatibility.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/DetachOptions.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAConfiguration.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAConfigurationImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAProductDerivation.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAProductDerivation.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAProductDerivation.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAProductDerivation.java Sun Mar 22 23:45:15 2009
@@ -1,43 +1,43 @@
-/*
- * 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.    
- */
-package org.apache.openjpa.conf;
-
-import org.apache.openjpa.lib.conf.ProductDerivation;
-import java.util.Map;
-
-/**
- * Adds datastore based extension to ProductDerivation.  
- *
- * @since 0.4.1
- * @author Pinaki Poddar
- */
-public interface OpenJPAProductDerivation extends ProductDerivation {
-
-    public static final int TYPE_SPEC = 0;
-    public static final int TYPE_STORE = 200;
-    public static final int TYPE_SPEC_STORE = 300;
-    public static final int TYPE_PRODUCT_STORE = 400;
-
-    /**
-     * Load default alias options into the given map.  Each entry maps an
-     * alias to a broker factory class name.  Replace anything previously 
-     * under the desired keys.
-     */
-    public void putBrokerFactoryAliases(Map aliases);
-}
+/*
+ * 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.    
+ */
+package org.apache.openjpa.conf;
+
+import org.apache.openjpa.lib.conf.ProductDerivation;
+import java.util.Map;
+
+/**
+ * Adds datastore based extension to ProductDerivation.  
+ *
+ * @since 0.4.1
+ * @author Pinaki Poddar
+ */
+public interface OpenJPAProductDerivation extends ProductDerivation {
+
+    public static final int TYPE_SPEC = 0;
+    public static final int TYPE_STORE = 200;
+    public static final int TYPE_SPEC_STORE = 300;
+    public static final int TYPE_PRODUCT_STORE = 400;
+
+    /**
+     * Load default alias options into the given map.  Each entry maps an
+     * alias to a broker factory class name.  Replace anything previously 
+     * under the desired keys.
+     */
+    public void putBrokerFactoryAliases(Map aliases);
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAProductDerivation.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/OpenJPAVersion.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/QueryCompilationCacheValue.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/QueryCompilationCacheValue.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/QueryCompilationCacheValue.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/QueryCompilationCacheValue.java Sun Mar 22 23:45:15 2009
@@ -1,94 +1,94 @@
-/*
- * 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.    
- */
-package org.apache.openjpa.conf;
-
-import java.util.Collections;
-import java.util.Hashtable;
-import java.util.Map;
-
-import org.apache.openjpa.lib.conf.Configuration;
-import org.apache.openjpa.lib.conf.PluginValue;
-import org.apache.openjpa.lib.util.concurrent.ConcurrentMap;
-import org.apache.openjpa.lib.util.concurrent.ConcurrentHashMap;
-import org.apache.openjpa.lib.util.ParseException;
-import org.apache.openjpa.util.CacheMap;
-
-/**
- * A cache of compiled queries.
- *
- * @author Abe White
- * @since 0.9.6 (also existed in prior versions of Kodo)
- * @nojavadoc
- */
-public class QueryCompilationCacheValue
-    extends PluginValue {
-
-    public static final String[] ALIASES = {
-        "true", CacheMap.class.getName(),
-        "all", ConcurrentHashMap.class.getName(),
-        "false", null,
-    };
-
-    public QueryCompilationCacheValue(String prop) {
-        super(prop, true);
-        setAliases(ALIASES);
-        setDefault(ALIASES[0]);
-        setClassName(ALIASES[1]);
-    }
-
-    public Object newInstance(String clsName, Class type,
-        Configuration conf, boolean fatal) {
-        // make sure map handles concurrency
-        Map map;
-        
-        try {
-            map = (Map) super.newInstance(clsName, type, conf, fatal);
-        } catch (ParseException pe) {
-            // OPENJPA256: this class differs from most plugins in that
-            // the plugin type is the standard java interface Map.class (rather
-            // than an openjpa-specific interface), which means that the
-            // ClassLoader used to load the implementation will be the system
-            // class loader; this presents a problem if OpenJPA is not in the
-            // system classpath, so work around the problem by catching
-            // the ParseException (which is what we wrap the
-            // ClassNotFoundException in) and try again, this time using
-            // this class' ClassLoader.
-            map = (Map) super.newInstance(clsName,
-                QueryCompilationCacheValue.class, conf, fatal);
-        } catch (IllegalArgumentException iae) {
-            // OPENJPA256: this class differs from most plugins in that
-            // the plugin type is the standard java interface Map.class (rather
-            // than an openjpa-specific interface), which means that the
-            // ClassLoader used to load the implementation will be the system
-            // class loader; this presents a problem if OpenJPA is not in the
-            // system classpath, so work around the problem by catching
-            // the IllegalArgumentException (which is what we wrap the
-            // ClassNotFoundException in) and try again, this time using
-            // this class' ClassLoader.
-            map = (Map) super.newInstance(clsName,
-                QueryCompilationCacheValue.class, conf, fatal);
-        }
-
-        if (map != null && !(map instanceof Hashtable)
-            && !(map instanceof CacheMap)
-            && !(map instanceof ConcurrentMap))
-            map = Collections.synchronizedMap(map);
-        return map;
-	}
-}
+/*
+ * 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.    
+ */
+package org.apache.openjpa.conf;
+
+import java.util.Collections;
+import java.util.Hashtable;
+import java.util.Map;
+
+import org.apache.openjpa.lib.conf.Configuration;
+import org.apache.openjpa.lib.conf.PluginValue;
+import org.apache.openjpa.lib.util.concurrent.ConcurrentMap;
+import org.apache.openjpa.lib.util.concurrent.ConcurrentHashMap;
+import org.apache.openjpa.lib.util.ParseException;
+import org.apache.openjpa.util.CacheMap;
+
+/**
+ * A cache of compiled queries.
+ *
+ * @author Abe White
+ * @since 0.9.6 (also existed in prior versions of Kodo)
+ * @nojavadoc
+ */
+public class QueryCompilationCacheValue
+    extends PluginValue {
+
+    public static final String[] ALIASES = {
+        "true", CacheMap.class.getName(),
+        "all", ConcurrentHashMap.class.getName(),
+        "false", null,
+    };
+
+    public QueryCompilationCacheValue(String prop) {
+        super(prop, true);
+        setAliases(ALIASES);
+        setDefault(ALIASES[0]);
+        setClassName(ALIASES[1]);
+    }
+
+    public Object newInstance(String clsName, Class type,
+        Configuration conf, boolean fatal) {
+        // make sure map handles concurrency
+        Map map;
+        
+        try {
+            map = (Map) super.newInstance(clsName, type, conf, fatal);
+        } catch (ParseException pe) {
+            // OPENJPA256: this class differs from most plugins in that
+            // the plugin type is the standard java interface Map.class (rather
+            // than an openjpa-specific interface), which means that the
+            // ClassLoader used to load the implementation will be the system
+            // class loader; this presents a problem if OpenJPA is not in the
+            // system classpath, so work around the problem by catching
+            // the ParseException (which is what we wrap the
+            // ClassNotFoundException in) and try again, this time using
+            // this class' ClassLoader.
+            map = (Map) super.newInstance(clsName,
+                QueryCompilationCacheValue.class, conf, fatal);
+        } catch (IllegalArgumentException iae) {
+            // OPENJPA256: this class differs from most plugins in that
+            // the plugin type is the standard java interface Map.class (rather
+            // than an openjpa-specific interface), which means that the
+            // ClassLoader used to load the implementation will be the system
+            // class loader; this presents a problem if OpenJPA is not in the
+            // system classpath, so work around the problem by catching
+            // the IllegalArgumentException (which is what we wrap the
+            // ClassNotFoundException in) and try again, this time using
+            // this class' ClassLoader.
+            map = (Map) super.newInstance(clsName,
+                QueryCompilationCacheValue.class, conf, fatal);
+        }
+
+        if (map != null && !(map instanceof Hashtable)
+            && !(map instanceof CacheMap)
+            && !(map instanceof ConcurrentMap))
+            map = Collections.synchronizedMap(map);
+        return map;
+	}
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/QueryCompilationCacheValue.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/RemoteCommitProviderValue.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/conf/SeqValue.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/AbstractDataCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/AbstractQueryCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/Caches.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/ConcurrentDataCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/ConcurrentQueryCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCacheManager.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCacheManagerImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCData.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataGenerator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCacheScheduler.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCacheStoreManager.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DelegatingDataCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DelegatingQueryCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/ExpirationEvent.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/ExpirationListener.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/QueryCache.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/QueryCacheStoreQuery.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/QueryKey.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/QueryResult.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/TypesChangedEvent.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/TypesChangedListener.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/AutomaticManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/InvocationManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/JNDIManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/ManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/SunOneManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/WASManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/ee/WLSManagedRuntime.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/ApplicationIdTool.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/AttributeTranslator.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/AttributeTranslator.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/AttributeTranslator.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/AttributeTranslator.java Sun Mar 22 23:45:15 2009
@@ -1,31 +1,31 @@
-/*
- * 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.
- */
-package org.apache.openjpa.enhance;
-
-/**
- * Instances of this interface can convert a positional index for a
- * {@link FieldMetaData} that uses property access into the underlying
- * field name. Instances of {@link DynamicPersistenceCapable} for types
- * that use property access will implement this interface.
- *
- * @since 1.0.0
- */
-public interface AttributeTranslator {
-    public String pcAttributeIndexToFieldName(int i);
-}
+/*
+ * 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.
+ */
+package org.apache.openjpa.enhance;
+
+/**
+ * Instances of this interface can convert a positional index for a
+ * {@link FieldMetaData} that uses property access into the underlying
+ * field name. Instances of {@link DynamicPersistenceCapable} for types
+ * that use property access will implement this interface.
+ *
+ * @since 1.0.0
+ */
+public interface AttributeTranslator {
+    public String pcAttributeIndexToFieldName(int i);
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/AttributeTranslator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/CodeGenerator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPCHelper.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPCHelper.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPCHelper.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPCHelper.java Sun Mar 22 23:45:15 2009
@@ -1,30 +1,30 @@
-/*
- * 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.
- */
-package org.apache.openjpa.enhance;
-
-/**
- * Helper methods for dynamically-redefined managed types.
- *
- * @since 1.0.0
- */
-public class DynamicPCHelper {
-    public static boolean isDetached(Object o) {
-        throw new UnsupportedOperationException();
-    }
-}
+/*
+ * 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.
+ */
+package org.apache.openjpa.enhance;
+
+/**
+ * Helper methods for dynamically-redefined managed types.
+ *
+ * @since 1.0.0
+ */
+public class DynamicPCHelper {
+    public static boolean isDetached(Object o) {
+        throw new UnsupportedOperationException();
+    }
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPCHelper.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPersistenceCapable.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPersistenceCapable.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPersistenceCapable.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPersistenceCapable.java Sun Mar 22 23:45:15 2009
@@ -1,28 +1,28 @@
-/*
- * 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.
- */
-package org.apache.openjpa.enhance;
-
-/**
- * Instances that implement this marker interface are dynamically-generated
- * subtypes of managed types that were loaded before being enhanced.
- *
- * @since 1.0.0
- */
-public interface DynamicPersistenceCapable {
-}
+/*
+ * 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.
+ */
+package org.apache.openjpa.enhance;
+
+/**
+ * Instances that implement this marker interface are dynamically-generated
+ * subtypes of managed types that were loaded before being enhanced.
+ *
+ * @since 1.0.0
+ */
+public interface DynamicPersistenceCapable {
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicPersistenceCapable.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicStorage.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/DynamicStorageGenerator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/FieldConsumer.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/FieldManager.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/FieldSupplier.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/ManagedInstanceProvider.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/ManagedInstanceProvider.java?rev=757280&r1=757279&r2=757280&view=diff
==============================================================================
--- openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/ManagedInstanceProvider.java (original)
+++ openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/ManagedInstanceProvider.java Sun Mar 22 23:45:15 2009
@@ -1,28 +1,28 @@
-/*
- * 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.
- */
-package org.apache.openjpa.enhance;
-
-/**
- * Instances of this interface can provide an underlying instance.
- *
- * @since 1.0.0
- */
-public interface ManagedInstanceProvider {
-    public Object getManagedInstance();
-}
+/*
+ * 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.
+ */
+package org.apache.openjpa.enhance;
+
+/**
+ * Instances of this interface can provide an underlying instance.
+ *
+ * @since 1.0.0
+ */
+public interface ManagedInstanceProvider {
+    public Object getManagedInstance();
+}

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/ManagedInstanceProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCDataGenerator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCEnhancer.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: openjpa/branches/1.0.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCRegistry.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message