openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Donald Woods <dwo...@apache.org>
Subject Re: svn commit: r792583 - in spec-src/
Date Fri, 10 Jul 2009 12:32:33 GMT
Pinaki, please remove the trunk/spec-src directory, as the checked in 
jar file includes source files that include Javadoc covered by the 
JCP/CDDL license and cannot be in the ASF repo.


-Donald


ppoddar@apache.org wrote:
> Author: ppoddar
> Date: Thu Jul  9 15:29:27 2009
> New Revision: 792583
> 
> URL: http://svn.apache.org/viewvc?rev=792583&view=rev
> Log:
> OPENJPA-1143: Re-realign implementation with JAP EA4. Repurpose SelectionImpl, rename
ResultItemImpl to TupleElementImpl (to match JPA naming)
> 
> Added:
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/TupleElementImpl.java
>       - copied, changed from r792559, openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/ResultItemImpl.java
>     openjpa/trunk/spec-src/
>     openjpa/trunk/spec-src/APIsJune15.jar   (with props)
> Removed:
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/ResultItemImpl.java
> Modified:
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/CriteriaExpressionBuilder.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ExpressionImpl.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Expressions.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Joins.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/NewInstanceSelection.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ParameterImpl.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PathImpl.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PredicateImpl.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SelectionImpl.java
>     openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SubqueryImpl.java
> 
> Copied: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/TupleElementImpl.java
(from r792559, openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/ResultItemImpl.java)
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/TupleElementImpl.java?p2=openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/TupleElementImpl.java&p1=openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/ResultItemImpl.java&r1=792559&r2=792583&rev=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/ResultItemImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/TupleElementImpl.java
Thu Jul  9 15:29:27 2009
> @@ -27,19 +27,19 @@
>   *
>   * @param <X> type of the result
>   */
> -public class ResultItemImpl<X> implements TupleElement<X> {
> -    protected String _alias;
> +public class TupleElementImpl<X> implements TupleElement<X> {
> +    private String _alias;
>      protected final Class<X> _cls;
>  
> -    protected ResultItemImpl(Class<X> cls) {
> +    protected TupleElementImpl(Class<X> cls) {
>          _cls = cls;
>      }
>      
> -    public String getAlias() {
> +    public final String getAlias() {
>          return _alias;
>      }
>  
> -    public void setAlias(String alias) {
> +    protected void setAlias(String alias) {
>          _alias = alias;
>      }
>  
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/CriteriaExpressionBuilder.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/CriteriaExpressionBuilder.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/CriteriaExpressionBuilder.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/CriteriaExpressionBuilder.java
Thu Jul  9 15:29:27 2009
> @@ -213,7 +213,7 @@
>          for (Selection<?> s : selections) {
>              if (s instanceof NewInstanceSelection<?>) {
>                  exps.resultClass = s.getJavaType();
> -                getProjections(exps, ((NewInstanceSelection)s).getConstructorArguments(),
projections, aliases, 
> +                getProjections(exps, ((NewInstanceSelection<?>)s).getSelectionItems(),
projections, aliases, 
>                          factory, q, model);               
>              } else {
>                  projections.add(((ExpressionImpl<?>)s).toValue(factory, model,
q));
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ExpressionImpl.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ExpressionImpl.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ExpressionImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ExpressionImpl.java
Thu Jul  9 15:29:27 2009
> @@ -27,7 +27,7 @@
>  
>  import org.apache.openjpa.kernel.exps.ExpressionFactory;
>  import org.apache.openjpa.kernel.exps.Value;
> -import org.apache.openjpa.persistence.ResultItemImpl;
> +import org.apache.openjpa.persistence.TupleElementImpl;
>  import org.apache.openjpa.persistence.meta.MetamodelImpl;
>  
>  /**
> @@ -37,7 +37,7 @@
>   *
>   * @param <X> the type of the value this expression represents.
>   */
> -public abstract class ExpressionImpl<X> extends ResultItemImpl<X> 
> +public abstract class ExpressionImpl<X> extends SelectionImpl<X> 
>      implements Expression<X> {
>  
>      abstract Value toValue(ExpressionFactory factory, MetamodelImpl model,
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Expressions.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Expressions.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Expressions.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Expressions.java
Thu Jul  9 15:29:27 2009
> @@ -133,21 +133,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.abs(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<X> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Count extends UnaryFunctionalExpression<Long> {
> @@ -168,21 +153,6 @@
>              Value v = factory.count(Expressions.toValue(e, factory, model, q));
>              return _distinct ? factory.distinct(v) : v;
>          }
> -
> -        public Selection<Long> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Avg extends UnaryFunctionalExpression<Double> {
> @@ -195,21 +165,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.avg(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<Double> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Sqrt extends UnaryFunctionalExpression<Double> {
> @@ -222,21 +177,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.sqrt(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<Double> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Max<X> extends UnaryFunctionalExpression<X> {
> @@ -249,21 +189,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.max(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<X> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Min<X> extends UnaryFunctionalExpression<X> {
> @@ -276,21 +201,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.min(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<X> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Size extends UnaryFunctionalExpression<Integer> {
> @@ -307,21 +217,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.size(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<Integer> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Type<X> 
> @@ -336,21 +231,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.type(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<Class<? extends X>> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Cast<B> extends UnaryFunctionalExpression<B> {
> @@ -364,21 +244,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.cast(Expressions.toValue(e, factory, model, q), b);
>          }
> -
> -        public Selection<B> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Concat extends BinarayFunctionalExpression<String> {
> @@ -401,21 +266,6 @@
>                  Expressions.toValue(e1, factory, model, q), 
>                  Expressions.toValue(e2, factory, model, q));
>          }
> -
> -        public Selection<String> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Substring extends UnaryFunctionalExpression<String> {
> @@ -458,16 +308,6 @@
>              // TODO Auto-generated method stub
>              return null;
>          }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Locate extends ExpressionImpl<Integer> {
> @@ -517,21 +357,6 @@
>                      factory.newLiteral(Numbers.valueOf(1),
>                          Literal.TYPE_NUMBER));
>          }
> -
> -        public Selection<Integer> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Trim extends BinarayFunctionalExpression<String> {
> @@ -580,21 +405,6 @@
>                  Expressions.toValue(e1, factory, model, q), 
>                  Expressions.toValue(e2, factory, model, q), spec);
>          }
> -
> -        public Selection<String> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Sum<N extends Number> 
> @@ -625,21 +435,6 @@
>                     Expressions.toValue(e1, factory, model, q), 
>                     Expressions.toValue(e2, factory, model, q));
>          }
> -
> -        public Selection<N> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Product<N extends Number> 
> @@ -664,21 +459,6 @@
>                  Expressions.toValue(e1, factory, model, q), 
>                  Expressions.toValue(e2, factory, model, q));
>          }
> -
> -        public Selection<N> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Diff<N extends Number> 
> @@ -703,21 +483,6 @@
>                  Expressions.toValue(e1, factory, model, q), 
>                  Expressions.toValue(e2, factory, model, q));
>          }
> -
> -        public Selection<N> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      
> @@ -743,21 +508,6 @@
>                  Expressions.toValue(e1, factory, model, q), 
>                  Expressions.toValue(e2, factory, model, q));
>          }
> -
> -        public Selection<N> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Mod extends BinarayFunctionalExpression<Integer> {
> @@ -778,18 +528,6 @@
>                  Expressions.toValue(e1, factory, model, q), 
>                  Expressions.toValue(e2, factory, model, q));
>          }
> -        public Selection<Integer> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class CurrentDate extends ExpressionImpl<java.sql.Date> {
> @@ -802,21 +540,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.getCurrentDate();
>          }
> -
> -        public Selection<Date> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class CurrentTime extends ExpressionImpl<java.sql.Time> {
> @@ -829,21 +552,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.getCurrentTime();
>          }
> -
> -        public Selection<Time> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class CurrentTimestamp 
> @@ -857,21 +565,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.getCurrentTimestamp();
>          }
> -
> -        public Selection<Timestamp> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Equal extends BinaryLogicalExpression {
> @@ -1039,21 +732,6 @@
>              }
>              return factory.newLiteral(value, literalType);
>          }
> -
> -        public Selection<X> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class TypeConstant<X> extends Constant<X> {
> @@ -1128,21 +806,6 @@
>              v.setMetaData(meta);
>              return factory.index(v);
>          }
> -
> -        public Selection<Integer> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class IsMember<E> extends PredicateImpl {
> @@ -1266,21 +929,6 @@
>                     factory, model, q);
>              return factory.coalesceExpression(vs);
>          }
> -
> -        public Selection<T> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      public static class Nullif<T> extends ExpressionImpl<T> {
> @@ -1309,21 +957,6 @@
>                  factory, model, q); 
>              return factory.nullIfExpression(value1, value2);
>          }
> -
> -        public Selection<T> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class IsNull extends PredicateImpl {
> @@ -1483,16 +1116,6 @@
>              // TODO Auto-generated method stub
>              return null;
>          }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class SimpleCase<C,R> extends ExpressionImpl<R> 
> @@ -1573,16 +1196,6 @@
>              // TODO Auto-generated method stub
>              return null;
>          }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Lower extends UnaryFunctionalExpression<String> {
> @@ -1601,16 +1214,6 @@
>              // TODO Auto-generated method stub
>              return null;
>          }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Upper extends UnaryFunctionalExpression<String> {
> @@ -1629,16 +1232,6 @@
>              // TODO Auto-generated method stub
>              return null;
>          }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>  
>      public static class Length extends UnaryFunctionalExpression<Integer> {
> @@ -1657,16 +1250,6 @@
>              // TODO Auto-generated method stub
>              return null;
>          }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>       
>      public static class Exists<X> extends PredicateImpl {
> @@ -1703,21 +1286,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.all(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<X> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }        
>      }
>  
>      public static class Any<X> extends ExpressionImpl<X> {
> @@ -1732,21 +1300,6 @@
>              CriteriaQueryImpl<?> q) {
>              return factory.any(Expressions.toValue(e, factory, model, q));
>          }
> -
> -        public Selection<X> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }        
>      }
>  
>      public static class Not<X> extends PredicateImpl {
> @@ -1782,21 +1335,6 @@
>              e.setImplicitType(getJavaType());
>              return e;
>          }
> -
> -        public Selection<Y> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public List<Selection<?>> getCompoundSelectionItems() {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }        
>      }
>  
>  }
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Joins.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Joins.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Joins.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/Joins.java
Thu Jul  9 15:29:27 2009
> @@ -364,21 +364,6 @@
>              return (CollectionAttribute<? super Z, E>)
>                 _member.getType();
>          }
> -
> -        public Selection<E> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public java.util.List<Selection<?>> getCompoundSelectionItems()
{
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      /**
> @@ -396,21 +381,6 @@
>          public SetAttribute<? super Z, E> getModel() {
>              return (SetAttribute<? super Z, E>)_member;
>          }
> -
> -        public Selection<E> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public java.util.List<Selection<?>> getCompoundSelectionItems()
{
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      /**
> @@ -435,21 +405,6 @@
>          public Expression<Integer> index() {
>              return new Expressions.Index(this);
>          }
> -
> -        public Selection<E> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public java.util.List<Selection<?>> getCompoundSelectionItems()
{
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>      /**
> @@ -500,21 +455,6 @@
>              c.registerVariable(this, var, path);
>              return join;
>          }
> -
> -        public Selection<V> alias(String arg0) {
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public java.util.List<Selection<?>> getCompoundSelectionItems()
{
> -            // TODO Auto-generated method stub
> -            return null;
> -        }
> -
> -        public boolean isCompoundSelection() {
> -            // TODO Auto-generated method stub
> -            return false;
> -        }
>      }
>      
>         
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/NewInstanceSelection.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/NewInstanceSelection.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/NewInstanceSelection.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/NewInstanceSelection.java
Thu Jul  9 15:29:27 2009
> @@ -24,7 +24,7 @@
>  import javax.persistence.criteria.CompoundSelection;
>  import javax.persistence.criteria.Selection;
>  
> -import org.apache.openjpa.persistence.ResultItemImpl;
> +import org.apache.openjpa.persistence.TupleElementImpl;
>  
>  /**
>   * A selection item that constructs new instance of a user-defined class with arguments
specified as other selected 
> @@ -34,7 +34,7 @@
>   *
>   * @param <X>
>   */
> -public class NewInstanceSelection<X> extends ResultItemImpl<X> 
> +public class NewInstanceSelection<X> extends SelectionImpl<X> 
>      implements CompoundSelection<X> {
>      
>      private List<Selection<?>>  _args;
> @@ -44,27 +44,11 @@
>          _args = Arrays.asList(selections);
>      }
>      
> -    public List<Selection<?>> getConstructorArguments() {
> -        return _args;
> +    public final boolean isCompoundSelection() {
> +        return true;
>      }
> -
> +    
>      public List<Selection<?>> getSelectionItems() {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public Selection<X> alias(String arg0) {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public List<Selection<?>> getCompoundSelectionItems() {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public boolean isCompoundSelection() {
> -        // TODO Auto-generated method stub
> -        return false;
> +        return _args;
>      }
>  }
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ParameterImpl.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ParameterImpl.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ParameterImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/ParameterImpl.java
Thu Jul  9 15:29:27 2009
> @@ -88,19 +88,4 @@
>              throw new IllegalStateException(this + " index is not set");
>          return position-1;
>      }
> -
> -    public Selection<T> alias(String arg0) {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public List<Selection<?>> getCompoundSelectionItems() {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public boolean isCompoundSelection() {
> -        // TODO Auto-generated method stub
> -        return false;
> -    }
>  }
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PathImpl.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PathImpl.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PathImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PathImpl.java
Thu Jul  9 15:29:27 2009
> @@ -254,20 +254,5 @@
>       */
>      public Expression<Class<? extends X>> type() {
>          return new Expressions.Type<X>(this);
> -}
> -
> -    public Selection<X> alias(String arg0) {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public List<Selection<?>> getCompoundSelectionItems() {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public boolean isCompoundSelection() {
> -        // TODO Auto-generated method stub
> -        return false;
>      }
>  }
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PredicateImpl.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PredicateImpl.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PredicateImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/PredicateImpl.java
Thu Jul  9 15:29:27 2009
> @@ -134,19 +134,4 @@
>              super(BooleanOperator.OR, restrictions);
>          }
>      }
> -
> -    public Selection<Boolean> alias(String arg0) {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public List<Selection<?>> getCompoundSelectionItems() {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public boolean isCompoundSelection() {
> -        // TODO Auto-generated method stub
> -        return false;
> -    }
>  }
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SelectionImpl.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SelectionImpl.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SelectionImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SelectionImpl.java
Thu Jul  9 15:29:27 2009
> @@ -18,12 +18,11 @@
>   */
>  package org.apache.openjpa.persistence.criteria;
>  
> -import java.util.Arrays;
>  import java.util.List;
>  
>  import javax.persistence.criteria.Selection;
>  
> -import org.apache.openjpa.persistence.ResultItemImpl;
> +import org.apache.openjpa.persistence.TupleElementImpl;
>  
>  /**
>   * An item selected in the projection clause of  Criteria query.
> @@ -32,36 +31,23 @@
>   *
>   * @param <X>
>   */
> -public class SelectionImpl<X> extends ResultItemImpl<X> 
> +public class SelectionImpl<X> extends TupleElementImpl<X> 
>      implements Selection<X> {
>      
> -    private List<Selection<?>>  _sels;
> -    
>      public SelectionImpl(Class<X> cls) {
>          super(cls);
>      }
>  
> -    public Selection<X> alias(String arg0) {
> -        // TODO Auto-generated method stub
> -        return null;
> +    public Selection<X> alias(String alias) {
> +        super.setAlias(alias);
> +        return this;
>      }
>  
> -    public List<Selection<?>> getCompoundSelectionItems() {
> -        // TODO Auto-generated method stub
> +    public final List<Selection<?>> getCompoundSelectionItems() {
>          return null;
>      }
>  
>      public boolean isCompoundSelection() {
> -        // TODO Auto-generated method stub
>          return false;
>      }
> -    
> -//    public SelectionImpl<X> setSelections(Selection<?>... selections)
{
> -//        _sels = Arrays.asList(selections);
> -//        return this;
> -//    }
> -//    
> -//    public List<Selection<?>> getSelections() {
> -//        return _sels;
> -//    }
>  }
> 
> Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SubqueryImpl.java
> URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SubqueryImpl.java?rev=792583&r1=792582&r2=792583&view=diff
> ==============================================================================
> --- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SubqueryImpl.java
(original)
> +++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/criteria/SubqueryImpl.java
Thu Jul  9 15:29:27 2009
> @@ -333,19 +333,4 @@
>          return from._member.fmd.getDeclaredTypeMetaData();
>          
>      }
> -
> -    public Selection<T> alias(String arg0) {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public List<Selection<?>> getCompoundSelectionItems() {
> -        // TODO Auto-generated method stub
> -        return null;
> -    }
> -
> -    public boolean isCompoundSelection() {
> -        // TODO Auto-generated method stub
> -        return false;
> -    }    
>  }
> 
> Added: openjpa/trunk/spec-src/APIsJune15.jar
> URL: http://svn.apache.org/viewvc/openjpa/trunk/spec-src/APIsJune15.jar?rev=792583&view=auto
> ==============================================================================
> Binary file - no diff available.
> 
> Propchange: openjpa/trunk/spec-src/APIsJune15.jar
> ------------------------------------------------------------------------------
>     svn:mime-type = application/octet-stream
> 
> 
> 

Mime
View raw message