directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r964401 - in /directory: apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/ apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/filtering/ apacheds/trunk/core/src/main/java/org/apache/directory/server...
Date Thu, 15 Jul 2010 12:32:20 GMT
Author: elecharny
Date: Thu Jul 15 12:32:19 2010
New Revision: 964401

URL: http://svn.apache.org/viewvc?rev=964401&view=rev
Log:
o Minor refactoring and Javadoc update

Modified:
    directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/EntryToResponseCursor.java
    directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/filtering/BaseEntryFilteringCursor.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaInterceptor.java
    directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/AndCursor.java
    directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateCursor.java
    directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityCursor.java
    directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/GreaterEqCursor.java
    directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LessEqCursor.java
    directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/PresenceCursor.java
    directory/shared/trunk/cursor/src/main/java/org/apache/directory/shared/ldap/cursor/Cursor.java

Modified: directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/EntryToResponseCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/EntryToResponseCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/EntryToResponseCursor.java
(original)
+++ directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/EntryToResponseCursor.java
Thu Jul 15 12:32:19 2010
@@ -32,13 +32,13 @@ import org.apache.directory.shared.ldap.
 
 
 /**
- * A cursor to get SearchResponseS after setting the underlying cursor's ServerEntry object
in SearchResultEnty object 
+ * A cursor to get SearchResponses after setting the underlying cursor's 
+ * ServerEntry object in SearchResultEnty object 
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class EntryToResponseCursor<SearchResponse> implements Cursor<SearchResponse>
 {
-
     /** the underlying cursor */
     private EntryFilteringCursor wrapped;
 

Modified: directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/filtering/BaseEntryFilteringCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/filtering/BaseEntryFilteringCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/filtering/BaseEntryFilteringCursor.java
(original)
+++ directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/filtering/BaseEntryFilteringCursor.java
Thu Jul 15 12:32:19 2010
@@ -38,7 +38,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.schema.AttributeType;
 import org.apache.directory.shared.ldap.schema.AttributeTypeOptions;
 import org.apache.directory.shared.ldap.schema.UsageEnum;
-
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -497,11 +496,13 @@ public class BaseEntryFilteringCursor im
         }
         
         ClonedServerEntry tempResult = null;
+        
         outer: while ( wrapped.next() )
         {
             boolean accepted = true;
             
             Entry tempEntry = wrapped.get();
+            
             if ( tempEntry instanceof ClonedServerEntry )
             {
                 tempResult = ( ClonedServerEntry ) tempEntry;
@@ -526,7 +527,7 @@ public class BaseEntryFilteringCursor im
                 return true;
             }
             
-            if ( filters.size() == 1 &&  filters.get( 0 ).accept( getOperationContext(),
tempResult ) )
+            if ( ( filters.size() == 1 ) &&  filters.get( 0 ).accept( getOperationContext(),
tempResult ) )
             {
                 prefetched = tempResult;
                 filterContents( prefetched );
@@ -534,7 +535,6 @@ public class BaseEntryFilteringCursor im
             }
             
             /* E N D   O P T I M I Z A T I O N */
-            
             for ( EntryFilter filter : filters )
             {
                 // if a filter rejects then short and continue with outer loop
@@ -549,6 +549,7 @@ public class BaseEntryFilteringCursor im
              */
             prefetched = tempResult;
             filterContents( prefetched );
+            
             return true;
         }
         
@@ -573,6 +574,7 @@ public class BaseEntryFilteringCursor im
         }
         
         ClonedServerEntry tempResult = null;
+        
         outer: while ( wrapped.previous() )
         {
             boolean accepted = true;
@@ -593,7 +595,7 @@ public class BaseEntryFilteringCursor im
                 return true;
             }
             
-            if ( filters.size() == 1 && filters.get( 0 ).accept( getOperationContext(),
tempResult ) )
+            if ( ( filters.size() == 1 ) && filters.get( 0 ).accept( getOperationContext(),
tempResult ) )
             {
                 prefetched = tempResult;
                 filterContents( prefetched );
@@ -620,6 +622,7 @@ public class BaseEntryFilteringCursor im
         }
         
         prefetched = null;
+        
         return false;
     }
 

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaInterceptor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaInterceptor.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaInterceptor.java
Thu Jul 15 12:32:19 2010
@@ -1351,6 +1351,7 @@ public class SchemaInterceptor extends B
         }
     }
 
