wam         2002/07/04 08:21:34

  Modified:    src/share/org/apache/slide/search/basic BasicQueryScope.java
  Log:
  check resourcetype = collection
  
  Revision  Changes    Path
  1.8       +18 -6     
jakarta-slide/src/share/org/apache/slide/search/basic/BasicQueryScope.java
  
  Index: BasicQueryScope.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-slide/src/share/org/apache/slide/search/basic/BasicQueryScope.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- BasicQueryScope.java      19 Jun 2002 11:00:11 -0000      1.7
  +++ BasicQueryScope.java      4 Jul 2002 15:21:34 -0000       1.8
  @@ -89,6 +89,7 @@
       /** the depth of this query. */
       private int    depth;
       
  +    private boolean isCollection = true;
       
       /**
        * Constructs a scope
  @@ -146,8 +147,8 @@
           // must not be a valid URL (server redirection not implemented)
           catch (java.net.MalformedURLException e) {}
           
  -        if (!href.endsWith("/"))
  -            href += "/";
  +//        if (!href.endsWith("/"))
  +//            href += "/";
           
           Element depth = scope.getChild (Literals.DEPTH, namespace);
           if (depth != null) {
  @@ -211,5 +212,16 @@
       public String toString () {
           return href + ", depth = " + depth;
       }
  +    
  +    public void setIsCollection(boolean isCollection) {
  +        this.isCollection = isCollection;
  +        if (isCollection == true && !href.endsWith("/"))
  +            href = href + "/";
  +    }
  +    
  +    public boolean isCollection() {
  +        return isCollection;
  +    }
  +    
       
   }
  
  
  

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

Reply via email to