cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r423749 [3/4] - in /incubator/cayenne/main/trunk/cayenne/cayenne-java/src: cayenne/java/org/apache/cayenne/ cayenne/java/org/apache/cayenne/access/ cayenne/java/org/apache/cayenne/access/event/ cayenne/java/org/apache/cayenne/access/jdbc/ c...
Date Thu, 20 Jul 2006 04:04:10 GMT
Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/ClassGenerator.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/ClassGenerator.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/ClassGenerator.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/ClassGenerator.java Wed Jul 19 21:04:04 2006
@@ -17,21 +17,20 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.gen;
 
 import java.io.Writer;
 import java.util.Properties;
 
+import org.apache.cayenne.CayenneRuntimeException;
+import org.apache.cayenne.map.DataMap;
+import org.apache.cayenne.map.ObjEntity;
 import org.apache.velocity.Template;
 import org.apache.velocity.VelocityContext;
 import org.apache.velocity.app.VelocityEngine;
 import org.apache.velocity.context.Context;
 import org.apache.velocity.runtime.RuntimeConstants;
 import org.apache.velocity.runtime.log.NullLogSystem;
-import org.apache.cayenne.CayenneRuntimeException;
-import org.apache.cayenne.map.DataMap;
-import org.apache.cayenne.map.ObjEntity;
 
 import foundrylogic.vpp.VPPConfig;
 
@@ -54,23 +53,6 @@
     protected ClassGenerationInfo classGenerationInfo; // only used for VERSION_1_1
 
     /**
-     * @deprecated since 1.2, as now Cayenne uses thread ClassLoader.
-     */
-    public synchronized static final void bootstrapVelocity(Class cl) {
-        // noop
-    }
-
-    /**
-     * Creates a new ClassGenerationInfo that uses a specified Velocity template.
-     * 
-     * @deprecated Since 1.2 use ClassGenerator(String template, String versionString)
-     *             instead.
-     */
-    public ClassGenerator(String template) throws Exception {
-        this(template, "1.1");
-    }
-
-    /**
      * Creates a new ClassGenerationInfo that uses a specified Velocity template.
      * 
      * @since 1.2
@@ -151,7 +133,7 @@
         catch (Exception ex) {
             throw new CayenneRuntimeException("Can't initialize Velocity", ex);
         }
-        
+
         try {
             classTemplate = velocityEngine.getTemplate(template);
         }
@@ -214,213 +196,5 @@
      */
     public ClassGenerationInfo getClassGenerationInfo() {
         return classGenerationInfo;
-    }
-
-    /**
-     * Returns Java package name of the class associated with this generator.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getPackageName()
-     */
-    public String getPackageName() {
-        return classGenerationInfo.getPackageName();
-    }
-
-    /**
-     * Sets Java package name of the class associated with this generator.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().setPackageName()
-     */
-    public void setPackageName(String packageName) {
-        classGenerationInfo.setPackageName(packageName);
-    }
-
-    /**
-     * Sets <code>superPackageName</code> property that defines a superclass's package
-     * name.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().setSuperPackageName()
-     */
-    public void setSuperPackageName(String superPackageName) {
-        classGenerationInfo.setSuperPackageName(superPackageName);
-    }
-
-    /**
-     * Returns class name (without a package) of the class associated with this generator.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getClassName()
-     */
-    public String getClassName() {
-        return classGenerationInfo.getClassName();
-    }
-
-    /**
-     * Sets class name of the class associated with this generator. Class name must not
-     * include a package.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().setClassName()
-     */
-    public void setClassName(String className) {
-        classGenerationInfo.setClassName(className);
-    }
-
-    /**
-     * Sets the fully qualified super class of the data object class associated with this
-     * generator
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().setSuperClassName()
-     */
-    public void setSuperClassName(String value) {
-        classGenerationInfo.setSuperClassName(value);
-    }
-
-    /**
-     * Returns prefix used to distinguish between superclass and subclass when generating
-     * classes in pairs.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().setSuperPrefix()
-     */
-    public void setSuperPrefix(String superPrefix) {
-        classGenerationInfo.setSuperPrefix(superPrefix);
-    }
-
-    // deprecated, delegated methods not used internally in cayenne
-
-    /**
-     * Returns <code>superPackageName</code> property that defines a superclass's
-     * package name.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getSuperPackageName()
-     */
-    public String getSuperPackageName() {
-        return classGenerationInfo.getSuperPackageName();
-    }
-
-    /**
-     * @deprecated use getClassGenerationInfo().formatJavaType(String)
-     */
-    public String formatJavaType(String type) {
-        return classGenerationInfo.formatJavaType(type);
-    }
-
-    /**
-     * @deprecated Since 1.2 use getClassGenerationInfo().formatVariableName(String)
-     */
-    public String formatVariableName(String variableName) {
-        return classGenerationInfo.formatVariableName(variableName);
-    }
-
-    /**
-     * Returns prefix used to distinguish between superclass and subclass when generating
-     * classes in pairs.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getSuperPrefix()
-     */
-    public String getSuperPrefix() {
-        return classGenerationInfo.getSuperPrefix();
-    }
-
-    /**
-     * Sets current class property name. This method is called during template parsing for
-     * each of the class properties.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().setProp(String)
-     */
-    public void setProp(String prop) {
-        classGenerationInfo.setProp(prop);
-    }
-
-    /**
-     * @deprecated Since 1.2 use getClassGenerationInfo().getProp()
-     */
-    public String getProp() {
-        return classGenerationInfo.getProp();
-    }
-
-    /**
-     * Capitalizes the first letter of the property name.
-     * 
-     * @since 1.1
-     * @deprecated Since 1.2 use getClassGenerationInfo().capitalized(String)
-     */
-    public String capitalized(String name) {
-        return classGenerationInfo.capitalized(name);
-    }
-
-    /**
-     * Converts property name to Java constants naming convention.
-     * 
-     * @since 1.1
-     * @deprecated Since 1.2 use getClassGenerationInfo().capitalizedAsConstant(String)
-     */
-    public String capitalizedAsConstant(String name) {
-        return classGenerationInfo.capitalizedAsConstant(name);
-    }
-
-    /**
-     * Returns current property name with capitalized first letter
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getCappedProp()
-     */
-    public String getCappedProp() {
-        return classGenerationInfo.getCappedProp();
-    }
-
-    /**
-     * @return a current property name converted to a format used by java static final
-     *         variables - all capitalized with underscores.
-     * @since 1.0.3
-     * @deprecated Since 1.2 use getClassGenerationInfo().getPropAsConstantName()
-     */
-    public String getPropAsConstantName() {
-        return classGenerationInfo.getPropAsConstantName();
-    }
-
-    /**
-     * Returns true if current entity contains at least one List property.
-     * 
-     * @since 1.1
-     * @deprecated Since 1.2 use getClassGenerationInfo().isContainingListProperties()
-     */
-    public boolean isContainingListProperties() {
-        return classGenerationInfo.isContainingListProperties();
-    }
-
-    /**
-     * Returns <code>true</code> if a class associated with this generator is located in
-     * a package.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().isUsingPackage()
-     */
-    public boolean isUsingPackage() {
-        return classGenerationInfo.isUsingPackage();
-    }
-
-    /**
-     * Returns <code>true</code> if a superclass class associated with this generator is
-     * located in a package.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().isUsingSuperPackage()
-     */
-    public boolean isUsingSuperPackage() {
-        return classGenerationInfo.isUsingSuperPackage();
-    }
-
-    /**
-     * Returns entity for the class associated with this generator.
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getEntity()
-     */
-    public ObjEntity getEntity() {
-        return classGenerationInfo.getEntity();
-    }
-
-    /**
-     * Returns the fully qualified super class of the data object class associated with
-     * this generator
-     * 
-     * @deprecated Since 1.2 use getClassGenerationInfo().getSuperClassName()
-     */
-    public String getSuperClassName() {
-        return classGenerationInfo.getSuperClassName();
     }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/DefaultClassGenerator.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/DefaultClassGenerator.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/DefaultClassGenerator.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/DefaultClassGenerator.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.gen;
 
 import java.io.File;
@@ -77,17 +76,6 @@
         super(dataMap, selectedObjEntities);
     }
 
