juergen     2002/06/05 06:39:37

  Modified:    src/share/org/apache/slide/search/basic BasicQueryImpl.java
  Log:
  Use NotNormalizer to remove all <not> expressions from the query's <where> clause.
  (ralf)
  
  Revision  Changes    Path
  1.2       +7 -5      
jakarta-slide/src/share/org/apache/slide/search/basic/BasicQueryImpl.java
  
  Index: BasicQueryImpl.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-slide/src/share/org/apache/slide/search/basic/BasicQueryImpl.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BasicQueryImpl.java       31 May 2002 12:23:23 -0000      1.1
  +++ BasicQueryImpl.java       5 Jun 2002 13:39:37 -0000       1.2
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-slide/src/share/org/apache/slide/search/basic/BasicQueryImpl.java,v 
1.1 2002/05/31 12:23:23 wam Exp $
  - * $Revision: 1.1 $
  - * $Date: 2002/05/31 12:23:23 $
  + * $Header: 
/home/cvs/jakarta-slide/src/share/org/apache/slide/search/basic/BasicQueryImpl.java,v 
1.2 2002/06/05 13:39:37 juergen Exp $
  + * $Revision: 1.2 $
  + * $Date: 2002/06/05 13:39:37 $
    *
    * ====================================================================
    *
  @@ -92,7 +92,7 @@
    * BasicSearch.
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Martin Wallmer</a>
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class BasicQueryImpl extends BasicQuery {
       
  @@ -161,12 +161,14 @@
           // <where> is not mandatory
           if (whereElement != null) {
               List expressionList = whereElement.getChildren();
  -            
  -            rootExpression = expressionFactory.createExpression
  -                ((Element) expressionList.get (0));
  +            Element whereWithoutNot =
  +                new 
NotNormalizer().getQueryWithoutNotExpression((Element)expressionList.get (0));
  +            rootExpression = expressionFactory.createExpression(whereWithoutNot);
           }
           else
               rootExpression = expressionFactory.createExpression (null);
       }
  +
  +    
   }
   
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to