+    
     /**
      * Filters objectClass attribute to inject top when not present.
      */

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/AndCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/AndCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/AndCursor.java
(original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/AndCursor.java
Thu Jul 15 12:32:19 2010
@@ -25,11 +25,11 @@ import java.util.Collections;
 import java.util.Comparator;
 import java.util.List;
 
-import org.apache.directory.server.xdbm.IndexEntry;
+import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.server.xdbm.AbstractIndexCursor;
 import org.apache.directory.server.xdbm.IndexCursor;
+import org.apache.directory.server.xdbm.IndexEntry;
 import org.apache.directory.server.xdbm.search.Evaluator;
-import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.shared.ldap.cursor.InvalidCursorPositionException;
 import org.apache.directory.shared.ldap.entry.Entry;
 import org.apache.directory.shared.ldap.filter.ExprNode;
@@ -139,6 +139,7 @@ public class AndCursor<V, ID> extends Ab
         {
             checkNotClosed( "next()" );
             IndexEntry<?, Entry, ID> candidate = wrapped.get();
+            
             if ( matches( candidate ) )
             {
                 return available = true;

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateCursor.java
(original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateCursor.java
Thu Jul 15 12:32:19 2010
@@ -96,6 +96,7 @@ public class ApproximateCursor<V, ID ext
     public void beforeValue( ID id, V value ) throws Exception
     {
         checkNotClosed( "beforeValue()" );
+        
         if ( userIdxCursor != null )
         {
             userIdxCursor.beforeValue( id, value );

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityCursor.java
(original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityCursor.java
Thu Jul 15 12:32:19 2010
@@ -95,6 +95,7 @@ public class EqualityCursor<V, ID extend
     public void beforeValue( ID id, V value ) throws Exception
     {
         checkNotClosed( "beforeValue()" );
+        
         if ( userIdxCursor != null )
         {
             userIdxCursor.beforeValue( id, value );

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/GreaterEqCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/GreaterEqCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/GreaterEqCursor.java
(original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/GreaterEqCursor.java
Thu Jul 15 12:32:19 2010
@@ -95,6 +95,7 @@ public class GreaterEqCursor<V, ID exten
     public void beforeValue( ID id, V value ) throws Exception
     {
         checkNotClosed( "beforeValue()" );
+        
         if ( userIdxCursor != null )
         {
             /*
@@ -166,6 +167,7 @@ public class GreaterEqCursor<V, ID exten
     public void before( IndexEntry<V, Entry, ID> element ) throws Exception
     {
         checkNotClosed( "before()" );
+        
         if ( userIdxCursor != null )
         {
             /*

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LessEqCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LessEqCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LessEqCursor.java
(original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LessEqCursor.java
Thu Jul 15 12:32:19 2010
@@ -94,6 +94,7 @@ public class LessEqCursor<V, ID extends 
     public void beforeValue( ID id, V value ) throws Exception
     {
         checkNotClosed( "beforeValue()" );
+        
         if ( userIdxCursor != null )
         {
             /*

Modified: directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/PresenceCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/PresenceCursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/PresenceCursor.java
(original)
+++ directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/PresenceCursor.java
Thu Jul 15 12:32:19 2010
@@ -79,6 +79,7 @@ public class PresenceCursor<ID extends C
     public void beforeValue( ID id, String value ) throws Exception
     {
         checkNotClosed( "beforeValue()" );
+        
         if ( presenceCursor != null )
         {
             presenceCursor.beforeValue( id, value );

Modified: directory/shared/trunk/cursor/src/main/java/org/apache/directory/shared/ldap/cursor/Cursor.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/cursor/src/main/java/org/apache/directory/shared/ldap/cursor/Cursor.java?rev=964401&r1=964400&r2=964401&view=diff
==============================================================================
--- directory/shared/trunk/cursor/src/main/java/org/apache/directory/shared/ldap/cursor/Cursor.java
(original)
+++ directory/shared/trunk/cursor/src/main/java/org/apache/directory/shared/ldap/cursor/Cursor.java
Thu Jul 15 12:32:19 2010
@@ -42,7 +42,7 @@ public interface Cursor<E> extends Itera
     /**
      * Determines whether or not a call to get() will succeed.
      *
-     * @return true if the cursor is valid get() will succeed, false otherwise
+     * @return true if a call to the get() method will succeed, false otherwise
      */
     boolean available();
 



Mime
View raw message