-    /**
-     * Creates class generator and initializes it with the list of ObjEntities that will
-     * be used in class generation.
-     * 
-     * @deprecated Use DefaultClassGenerator(DataMap, List) to provide support for v1.2
-     *             templates.
-     */
-    public DefaultClassGenerator(List selectedObjEntities) {
-        super(selectedObjEntities);
-    }
-
     /** Runs class generation. */
     public void execute() throws Exception {
         validateAttributes();
@@ -150,26 +138,6 @@
      */
     public void setMakePairs(boolean makePairs) {
         this.makePairs = makePairs;
-    }
-
-    /**
-     * Sets <code>template</code> property.
-     * 
-     * @deprecated since 1.2 use {@link #setTemplate(String)} as custom template can also
-     *             be looked up in CLASSPATH.
-     */
-    public void setTemplate(File template) {
-        this.template = template != null ? template.getPath() : null;
-    }
-
-    /**
-     * Sets <code>superTemplate</code> property.
-     * 
-     * @deprecated since 1.2 use {@link #setSuperTemplate(String)} as custom template can
-     *             also be looked up in CLASSPATH.
-     */
-    public void setSuperTemplate(File superTemplate) {
-        this.superTemplate = superTemplate != null ? superTemplate.getPath() : null;
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/MapClassGenerator.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/MapClassGenerator.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/MapClassGenerator.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/gen/MapClassGenerator.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.gen;
 
 import java.io.Writer;
@@ -102,14 +101,6 @@
         this.setObjEntities(objEntities);
     }
 
-    /**
-     * @deprecated Since 1.2 use MapClassGenerator(DataMap, List) to provide support for
-     *             v1.2 templates.
-     */
-    public MapClassGenerator(List objEntities) {
-        this.objEntities = objEntities;
-    }
-
     protected String defaultSingleClassTemplate() {
         // there is no default single class client template at the moment
         if (client) {
@@ -526,16 +517,6 @@
                             fqnSubClass);
             closeWriter(out);
         }
-    }
-
-    /**
-     * Runs class generation. Produces a single Java class for each ObjEntity in the map.
-     * 
-     * @deprecated Use generateSingleClasses(String classTemplate, String superPrefix)
-     *             instead.
-     */
-    public void generateSingleClasses(String classTemplate) throws Exception {
-        generateSingleClasses(classTemplate, SUPERCLASS_PREFIX);
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/AshwoodEntitySorter.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/AshwoodEntitySorter.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/AshwoodEntitySorter.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/AshwoodEntitySorter.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.map;
 
 import java.util.ArrayList;
@@ -29,6 +28,12 @@
 import java.util.List;
 import java.util.Map;
 
+import org.apache.cayenne.CayenneRuntimeException;
+import org.apache.cayenne.DataObject;
+import org.apache.cayenne.DataRow;
+import org.apache.cayenne.ObjectId;
+import org.apache.cayenne.PersistenceState;
+import org.apache.cayenne.access.DataContext;
 import org.apache.commons.collections.comparators.ReverseComparator;
 import org.objectstyle.ashwood.dbutil.DbUtils;
 import org.objectstyle.ashwood.dbutil.ForeignKey;
@@ -38,13 +43,6 @@
 import org.objectstyle.ashwood.graph.IndegreeTopologicalSort;
 import org.objectstyle.ashwood.graph.MapDigraph;
 import org.objectstyle.ashwood.graph.StrongConnection;
-import org.apache.cayenne.CayenneRuntimeException;
-import org.apache.cayenne.DataObject;
-import org.apache.cayenne.DataRow;
-import org.apache.cayenne.ObjectId;
-import org.apache.cayenne.PersistenceState;
-import org.apache.cayenne.access.DataContext;
-import org.apache.cayenne.access.QueryEngine;
 
 /**
  * Implements dependency sorting algorithms for ObjEntities, DbEntities and DataObjects.
@@ -77,7 +75,7 @@
         tableComparator = new TableComparator();
         dbEntityComparator = new DbEntityComparator();
         objEntityComparator = new ObjEntityComparator();
-        
+
         setDataMaps(dataMaps);
     }
 
@@ -135,16 +133,6 @@
     public synchronized void setDataMaps(Collection dataMaps) {
         this.dirty = true;
         this.dataMaps = dataMaps != null ? dataMaps : Collections.EMPTY_LIST;
-    }
-
-    /**
-     * Marks this instance as "dirty", so that it will be indexed lazily on the next
-     * invocation.
-     * 
-     * @deprecated since 1.2 - unused.
-     */
-    public void indexSorter(QueryEngine queryEngine) {
-        setDataMaps(queryEngine.getEntityResolver().getDataMaps());
     }
 
     public void sortDbEntities(List dbEntities, boolean deleteOrder) {

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/DataMap.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/DataMap.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/DataMap.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/DataMap.java Wed Jul 19 21:04:04 2006
@@ -559,16 +559,6 @@
     }
 
     /**
-     * Returns all ObjEntities in this DataMap, including entities from dependent maps if
-     * <code>includeDeps</code> is <code>true</code>.
-     * 
-     * @deprecated since 1.2 use getObjEntities().
-     */
-    public Collection getObjEntities(boolean includeDeps) {
-        return getObjEntities();
-    }
-
-    /**
      * Returns all DbEntities in this DataMap.
      */
     public Collection getDbEntities() {

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/EntityResolver.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/EntityResolver.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/EntityResolver.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/EntityResolver.java Wed Jul 19 21:04:04 2006
@@ -28,13 +28,13 @@
 import java.util.List;
 import java.util.Map;
 
-import org.apache.commons.collections.collection.CompositeCollection;
 import org.apache.cayenne.CayenneRuntimeException;
 import org.apache.cayenne.ObjectId;
 import org.apache.cayenne.Persistent;
 import org.apache.cayenne.property.ClassDescriptor;
 import org.apache.cayenne.property.ClassDescriptorFactory;
 import org.apache.cayenne.query.Query;
+import org.apache.commons.collections.collection.CompositeCollection;
 
 /**
  * Represents a virtual shared namespace for zero or more DataMaps. Unlike DataMap,
@@ -388,15 +388,6 @@
     }
 
     /**
-     * Searches for DataMap that holds Query root object.
-     * 
-     * @deprecated since 1.2 use 'Query.getMetaData(EntityResolver).getDataMap()'.
-     */
-    public synchronized DataMap lookupDataMap(Query q) {
-        return q.getMetaData(this).getDataMap();
-    }
-
-    /**
      * Looks in the DataMap's that this object was created with for the DbEntity that
      * services the specified class
      * 
@@ -420,17 +411,6 @@
     }
 
     /**
-     * Looks up the DbEntity for the given query by using the query's getRoot method and
-     * passing to lookupDbEntity
-     * 
-     * @return the root DbEntity of the query
-     * @deprecated since 1.2 use 'Query.getMetaData(EntityResolver).getDbEntity()'
-     */
-    public synchronized DbEntity lookupDbEntity(Query q) {
-        return q.getMetaData(this).getDbEntity();
-    }
-
-    /**
      * Returns EntityInheritanceTree representing inheritance hierarchy that starts with a
      * given ObjEntity as root, and includes all its subentities. If ObjEntity has no
      * known subentities, null is returned.
@@ -478,21 +458,6 @@
         ObjectId id = dataObject.getObjectId();
         Object key = id != null ? (Object) id.getEntityName() : dataObject.getClass();
         return this._lookupObjEntity(key);
-    }
-
-    /**
-     * Looks up the ObjEntity for the given query by using the query's getRoot method and
-     * passing to lookupObjEntity
-     * 
-     * @return the root ObjEntity of the query
-     * @throws CayenneRuntimeException if the root of the query is a DbEntity (it is not
-     *             reliably possible to map from a DbEntity to an ObjEntity as a DbEntity
-     *             may be the source for multiple ObjEntities. It is not safe to rely on
-     *             such behaviour).
-     * @deprecated since 1.2 use 'Query.getMetaData(EntityResolver).getObjEntity()'.
-     */
-    public synchronized ObjEntity lookupObjEntity(Query q) {
-        return q.getMetaData(this).getObjEntity();
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/MapLoader.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/MapLoader.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/MapLoader.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/MapLoader.java Wed Jul 19 21:04:04 2006
@@ -70,10 +70,6 @@
     // Query-related
     public static final String QUERY_TAG = "query";
 
-    /**
-     * @deprecated since 1.2 unused
-     */
-    public static final String QUERY_RESULT_COLUMN_TAG = "result-column";
     public static final String QUERY_SQL_TAG = "sql";
     public static final String QUERY_QUALIFIER_TAG = "qualifier";
     public static final String QUERY_ORDERING_TAG = "ordering";
@@ -683,7 +679,6 @@
 
         String rootType = attributes.getValue("", "root");
         String rootName = attributes.getValue("", "root-name");
-        String resultType = attributes.getValue("", "result-type");
         String resultEntity = attributes.getValue("", "result-entity");
 
         queryBuilder.setName(name);
@@ -691,10 +686,7 @@
 
         // TODO: Andrus, 2/13/2006 'result-type' is only used in ProcedureQuery and is
         // deprecated in 1.2
-        if (Util.isEmptyString(resultEntity)) {
-            queryBuilder.setResultType(resultType);
-        }
-        else {
+        if (!Util.isEmptyString(resultEntity)) {
             queryBuilder.setResultEntity(resultEntity);
         }
     }
@@ -870,7 +862,7 @@
     private void resetCurrentTag() {
         currentTag = null;
     }
-    
+
     /**
      * @since 2.0
      */

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjAttribute.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjAttribute.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjAttribute.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjAttribute.java Wed Jul 19 21:04:04 2006
@@ -17,17 +17,15 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.map;
 
 import java.util.Iterator;
 
-import org.apache.commons.collections.IteratorUtils;
-import org.apache.commons.lang.StringUtils;
-import org.apache.cayenne.CayenneException;
 import org.apache.cayenne.CayenneRuntimeException;
 import org.apache.cayenne.util.Util;
 import org.apache.cayenne.util.XMLEncoder;
+import org.apache.commons.collections.IteratorUtils;
+import org.apache.commons.lang.StringUtils;
 
 /**
  * An ObjAttribute is a mapping descriptor of a Java class property.
@@ -232,74 +230,6 @@
 
     public boolean isCompound() {
         return (dbAttributePath != null && dbAttributePath.indexOf('.') >= 0);
-    }
-
-    /**
-     * @deprecated Since 1.2 unused.
-     */
-    public boolean mapsToDependentDbEntity() {
-        Iterator i = getDbPathIterator();
-        if (!i.hasNext()) {
-            return false;
-        }
-
-        Object o = i.next();
-        if (!i.hasNext()) {
-            return false;
-        }
-
-        Object o1 = i.next();
-        if (!(o1 instanceof DbAttribute)) {
-            return false;
-        }
-
-        DbRelationship toDependent = (DbRelationship) o;
-        return toDependent.isToDependentPK();
-    }
-
-    /**
-     * @deprecated Since 1.2 unused.
-     */
-    public void validate() throws CayenneException {
-        String head = "ObjAttribute: " + getName() + " ";
-        ObjEntity ent = (ObjEntity) getEntity();
-        if (ent == null) {
-            throw new CayenneException(head + "Parent ObjEntity not defined.");
-        }
-        head += "ObjEntity: " + ent.getName() + " ";
-
-        if (getName() == null)
-            throw new CayenneException(head + "ObjAttribute's name not defined.");
-
-        if (getDbAttributePath() == null)
-            throw new CayenneException(head + "dbAttributePath not defined.");
-
-        try {
-            Iterator i = getDbPathIterator();
-            boolean dbAttributeFound = false;
-            while (i.hasNext()) {
-                Object pathPart = i.next();
-                if (pathPart instanceof DbRelationship) {
-                    DbRelationship r = (DbRelationship) pathPart;
-                    if (r.isToMany())
-                        throw new CayenneException(head
-                                + "DbRelationship: "
-                                + r.getName()
-                                + " is to-many.");
-                }
-                else if (pathPart instanceof DbAttribute) {
-                    dbAttributeFound = true;
-                }
-            }
-            if (!dbAttributeFound)
-                throw new CayenneException(head + "DbAttribute not found.");
-        }
-        catch (CayenneException ex) {
-            throw ex;
-        }
-        catch (Exception ex) {
-            throw new CayenneException(head + ex.getMessage(), ex);
-        }
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjEntity.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjEntity.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjEntity.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ObjEntity.java Wed Jul 19 21:04:04 2006
@@ -191,17 +191,6 @@
     }
 
     /**
-     * Returns Java class of persistent objects described by this entity. Casts any thrown
-     * exceptions into CayenneRuntimeException.
-     * 
-     * @deprecated since 1.2 thread ClassLoader is used.
-     * @since 1.0.7
-     */
-    public Class getJavaClass(ClassLoader classLoader) {
-        return getJavaClass();
-    }
-
-    /**
      * Returns Java class of persistent objects described by this entity. For generic
      * entities with no class specified explicitly, default DataMap superclass is used,
      * and if it is not set - CayenneDataObject is used. Casts any thrown exceptions into

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ProcedureParameter.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ProcedureParameter.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ProcedureParameter.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/ProcedureParameter.java Wed Jul 19 21:04:04 2006
@@ -136,15 +136,6 @@
         return direction;
     }
 
-    /**
-     * Returns the procedure that holds this parameter.
-     * 
-     * @deprecated since 1.2 use getProcedure() instead.
-     */
-    public Procedure getEntity() {
-        return getProcedure();
-    }
-
     public int getMaxLength() {
         return maxLength;
     }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/QueryBuilder.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/QueryBuilder.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/QueryBuilder.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/map/QueryBuilder.java Wed Jul 19 21:04:04 2006
@@ -21,7 +21,6 @@
 
 import java.util.ArrayList;
 import java.util.HashMap;
-import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 
@@ -57,11 +56,6 @@
     protected DataMap dataMap;
     protected String rootType;
     protected String rootName;
-
-    /**
-     * @deprecated since 1.2 as "selecting" query property is no longer relevant.
-     */
-    protected boolean selecting = true;
     protected String resultEntity;
 
     /**
@@ -104,34 +98,6 @@
         return (root != null) ? root : dataMap;
     }
 
-    /**
-     * @deprecated since 1.2 as "selecting" query property is no longer relevant.
-     */
-    public void setSelecting(String selecting) {
-        // "true" is a default per DTD
-        this.selecting = ("false".equalsIgnoreCase(selecting)) ? false : true;
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void setResultType(String resultType) {
-        this.resultEntity = null;
-
-        if (resultType != null) {
-
-            // find entity with matching class name
-            Iterator it = dataMap.getObjEntities().iterator();
-            while (it.hasNext()) {
-                ObjEntity next = (ObjEntity) it.next();
-                if (resultType.equals(next.getClassName())) {
-                    this.resultEntity = next.getName();
-                    break;
-                }
-            }
-        }
-    }
-
     public void setResultEntity(String resultEntity) {
         this.resultEntity = resultEntity;
     }
@@ -179,17 +145,6 @@
         properties.put(name, value);
     }
 
-    /**
-     * @deprecated since 1.2 unused.
-     */
-    public void addResultColumn(String label, String dbType, String objectType) {
-        if (resultColumns == null) {
-            resultColumns = new ArrayList();
-        }
-
-        resultColumns.add(new ResultColumn(label, dbType, objectType));
-    }
-
     public void addOrdering(String path, String descending, String ignoreCase) {
         if (orderings == null) {
             orderings = new ArrayList();
@@ -213,18 +168,5 @@
             prefetches = new ArrayList();
         }
         prefetches.add(path.trim());
-    }
-
-    static class ResultColumn {
-
-        String label;
-        String dbType;
-        String objectType;
-
-        ResultColumn(String label, String dbType, String objectType) {
-            this.label = label;
-            this.dbType = dbType;
-            this.objectType = objectType;
-        }
     }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/ApplicationProject.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/ApplicationProject.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/ApplicationProject.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/ApplicationProject.java Wed Jul 19 21:04:04 2006
@@ -108,14 +108,6 @@
     }
 
     /**
-     * @since 1.1
-     * @deprecated since 1.2
-     */
-    protected void loadProject(File projectFile) throws Exception {
-        loadProject();
-    }
-
-    /**
      * @since 1.2
      */
     protected void loadProject() {

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/Project.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/Project.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/Project.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/Project.java Wed Jul 19 21:04:04 2006
@@ -26,10 +26,10 @@
 import java.util.Iterator;
 import java.util.List;
 
-import org.apache.log4j.Logger;
 import org.apache.cayenne.conf.ConfigStatus;
 import org.apache.cayenne.conf.Configuration;
 import org.apache.cayenne.project.validator.Validator;
+import org.apache.log4j.Logger;
 
 /**
  * Describes a model of Cayenne project. Project is a set of files in the filesystem
@@ -134,15 +134,6 @@
      */
     public boolean isLocationUndefined() {
         return getMainFile() == null;
-    }
-
-    /**
-     * Returns true if the project needs to be upgraded.
-     * 
-     * @deprecated since 2.0 use 'getUpgradeStatus'.
-     */
-    public boolean isUpgradeNeeded() {
-        return upgradeStatus < 0;
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/validator/SQLTemplateValidator.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/validator/SQLTemplateValidator.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/validator/SQLTemplateValidator.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/project/validator/SQLTemplateValidator.java Wed Jul 19 21:04:04 2006
@@ -98,15 +98,4 @@
             }
         }
     }
-
-    /**
-     * @deprecated unused since 1.2
-     */
-    protected void validateResultType(
-            SQLTemplate query,
-            ProjectPath path,
-            Validator validator) {
-
-        // noop
-    }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/AbstractQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/AbstractQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/AbstractQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/AbstractQuery.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.query;
 
 import org.apache.commons.lang.builder.ToStringBuilder;

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/BatchQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/BatchQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/BatchQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/BatchQuery.java Wed Jul 19 21:04:04 2006
@@ -19,16 +19,15 @@
 
 package org.apache.cayenne.query;
 
-import java.util.ArrayList;
 import java.util.List;
 import java.util.Map;
 
-import org.apache.commons.collections.Factory;
 import org.apache.cayenne.CayenneRuntimeException;
 import org.apache.cayenne.ObjectId;
 import org.apache.cayenne.map.DbAttribute;
 import org.apache.cayenne.map.DbEntity;
 import org.apache.cayenne.map.EntityResolver;
+import org.apache.commons.collections.Factory;
 
 /**
  * BatchQuery and its descendants allow to group similar data for the batch database
@@ -80,26 +79,6 @@
     }
 
     /**
-     * @deprecated since 1.2 as the corresponding interface method is also deprecated.
-     */
-    public Object getRoot() {
-        return dbEntity;
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void setRoot(Object root) {
-        if (root == null || root instanceof DbEntity) {
-            this.dbEntity = (DbEntity) root;
-        }
-        else {
-            throw new CayenneRuntimeException("Only DbEntity is supported as root: "
-                    + root);
-        }
-    }
-
-    /**
      * @since 1.2
      */
     public void route(QueryRouter router, EntityResolver resolver, Query substitutedQuery) {
@@ -135,28 +114,6 @@
     }
 
     /**
-     * Returns a List of values for the current batch iteration, in the order they are
-     * bound to the query. Used mainly for logging.
-     * 
-     * @param includeNullValues A <code>true</code> value indicates that the returned
-     *            list should include <code>null</code> values and <code>false</code>
-     *            indicates they should not be included.
-     * @deprecated Since 1.2 use BatchQueryBuilder.getParameterValues(), as this allows
-     *             better control over which attributes are logged.
-     */
-    public List getValuesForUpdateParameters(boolean includeNullValues) {
-        int len = getDbAttributes().size();
-        List values = new ArrayList(len);
-        for (int i = 0; i < len; i++) {
-            Object value = getObject(i);
-            if (includeNullValues || value != null) {
-                values.add(value);
-            }
-        }
-        return values;
-    }
-
-    /**
      * Returns <code>true</code> if this batch query has no parameter rows.
      */
     public boolean isEmpty() {
@@ -183,13 +140,6 @@
     public boolean next() {
         batchIndex++;
         return size() > batchIndex;
-    }
-
-    /**
-     * @deprecated Since 1.2 renamed to "getValue()"
-     */
-    public Object getObject(int valueIndex) {
-        return getValue(valueIndex);
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/IndirectQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/IndirectQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/IndirectQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/IndirectQuery.java Wed Jul 19 21:04:04 2006
@@ -88,22 +88,4 @@
                 + "It should've been delegated to another "
                 + "query during resolution or routing phase.");
     }
-
-    /**
-     * This implementation throws an exception.
-     * 
-     * @deprecated since 1.2
-     */
-    public Object getRoot() {
-        throw new CayenneRuntimeException("This deprecated method is not implemented");
-    }
-
-    /**
-     * Throws an exception.
-     * 
-     * @deprecated since 1.2
-     */
-    public void setRoot(Object root) {
-        throw new CayenneRuntimeException("This deprecated method is not implemented");
-    }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/InvalidateListCacheQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/InvalidateListCacheQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/InvalidateListCacheQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/InvalidateListCacheQuery.java Wed Jul 19 21:04:04 2006
@@ -93,13 +93,6 @@
         return null;
     }
 
-    /**
-     * @deprecated since 1.2
-     */
-    public Object getRoot() {
-        return null;
-    }
-
     public void route(QueryRouter router, EntityResolver resolver, Query substitutedQuery) {
         // noop
     }
@@ -107,19 +100,4 @@
     public SQLAction createSQLAction(SQLActionVisitor visitor) {
         throw new CayenneRuntimeException("Unsupported operation");
     }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void setName(String name) {
-        // noop
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void setRoot(Object root) {
-        // noop
-    }
-
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ObjectIdQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ObjectIdQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ObjectIdQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ObjectIdQuery.java Wed Jul 19 21:04:04 2006
@@ -125,13 +125,6 @@
         return query;
     }
 
-    /**
-     * @deprecated since 1.2
-     */
-    public Object getRoot() {
-        return objectId.getEntityName();
-    }
-
     public int getCachePolicy() {
         return cachePolicy;
     }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/PrefetchSelectQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/PrefetchSelectQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/PrefetchSelectQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/PrefetchSelectQuery.java Wed Jul 19 21:04:04 2006
@@ -22,13 +22,8 @@
 import java.util.Collection;
 import java.util.Collections;
 import java.util.HashSet;
-import java.util.Iterator;
 
-import org.apache.cayenne.CayenneRuntimeException;
-import org.apache.cayenne.exp.Expression;
-import org.apache.cayenne.map.EntityInheritanceTree;
 import org.apache.cayenne.map.EntityResolver;
-import org.apache.cayenne.map.ObjEntity;
 import org.apache.cayenne.map.ObjRelationship;
 import org.apache.cayenne.util.Util;
 
@@ -36,7 +31,7 @@
  * A SelectQuery to perform a prefetch based on another query. Used internally by Cayenne
  * and is normally never used directly.
  * 
- * @author Craig Miskell, Andrei Adamchik
+ * @author Craig Miskell, Andrus Adamchik
  */
 public class PrefetchSelectQuery extends SelectQuery {
 
@@ -55,60 +50,6 @@
     // TODO, Andrus 11/17/2005 - i guess we should deprecate
     // SelectQuery.customDbAttribute, replacing it with "resultPaths" mechanism.
     protected Collection resultPaths;
-
-    /**
-     * Creates a prefetch query based on parent query.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2 - passing EntityResolver in constructor is no longer needed,
-     *             as prefetch query configuration alogrithm is moved out of this class.
-     *             In fact this constructor will not correctly configure query to handle
-     *             flattened prefetches.
-     */
-    public PrefetchSelectQuery(EntityResolver resolver, SelectQuery parentQuery,
-            String prefetch) {
-
-        setParentQuery(parentQuery);
-        setPrefetchPath(prefetch);
-
-        ObjEntity entity = parentQuery.getMetaData(resolver).getObjEntity();
-        EntityInheritanceTree inheritanceTree = resolver.lookupInheritanceTree(entity);
-
-        Iterator it = entity.resolvePathComponents(prefetch);
-
-        // find root entity
-
-        ObjRelationship r = null;
-        while (it.hasNext()) {
-            r = (ObjRelationship) it.next();
-        }
-
-        if (r == null) {
-            throw new CayenneRuntimeException("Invalid prefetch '"
-                    + prefetch
-                    + "' for entity: "
-                    + entity.getName());
-        }
-
-        setRoot(r.getTargetEntity());
-
-        // chain query and entity qualifiers
-        Expression queryQualifier = parentQuery.getQualifier();
-
-        Expression entityQualifier = (inheritanceTree != null) ? inheritanceTree
-                .qualifierForEntityAndSubclasses() : entity.getDeclaredQualifier();
-
-        if (entityQualifier != null) {
-            queryQualifier = (queryQualifier != null) ? queryQualifier
-                    .andExp(entityQualifier) : entityQualifier;
-        }
-
-        setQualifier(entity.translateToRelatedEntity(queryQualifier, prefetchPath));
-
-        if (r.isToMany() && !r.isFlattened()) {
-            setLastPrefetchHint(r);
-        }
-    }
 
     /**
      * Creates a new disjoint prefetch select query.

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ProcedureQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ProcedureQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ProcedureQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/ProcedureQuery.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.query;
 
 import java.util.ArrayList;
@@ -48,26 +47,18 @@
  * <h4>Using ProcedureQuery as a GenericSelectQuery</h4>
  * <p>
  * Executing ProcedureQuery via
- * {@link org.apache.cayenne.access.DataContext#performQuery(Query)} makes sense only
- * if the stored procedure returns a single result set (or alternatively returns a result
- * via OUT parameters and no other result sets). It is still OK if data modification
- * occurs as a side effect. However if the query returns more then one result set, a more
- * generic form should be used:
+ * {@link org.apache.cayenne.access.DataContext#performQuery(Query)} makes sense only if
+ * the stored procedure returns a single result set (or alternatively returns a result via
+ * OUT parameters and no other result sets). It is still OK if data modification occurs as
+ * a side effect. However if the query returns more then one result set, a more generic
+ * form should be used:
  * {@link org.apache.cayenne.access.DataContext#performGenericQuery(Query)}.
  * </p>
  * 
  * @author Andrus Adamchik
  */
-public class ProcedureQuery extends AbstractQuery implements GenericSelectQuery,
-        ParameterizedQuery, XMLSerializable {
-
-    /**
-     * If set, allows to fetch results as DataObjects.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2 'resultEntityName' must be used.
-     */
-    protected String resultClassName;
+public class ProcedureQuery extends AbstractQuery implements ParameterizedQuery,
+        XMLSerializable {
 
     /**
      * @since 1.2
@@ -81,11 +72,6 @@
 
     protected Map parameters = new HashMap();
 
-    /**
-     * @deprecated since 1.2 as this information is no longer relavant to Cayenne
-     */
-    protected boolean selecting;
-
     ProcedureQueryMetadata metaData = new ProcedureQueryMetadata();
 
     // TODO: ColumnDescriptor is not XMLSerializable so we can't store
@@ -139,9 +125,6 @@
         setRoot(procedure);
 
         this.resultClass = resultType;
-
-        // call this for backwards compatibility
-        setResultClassName(resultType != null ? resultType.getName() : null);
     }
 
     /**
@@ -159,8 +142,6 @@
         setRoot(procedureName);
 
         this.resultClass = resultType;
-
-        setResultClassName(resultType != null ? resultType.getName() : null);
     }
 
     /**
@@ -295,7 +276,6 @@
             query.setRoot(root);
         }
 
-        query.setResultClassName(resultClassName);
         query.setResultEntityName(resultEntityName);
         query.metaData.copyFromInfo(this.metaData);
         query.setParameters(parameters);
@@ -399,57 +379,6 @@
      */
     public synchronized void clearParameters() {
         this.parameters.clear();
-    }
-
-    /**
-     * Returns an optional result type of the query.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2 use {@link #getResultEntityName()}
-     */
-    public String getResultClassName() {
-        return resultClassName;
-    }
-
-    /**
-     * Returns Java class of the DataObjects returned by this query.
-     * 
-     * @deprecated since 1.2
-     * @since 1.1
-     */
-    public Class getResultClass(ClassLoader classLoader) {
-        return resultClass;
-    }
-
-    /**
-     * Sets optional result type of the query. A Class of the result type must be a
-     * DataObject implementation mapped in Cayenne.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2 use {@link #setResultEntityName(String)}
-     */
-    public void setResultClassName(String resultClassName) {
-        this.resultClassName = resultClassName;
-    }
-
-    /**
-     * Returns true if ProcedureQuery is expected to return a ResultSet.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2 as this information is no longer relavant to Cayenne
-     */
-    public boolean isSelecting() {
-        return selecting;
-    }
-
-    /**
-     * Sets whether ProcedureQuery is expected to return a ResultSet.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2 as this information is no longer relavant to Cayenne
-     */
-    public void setSelecting(boolean b) {
-        selecting = b;
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/Query.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/Query.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/Query.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/Query.java Wed Jul 19 21:04:04 2006
@@ -71,28 +71,4 @@
      * @since 1.1
      */
     String getName();
-
-    /**
-     * Sets a symbolic name of the query.
-     * 
-     * @since 1.1
-     * @deprecated since 1.2
-     */
-    void setName(String name);
-
-    /**
-     * Returns the root object of the query.
-     * 
-     * @deprecated since 1.2. Query "root" is now accessed via
-     *             {@link #getMetaData(EntityResolver)}.
-     */
-    Object getRoot();
-
-    /**
-     * Sets the root of the query.
-     * 
-     * @deprecated since 1.2. Query "root" is now accessed via
-     *             {@link #getMetaData(EntityResolver)}.
-     */
-    void setRoot(Object root);
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/QueryChain.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/QueryChain.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/QueryChain.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/QueryChain.java Wed Jul 19 21:04:04 2006
@@ -122,22 +122,9 @@
      * Returns default metadata.
      */
     public QueryMetadata getMetaData(EntityResolver resolver) {
-        QueryMetadataWrapper wrapper = new QueryMetadataWrapper(DefaultQueryMetadata.defaultMetadata);
+        QueryMetadataWrapper wrapper = new QueryMetadataWrapper(
+                DefaultQueryMetadata.defaultMetadata);
         wrapper.override(QueryMetadata.FETCHING_DATA_ROWS_PROPERTY, Boolean.TRUE);
         return wrapper;
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public Object getRoot() {
-        throw new CayenneRuntimeException("This deprecated method is not implemented");
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void setRoot(Object root) {
-        throw new CayenneRuntimeException("This deprecated method is not implemented");
     }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SQLTemplate.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SQLTemplate.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SQLTemplate.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SQLTemplate.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.query;
 
 import java.util.Collection;
@@ -26,8 +25,6 @@
 import java.util.Iterator;
 import java.util.Map;
 
-import org.apache.commons.collections.IteratorUtils;
-import org.apache.commons.collections.Transformer;
 import org.apache.cayenne.map.DataMap;
 import org.apache.cayenne.map.DbEntity;
 import org.apache.cayenne.map.EntityResolver;
@@ -37,6 +34,8 @@
 import org.apache.cayenne.util.Util;
 import org.apache.cayenne.util.XMLEncoder;
 import org.apache.cayenne.util.XMLSerializable;
+import org.apache.commons.collections.IteratorUtils;
+import org.apache.commons.collections.Transformer;
 
 /**
  * A query that executes unchanged (except for template preprocessing) "raw" SQL specified
@@ -49,7 +48,7 @@
  * </p>
  * 
  * <pre>
- *               SELECT ID, NAME FROM SOME_TABLE WHERE NAME LIKE $a
+ *                   SELECT ID, NAME FROM SOME_TABLE WHERE NAME LIKE $a
  * </pre>
  * 
  * <p>
@@ -73,8 +72,8 @@
  * @since 1.1
  * @author Andrus Adamchik
  */
-public class SQLTemplate extends AbstractQuery implements GenericSelectQuery,
-        ParameterizedQuery, XMLSerializable {
+public class SQLTemplate extends AbstractQuery implements ParameterizedQuery,
+        XMLSerializable {
 
     private static final Transformer nullMapTransformer = new Transformer() {
 
@@ -90,11 +89,6 @@
     BaseQueryMetadata selectInfo = new BaseQueryMetadata();
 
     /**
-     * @deprecated Since 1.2 this property is redundant.
-     */
-    protected boolean selecting;
-
-    /**
      * Creates an empty SQLTemplate. Note this constructor does not specify the "root" of
      * the query, so a user must call "setRoot" later to make sure SQLTemplate can be
      * executed.
@@ -145,58 +139,6 @@
     }
 
     /**
-     * Creates an empty SQLTemplate. Note this constructor does not specify the "root" of
-     * the query, so a user must call "setRoot" later to make sure SQLTemplate can be
-     * executed.
-     * 
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public SQLTemplate(boolean selecting) {
-        this();
-        setSelecting(selecting);
-    }
-
-    /**
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public SQLTemplate(DataMap rootMap, String defaultTemplate, boolean selecting) {
-        this(rootMap, defaultTemplate);
-        setSelecting(selecting);
-    }
-
-    /**
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public SQLTemplate(ObjEntity rootEntity, String defaultTemplate, boolean selecting) {
-        this(rootEntity, defaultTemplate);
-        setSelecting(selecting);
-    }
-
-    /**
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public SQLTemplate(Class rootClass, String defaultTemplate, boolean selecting) {
-        this(rootClass, defaultTemplate);
-        setSelecting(selecting);
-    }
-
-    /**
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public SQLTemplate(DbEntity rootEntity, String defaultTemplate, boolean selecting) {
-        this(rootEntity, defaultTemplate);
-        setSelecting(selecting);
-    }
-
-    /**
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public SQLTemplate(String objEntityName, String defaultTemplate, boolean selecting) {
-        this(objEntityName, defaultTemplate);
-        setSelecting(selecting);
-    }
-
-    /**
      * @since 1.2
      */
     public QueryMetadata getMetaData(EntityResolver resolver) {
@@ -532,24 +474,6 @@
                         : new HashMap();
             }
         }
-    }
-
-    /**
-     * Returns true if SQLTemplate is expected to return a ResultSet.
-     * 
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public boolean isSelecting() {
-        return selecting;
-    }
-
-    /**
-     * Sets whether SQLTemplate is expected to return a ResultSet.
-     * 
-     * @deprecated Since 1.2 'selecting' property is redundant.
-     */
-    public void setSelecting(boolean b) {
-        selecting = b;
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SelectQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SelectQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SelectQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/query/SelectQuery.java Wed Jul 19 21:04:04 2006
@@ -44,8 +44,8 @@
  * 
  * @author Andrei Adamchik
  */
-public class SelectQuery extends QualifiedQuery implements GenericSelectQuery,
-        ParameterizedQuery, XMLSerializable {
+public class SelectQuery extends QualifiedQuery implements ParameterizedQuery,
+        XMLSerializable {
 
     public static final String DISTINCT_PROPERTY = "cayenne.SelectQuery.distinct";
     public static final boolean DISTINCT_DEFAULT = false;
@@ -297,8 +297,8 @@
      * Returns a query built using this query as a prototype, using a set of parameters to
      * build the qualifier.
      * 
-     * @see org.apache.cayenne.exp.Expression#expWithParameters(java.util.Map,
-     *      boolean) parameter substitution.
+     * @see org.apache.cayenne.exp.Expression#expWithParameters(java.util.Map, boolean)
+     *      parameter substitution.
      */
     public SelectQuery queryWithParameters(Map parameters, boolean pruneMissing) {
         // create a query replica
@@ -468,28 +468,6 @@
     }
 
     /**
-     * Returns a collection of String paths indicating relationships to objects that are
-     * prefetched together with this query.
-     * 
-     * @deprecated since 1.2 use 'getPrefetchTree' to explore prefetches.
-     */
-    public Collection getPrefetches() {
-        if (getPrefetchTree() != null) {
-
-            Collection nodes = getPrefetchTree().nonPhantomNodes();
-            Collection paths = new ArrayList(nodes.size());
-            Iterator it = nodes.iterator();
-            while (it.hasNext()) {
-                paths.add(((PrefetchTreeNode) it.next()).getPath());
-            }
-
-            return paths;
-        }
-
-        return Collections.EMPTY_LIST;
-    }
-
-    /**
      * @since 1.2
      */
     public PrefetchTreeNode getPrefetchTree() {
@@ -510,15 +488,6 @@
      */
     public PrefetchTreeNode addPrefetch(String prefetchPath) {
         return selectInfo.addPrefetch(prefetchPath, PrefetchTreeNode.UNDEFINED_SEMANTICS);
-    }
-
-    /**
-     * Adds all prefetches to the internal prefetch set.
-     * 
-     * @deprecated since 1.2
-     */
-    public void addPrefetches(Collection prefetches) {
-        selectInfo.addPrefetches(prefetches, PrefetchTreeNode.UNDEFINED_SEMANTICS);
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/IncrementalQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/IncrementalQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/IncrementalQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/IncrementalQuery.java Wed Jul 19 21:04:04 2006
@@ -124,25 +124,4 @@
     public String getName() {
         return query.getName();
     }
-
-    /**
-     * @deprecated since 1.2 as super is deprecated.
-     */
-    public void setName(String name) {
-        this.query.setName(name);
-    }
-
-    /**
-     * @deprecated since 1.2 as super is deprecated.
-     */
-    public Object getRoot() {
-        return query.getRoot();
-    }
-
-    /**
-     * @deprecated since 1.2 as super is deprecated.
-     */
-    public void setRoot(Object root) {
-        query.setRoot(root);
-    }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/RangeQuery.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/RangeQuery.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/RangeQuery.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/remote/RangeQuery.java Wed Jul 19 21:04:04 2006
@@ -45,10 +45,10 @@
     private int fetchLimit;
     private boolean fetchingDataRows;
     private PrefetchTreeNode prefetchTree;
-    
+
     // exists for hessian serialization.
     private RangeQuery() {
-        
+
     }
 
     /**
@@ -130,27 +130,6 @@
     }
 
     public void route(QueryRouter router, EntityResolver resolver, Query substitutedQuery) {
-        throw new UnsupportedOperationException();
-    }
-
-    /**
-     * @deprecated as the corresponding interface method is deprecated.
-     */
-    public Object getRoot() {
-        throw new UnsupportedOperationException();
-    }
-
-    /**
-     * @deprecated as the corresponding interface method is deprecated.
-     */
-    public void setName(String name) {
-        throw new UnsupportedOperationException();
-    }
-
-    /**
-     * @deprecated as the corresponding interface method is deprecated.
-     */
-    public void setRoot(Object root) {
         throw new UnsupportedOperationException();
     }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/NameConverter.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/NameConverter.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/NameConverter.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/NameConverter.java Wed Jul 19 21:04:04 2006
@@ -21,17 +21,17 @@
 
 import java.util.StringTokenizer;
 
-/** 
- * Utility class to convert from different naming styles to Java convention.
- * For example names like "ABCD_EFG" can be converted to "abcdEfg".
+/**
+ * Utility class to convert from different naming styles to Java convention. For example
+ * names like "ABCD_EFG" can be converted to "abcdEfg".
  * 
  * @author Andrei Adamchik
  */
 public class NameConverter {
 
     /**
-     * Converts a String name to a String forllowing java convention for the 
-     * static final variables. E.g. "abcXyz" will be converted to "ABC_XYZ".
+     * Converts a String name to a String forllowing java convention for the static final
+     * variables. E.g. "abcXyz" will be converted to "ABC_XYZ".
      * 
      * @since 1.0.3
      */
@@ -45,7 +45,7 @@
 
         for (int i = 0; i < charArray.length; i++) {
             if ((Character.isUpperCase(charArray[i])) && (i != 0)) {
-                
+
                 char prevChar = charArray[i - 1];
                 if ((Character.isLowerCase(prevChar))) {
                     buffer.append("_");
@@ -59,19 +59,11 @@
     }
 
     /**
-     * @deprecated since 1.2 replaced with {@link #underscoredToJava(String, boolean)},
-     *             fixing the naming typo.
-     */
-    public static String undescoredToJava(String name, boolean capitalize) {
-        return underscoredToJava(name, capitalize);
-    }
-    
-    /** 
-     * Converts names like "ABCD_EFG_123" to Java-style names like "abcdEfg123".
-     * If <code>capitalize</code> is true, returned name is capitalized
-     * (for instance if this is a class name).
+     * Converts names like "ABCD_EFG_123" to Java-style names like "abcdEfg123". If
+     * <code>capitalize</code> is true, returned name is capitalized (for instance if
+     * this is a class name).
      * 
-     *  @since 1.2
+     * @since 1.2
      */
     public static String underscoredToJava(String name, boolean capitalize) {
         StringTokenizer st = new StringTokenizer(name, "_");
@@ -92,7 +84,8 @@
             for (int i = 0; i < len && !(hasUpperCase && hasLowerCase); i++) {
                 if (Character.isUpperCase(token.charAt(i))) {
                     hasUpperCase = true;
-                } else if (Character.isLowerCase(token.charAt(i))) {
+                }
+                else if (Character.isLowerCase(token.charAt(i))) {
                     hasLowerCase = true;
                 }
             }
@@ -107,10 +100,12 @@
                 first = false;
                 if (capitalize) {
                     buf.append(Character.toUpperCase(token.charAt(0)));
-                } else {
+                }
+                else {
                     buf.append(Character.toLowerCase(token.charAt(0)));
                 }
-            } else {
+            }
+            else {
                 buf.append(Character.toUpperCase(token.charAt(0)));
             }
 

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/Util.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/Util.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/Util.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/cayenne/java/org/apache/cayenne/util/Util.java Wed Jul 19 21:04:04 2006
@@ -316,7 +316,7 @@
 
         // no need to close the stream - we created it and now will be throwing away...
         // in.close();
-        
+
         return objCopy;
     }
 
@@ -517,19 +517,6 @@
         for (Iterator i = c.iterator(); i.hasNext();)
             builder.append(i.next());
         return builder.toHashCode();
-    }
-
-    /**
-     * Converts a SQL-style pattern to a valid Perl regular expression. E.g.:
-     * <p>
-     * <code>"billing_%"</code> will become <code>/^billing_.*$/</code>
-     * <p>
-     * <code>"user?"</code> will become <code>/^user.?$/</code>
-     * 
-     * @deprecated since 1.2 use "sqlPatternToPattern".
-     */
-    public static String sqlPatternToRegex(String pattern, boolean ignoreCase) {
-        return RegexUtil.sqlPatternToRegex(pattern);
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/modeler/pref/PreferencesDataSourceFactory.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/modeler/pref/PreferencesDataSourceFactory.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/modeler/pref/PreferencesDataSourceFactory.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/modeler/pref/PreferencesDataSourceFactory.java Wed Jul 19 21:04:04 2006
@@ -30,7 +30,6 @@
 
 import javax.sql.DataSource;
 
-import org.apache.log4j.Level;
 import org.apache.cayenne.CayenneRuntimeException;
 import org.apache.cayenne.DataObjectUtils;
 import org.apache.cayenne.access.DataContext;
@@ -78,13 +77,6 @@
 
     public void initializeWithParentConfiguration(Configuration configuaration) {
         // noop
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public DataSource getDataSource(String location, Level logLevel) throws Exception {
-        return getDataSource(location);
     }
 
     /**

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/pref/HSQLEmbeddedPreferenceService.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/pref/HSQLEmbeddedPreferenceService.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/pref/HSQLEmbeddedPreferenceService.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/modeler/java/org/apache/cayenne/pref/HSQLEmbeddedPreferenceService.java Wed Jul 19 21:04:04 2006
@@ -25,7 +25,6 @@
 
 import javax.sql.DataSource;
 
-import org.apache.log4j.Level;
 import org.apache.cayenne.CayenneRuntimeException;
 import org.apache.cayenne.access.ConnectionLogger;
 import org.apache.cayenne.access.QueryLogger;
@@ -41,7 +40,7 @@
  * An implementation of preference service that stores the data using embedded HSQL DB
  * database with Cayenne.
  * 
- * @author Andrei Adamchik
+ * @author Andrus Adamchik
  */
 public class HSQLEmbeddedPreferenceService extends CayennePreferenceService {
 
@@ -371,13 +370,6 @@
             }
 
             return false;
-        }
-
-        /**
-         * @deprecated since 1.2
-         */
-        public DataSource getDataSource(String location, Level logLevel) throws Exception {
-            return getDataSource(location);
         }
 
         public DataSource getDataSource(String location) throws Exception {

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/CayenneDataObjectInCtxtTst.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/CayenneDataObjectInCtxtTst.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/CayenneDataObjectInCtxtTst.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/CayenneDataObjectInCtxtTst.java Wed Jul 19 21:04:04 2006
@@ -86,42 +86,6 @@
         assertEquals("Painting", e1.getName());
     }
 
-    /**
-     * @deprecated since 1.2
-     */
-    public void testResolveFault() {
-        DataContext context = createDataContext();
-
-        Artist o1 = newSavedArtist(context);
-        context.invalidateObjects(Collections.singleton(o1));
-        assertEquals(PersistenceState.HOLLOW, o1.getPersistenceState());
-        assertNull(o1.readPropertyDirectly("artistName"));
-
-        o1.resolveFault();
-        assertEquals(PersistenceState.COMMITTED, o1.getPersistenceState());
-        assertEquals("a", o1.readPropertyDirectly("artistName"));
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void testResolveFaultFailure() {
-        DataContext context = createDataContext();
-
-        DataObject o1 = context.registeredObject(new ObjectId(
-                "Artist",
-                Artist.ARTIST_ID_PK_COLUMN,
-                new Integer(234)));
-
-        try {
-            o1.resolveFault();
-            fail("Must blow on non-existing fault.");
-        }
-        catch (CayenneRuntimeException ex) {
-
-        }
-    }
-
     public void testCommitChangesInBatch() {
         DataContext context = createDataContext();
 

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/ObjectIdTst.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/ObjectIdTst.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/ObjectIdTst.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/ObjectIdTst.java Wed Jul 19 21:04:04 2006
@@ -48,14 +48,6 @@
         assertSame(key, temp2.getKey());
     }
 
-    /**
-     * @deprecated since 1.2
-     */
-    public void testClassConstructor() {
-        ObjectId temp1 = new ObjectId(Number.class);
-        assertEquals("Number", temp1.getEntityName());
-    }
-
     public void testSerializabilityTemp() throws Exception {
         ObjectId temp1 = new ObjectId("e");
         ObjectId temp2 = (ObjectId) Util.cloneViaSerialization(temp1);
@@ -294,7 +286,7 @@
         ObjectId oid2 = new ObjectId("T", hm2);
         assertFalse(oid1.equals(oid2));
     }
-    
+
     /**
      * Test different numeric types.
      */

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextDelegateTst.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextDelegateTst.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextDelegateTst.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextDelegateTst.java Wed Jul 19 21:04:04 2006
@@ -149,65 +149,4 @@
         // blocked
         assertEquals("Delegate couldn't block the query.", 0, results.size());
     }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void testWillPerformSelect() throws Exception {
-        DataContext context = gallery.getDataContext();
-
-        final List queriesPerformed = new ArrayList(1);
-        DataContextDelegate delegate = new MockDataContextDelegate() {
-
-            public org.apache.cayenne.query.GenericSelectQuery willPerformSelect(
-                    DataContext context,
-                    org.apache.cayenne.query.GenericSelectQuery query) {
-                // save query, and allow its execution
-                queriesPerformed.add(query);
-                return query;
-            }
-        };
-        context.setDelegate(delegate);
-
-        // test that delegate is consulted before select
-        SelectQuery query = new SelectQuery(Gallery.class);
-        List results = context.performQuery(query);
-
-        assertTrue("Delegate is not notified of a query being run.", queriesPerformed
-                .contains(query));
-        assertEquals(1, queriesPerformed.size());
-        assertNotNull(results);
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public void testWillPerformSelectQueryBlocked() throws Exception {
-        DataContext context = gallery.getDataContext();
-
-        final List queriesPerformed = new ArrayList(1);
-        DataContextDelegate delegate = new MockDataContextDelegate() {
-
-            public org.apache.cayenne.query.GenericSelectQuery willPerformSelect(
-                    DataContext context,
-                    org.apache.cayenne.query.GenericSelectQuery query) {
-                // save query, and block its execution
-                queriesPerformed.add(query);
-                return null;
-            }
-        };
-
-        context.setDelegate(delegate);
-        SelectQuery query = new SelectQuery(Gallery.class);
-        List results = context.performQuery(query);
-
-        assertTrue("Delegate is not notified of a query being run.", queriesPerformed
-                .contains(query));
-        assertEquals(1, queriesPerformed.size());
-
-        assertNotNull(results);
-
-        // blocked
-        assertEquals("Delegate couldn't block the query.", 0, results.size());
-    }
 }

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextObjectTrackingTst.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextObjectTrackingTst.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextObjectTrackingTst.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextObjectTrackingTst.java Wed Jul 19 21:04:04 2006
@@ -19,14 +19,10 @@
 
 package org.apache.cayenne.access;
 
-import java.util.Arrays;
 import java.util.Collections;
 import java.util.Date;
-import java.util.Iterator;
-import java.util.List;
 
 import org.apache.art.Artist;
-import org.apache.art.Painting;
 import org.apache.cayenne.DataObject;
 import org.apache.cayenne.DataObjectUtils;
 import org.apache.cayenne.DataRow;
@@ -228,98 +224,6 @@
             assertEquals(PersistenceState.MODIFIED, peerModified2.getPersistenceState());
             assertEquals("M2", peerModified.getArtistName());
             assertEquals("M1", modified.getArtistName());
-        }
-        finally {
-            unblockQueries();
-        }
-    }
-
-    /**
-     * @deprecated since 1.2 as localObjects is deprecated.
-     */
-    public void testLocalObjectsPeerContextDifferentEntities() throws Exception {
-        deleteTestData();
-        createTestData("testMix");
-
-        // must create both contexts before running the queries, as each call to
-        // 'createDataContext' clears the cache.
-        DataContext context = createDataContext();
-        DataContext peerContext = createDataContext();
-
-        Artist artist = (Artist) DataObjectUtils.objectForQuery(
-                context,
-                new ObjectIdQuery(new ObjectId(
-                        "Artist",
-                        Artist.ARTIST_ID_PK_COLUMN,
-                        33003)));
-        Painting painting = (Painting) DataObjectUtils.objectForQuery(
-                context,
-                new ObjectIdQuery(new ObjectId(
-                        "Painting",
-                        Painting.PAINTING_ID_PK_COLUMN,
-                        33003)));
-
-        List objects = Arrays.asList(new Object[] {
-                artist, painting
-        });
-
-        blockQueries();
-
-        try {
-
-            List locals = peerContext.localObjects(objects);
-            assertEquals(2, locals.size());
-
-            assertTrue(locals.get(0) instanceof Artist);
-            assertTrue(locals.get(1) instanceof Painting);
-        }
-        finally {
-            unblockQueries();
-        }
-    }
-
-    /**
-     * @deprecated since 1.2 as localObjects is deprecated.
-     */
-    public void testLocalObjectsPeerContextDifferentContexts() throws Exception {
-        deleteTestData();
-        createTestData("testMix");
-
-        // must create both contexts before running the queries, as each call to
-        // 'createDataContext' clears the cache.
-        DataContext context1 = createDataContext();
-        DataContext context2 = createDataContext();
-        DataContext peerContext = createDataContext();
-
-        Artist artist = (Artist) DataObjectUtils.objectForQuery(
-                context1,
-                new ObjectIdQuery(new ObjectId(
-                        "Artist",
-                        Artist.ARTIST_ID_PK_COLUMN,
-                        33003)));
-        Painting painting = (Painting) DataObjectUtils.objectForQuery(
-                context2,
-                new ObjectIdQuery(new ObjectId(
-                        "Painting",
-                        Painting.PAINTING_ID_PK_COLUMN,
-                        33003)));
-
-        List objects = Arrays.asList(new Object[] {
-                artist, painting
-        });
-
-        blockQueries();
-
-        try {
-
-            List locals = peerContext.localObjects(objects);
-            assertEquals(2, locals.size());
-
-            Iterator it = locals.iterator();
-            while (it.hasNext()) {
-                DataObject o = (DataObject) it.next();
-                assertSame(peerContext, o.getDataContext());
-            }
         }
         finally {
             unblockQueries();

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextTst.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextTst.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextTst.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/DataContextTst.java Wed Jul 19 21:04:04 2006
@@ -17,7 +17,6 @@
  *  under the License.
  ****************************************************************/
 
-
 package org.apache.cayenne.access;
 
 import java.math.BigDecimal;
@@ -29,7 +28,6 @@
 import org.apache.art.Artist;
 import org.apache.art.ArtistAssets;
 import org.apache.art.Exhibit;
-import org.apache.art.Gallery;
 import org.apache.art.Painting;
 import org.apache.art.ROArtist;
 import org.apache.cayenne.DataRow;
@@ -39,10 +37,10 @@
 import org.apache.cayenne.conn.PoolManager;
 import org.apache.cayenne.exp.Expression;
 import org.apache.cayenne.exp.ExpressionFactory;
+import org.apache.cayenne.query.ObjectIdQuery;
 import org.apache.cayenne.query.Ordering;
 import org.apache.cayenne.query.SQLTemplate;
 import org.apache.cayenne.query.SelectQuery;
-import org.apache.cayenne.query.ObjectIdQuery;
 
 public class DataContextTst extends DataContextTestBase {
 
@@ -215,32 +213,6 @@
         assertEquals(1, a1.getPaintingsCount().intValue());
     }
 
-    /**
-     * @deprecated since 1.2 as 'performQueries' is deprecated.
-     */
-    public void testPerformQueries() throws Exception {
-        createTestData("testGalleries");
-
-        SelectQuery q1 = new SelectQuery();
-        q1.setRoot(Artist.class);
-        SelectQuery q2 = new SelectQuery();
-        q2.setRoot(Gallery.class);
-
-        List qs = new ArrayList();
-        qs.add(q1);
-        qs.add(q2);
-        context.performQueries(qs, opObserver);
-
-        // check query results
-        List o1 = opObserver.rowsForQuery(q1);
-        assertNotNull(o1);
-        assertEquals(artistCount, o1.size());
-
-        List o2 = opObserver.rowsForQuery(q2);
-        assertNotNull(o2);
-        assertEquals(galleryCount, o2.size());
-    }
-
     public void testSelectDate() throws Exception {
         createTestData("testGalleries");
         populateExhibits();
@@ -390,7 +362,7 @@
         assertTrue(((IncrementalFaultList) objects).elements.get(0) instanceof Artist);
         assertTrue(((IncrementalFaultList) objects).elements.get(7) instanceof Map);
     }
-    
+
     public void testPerformPaginatedQueryBigPage() throws Exception {
         SelectQuery query = new SelectQuery("Artist");
         query.setPageSize(DataContextTst.artistCount + 2);

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockDataContextDelegate.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockDataContextDelegate.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockDataContextDelegate.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockDataContextDelegate.java Wed Jul 19 21:04:04 2006
@@ -27,18 +27,9 @@
  * Default implementation of DataContextDelegate that serves as a superclass for mockup
  * test delegates.
  * 
- * @author Andrei Adamchik
+ * @author Andrus Adamchik
  */
 public class MockDataContextDelegate implements DataContextDelegate {
-
-    /**
-     * @deprecated since 1.2
-     */
-    public org.apache.cayenne.query.GenericSelectQuery willPerformSelect(
-            DataContext context,
-            org.apache.cayenne.query.GenericSelectQuery query) {
-        return query;
-    }
 
     public Query willPerformGenericQuery(DataContext context, Query query) {
         return query;

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockOperationObserver.java
URL: http://svn.apache.org/viewvc/incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockOperationObserver.java?rev=423749&r1=423748&r2=423749&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockOperationObserver.java (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-java/src/tests/java/org/apache/cayenne/access/MockOperationObserver.java Wed Jul 19 21:04:04 2006
@@ -23,7 +23,6 @@
 import java.util.List;
 import java.util.Map;
 
-import org.apache.log4j.Level;
 import org.apache.cayenne.CayenneRuntimeException;
 import org.apache.cayenne.query.Query;
 
@@ -73,13 +72,6 @@
     }
 
     public void nextGeneratedDataRows(Query query, ResultIterator keysIterator) {
-    }
-
-    /**
-     * @deprecated since 1.2
-     */
-    public Level getLoggingLevel() {
-        return null;
     }
 
     public boolean isIteratedResult() {



Mime
View raw message