You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by se...@apache.org on 2010/09/27 10:29:27 UTC

svn commit: r1001621 [1/2] - in /directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api: ./ callback/ exception/ future/ listener/ protocol/

Author: seelmann
Date: Mon Sep 27 08:29:26 2010
New Revision: 1001621

URL: http://svn.apache.org/viewvc?rev=1001621&view=rev
Log:
Fixed checkstyle errors, javadocs, and formatting

Modified:
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/Krb5LoginConfiguration.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapAsyncConnection.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnection.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionConfig.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionFactory.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionPool.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NetworkSchemaLoader.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NoVerificationTrustManager.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/PoolableLdapConnectionFactory.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/SearchCursor.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/callback/SaslCallbackHandler.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/exception/InvalidConnectionException.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/future/ResponseFuture.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/AddListener.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/CompareListener.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/DeleteListener.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ExtendedListener.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ModifyDnListener.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ModifyListener.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/protocol/LdapProtocolCodecFactory.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/protocol/LdapProtocolDecoder.java
    directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/protocol/LdapProtocolEncoder.java

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/Krb5LoginConfiguration.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/Krb5LoginConfiguration.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/Krb5LoginConfiguration.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/Krb5LoginConfiguration.java Mon Sep 27 08:29:26 2010
@@ -23,8 +23,8 @@ package org.apache.directory.ldap.client
 import java.util.HashMap;
 
 import javax.security.auth.login.AppConfigurationEntry;
-import javax.security.auth.login.Configuration;
 import javax.security.auth.login.AppConfigurationEntry.LoginModuleControlFlag;
+import javax.security.auth.login.Configuration;
 
 
 /**
@@ -32,6 +32,8 @@ import javax.security.auth.login.AppConf
  */
 public class Krb5LoginConfiguration extends Configuration
 {
+
+    /** The list with configuration entries. */
     private static AppConfigurationEntry[] configList = new AppConfigurationEntry[1];
 
 
@@ -48,6 +50,9 @@ public class Krb5LoginConfiguration exte
 
     /**
      * Interface method requiring us to return all the LoginModules we know about.
+     *
+     * @param applicationName the application name
+     * @return the configuration entry
      */
     public AppConfigurationEntry[] getAppConfigurationEntry( String applicationName )
     {

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapAsyncConnection.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapAsyncConnection.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapAsyncConnection.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapAsyncConnection.java Mon Sep 27 08:29:26 2010
@@ -44,6 +44,11 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.name.DN;
 
 
+/**
+ * Root interface for all asynchronous LDAP connections.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
 public interface LdapAsyncConnection extends LdapConnection
 {
 
@@ -52,7 +57,8 @@ public interface LdapAsyncConnection ext
      * the user has to get for the response from the returned Future.
      * 
      * @param entry The entry to add
-     * @return the add operation's Future 
+     * @return the add operation's future
+     * @throws LdapException if some error occurred
      */
     AddFuture addAsync( Entry entry ) throws LdapException;
 
@@ -61,8 +67,8 @@ public interface LdapAsyncConnection ext
      * Add an entry present in the AddRequest to the server.
      * 
      * @param addRequest the request object containing an entry and controls(if any)
-     * @return the add operation's response
-     * @throws LdapException
+     * @return the add operation's future
+     * @throws LdapException if some error occurred
      */
     AddFuture addAsync( AddRequest addRequest ) throws LdapException;
 
@@ -70,7 +76,9 @@ public interface LdapAsyncConnection ext
     /**
      * Anonymous asynchronous Bind on a server. 
      *
-     * @return The BindFuture
+     * @return the bind operation's future
+     * @throws LdapException if some error occurred
+     * @throws IOException if some IO error occurred
      */
     BindFuture bindAsync() throws LdapException, IOException;
 
@@ -78,10 +86,11 @@ public interface LdapAsyncConnection ext
     /**
      * Simple asynchronous Bind on a server.
      *
-     * @param name The name we use to authenticate the user. It must be a 
-     * valid DN
-     * @param credentials The password. It can't be null 
-     * @return The BindResponse LdapResponse 
+     * @param name The name we use to authenticate the user, it must be a valid DN
+     * @param credentials The password, it can't be null 
+     * @return the bind operation's future
+     * @throws LdapException if some error occurred
+     * @throws IOException if some IO error occurred
      */
     BindFuture bindAsync( String name, String credentials ) throws LdapException, IOException;
 
@@ -89,10 +98,11 @@ public interface LdapAsyncConnection ext
     /**
      * Simple asynchronous Bind on a server.
      *
-     * @param name The name we use to authenticate the user. It must be a 
-     * valid DN
-     * @param credentials The password. It can't be null 
-     * @return The BindResponse LdapResponse 
+     * @param name The name we use to authenticate the user, it must be a valid DN
+     * @param credentials The password, it can't be null
+     * @return the bind operation's future
+     * @throws LdapException if some error occurred
+     * @throws IOException if some IO error occurred
      */
     BindFuture bindAsync( DN name, String credentials ) throws LdapException, IOException;
 
@@ -101,7 +111,9 @@ public interface LdapAsyncConnection ext
      * Do an asynchronous bind, based on a BindRequest.
      *
      * @param bindRequest The BindRequest to send
-     * @return BindFuture A future
+     * @return the bind operation's future
+     * @throws LdapException if some error occurred
+     * @throws IOException if some IO error occurred
      */
     BindFuture bindAsync( BindRequest bindRequest ) throws LdapException, IOException;
 
@@ -109,6 +121,7 @@ public interface LdapAsyncConnection ext
     /**
      * Do an asynchronous search, on the base object, using the given filter. The
      * SearchRequest parameters default to :
+     * <pre>
      * Scope : ONE
      * DerefAlias : ALWAYS
      * SizeLimit : none
@@ -116,13 +129,14 @@ public interface LdapAsyncConnection ext
      * TypesOnly : false
      * Attributes : all the user's attributes.
      * This method is blocking.
+     * </pre>
      * 
-     * @param baseDn The base for the search. It must be a valid
-     * DN, and can't be emtpy
-     * @param filter The filter to use for this search. It can't be empty
+     * @param baseDn The base for the search, it must be a valid DN, and can't be emtpy
+     * @param filter The filter to use for this search, it can't be empty
      * @param scope The search scope : OBJECT, ONELEVEL or SUBTREE 
      * @param attributes The attributes for this search 
-     * @return A cursor on the result. 
+     * @return the search operation's future
+     * @throws LdapException if some error occurred
      */
     SearchFuture searchAsync( String baseDn, String filter, SearchScope scope, String... attributes )
         throws LdapException;
@@ -131,6 +145,7 @@ public interface LdapAsyncConnection ext
     /**
      * Do an asynchronous search, on the base object, using the given filter. The
      * SearchRequest parameters default to :
+     * <pre>
      * Scope : ONE
      * DerefAlias : ALWAYS
      * SizeLimit : none
@@ -138,13 +153,14 @@ public interface LdapAsyncConnection ext
      * TypesOnly : false
      * Attributes : all the user's attributes.
      * This method is blocking.
+     * </pre>
      * 
-     * @param baseDn The base for the search. It must be a valid
-     * DN, and can't be emtpy
-     * @param filter The filter to use for this search. It can't be empty
+     * @param baseDn The base for the search, it must be a valid DN, and can't be empty
+     * @param filter The filter to use for this search, it can't be empty
      * @param scope The search scope : OBJECT, ONELEVEL or SUBTREE
      * @param attributes The attributes for this search 
-     * @return A cursor on the result. 
+     * @return the search operation's future
+     * @throws LdapException if some error occurred
      */
     SearchFuture searchAsync( DN baseDn, String filter, SearchScope scope, String... attributes )
         throws LdapException;
@@ -153,6 +169,7 @@ public interface LdapAsyncConnection ext
     /**
      * Do a search, on the base object, using the given filter. The
      * SearchRequest parameters default to :
+     * <pre>
      * Scope : ONE
      * DerefAlias : ALWAYS
      * SizeLimit : none
@@ -160,9 +177,11 @@ public interface LdapAsyncConnection ext
      * TypesOnly : false
      * Attributes : all the user's attributes.
      * This method is blocking.
+     * </pre>
      * 
      * @param searchRequest The search request to send to the server
-     * @return A Future 
+     * @return the search operation's future
+     * @throws LdapException if some error occurred
      */
     SearchFuture searchAsync( SearchRequest searchRequest ) throws LdapException;
 
@@ -179,12 +198,11 @@ public interface LdapAsyncConnection ext
 
 
     /**
-     * 
-     * performs the modifyDn operation based on the given ModifyDnRequest.
+     * Performs the modifyDn operation based on the given ModifyDnRequest.
      *
      * @param modDnRequest the request
-     * @return modifyDn operations response, null if non-null listener is provided
-     * @throws LdapException
+     * @return modifyDn operation's future
+     * @throws LdapException if some error occurred
      */
     ModifyDnFuture modifyDnAsync( ModifyDnRequest modDnRequest ) throws LdapException;
 
@@ -193,7 +211,7 @@ public interface LdapAsyncConnection ext
      * Performs an asynchronous delete operation based on the delete request object.
      *  
      * @param delRequest the delete operation's request
-     * @return delete operation's response, null if a non-null listener value is provided
+     * @return delete operation's future
      * @throws LdapException If the DN is not valid or if the deletion failed
      */
     DeleteFuture deleteAsync( DeleteRequest delRequest ) throws LdapException;
@@ -204,7 +222,7 @@ public interface LdapAsyncConnection ext
      *   
      * @param compareRequest the CompareRequest which contains the target DN, attribute name and value
      * @return compare operation's future
-     * @throws LdapException
+     * @throws LdapException if some error occurred
      */
     CompareFuture compareAsync( CompareRequest compareRequest ) throws LdapException;
 
@@ -214,15 +232,15 @@ public interface LdapAsyncConnection ext
      *
      * @param extendedRequest the object containing the details of the extended operation to be performed
      * @return extended operation's Future
-     * @throws LdapException
+     * @throws LdapException if some error occurred
      */
     ExtendedFuture extendedAsync( ExtendedRequest extendedRequest ) throws LdapException;
 
 
     /**
-     * configuration of LdapNetworkConnection
+     * Configuration of LdapNetworkConnection
      * 
-     * @return the configuration of the ldap connection
+     * @return the configuration of the LDAP connection
      */
     LdapConnectionConfig getConfig();
 }
\ No newline at end of file

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnection.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnection.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnection.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnection.java Mon Sep 27 08:29:26 2010
@@ -54,7 +54,7 @@ import org.apache.directory.shared.ldap.
 
 
 /**
- * The root interface for all the LdapConnection implementations/
+ * The root interface for all the LDAP connection implementations.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
@@ -65,7 +65,7 @@ public interface LdapConnection
      *
      * @return <code>true</code> if we are connected.
      */
-    public abstract boolean isConnected();
+    boolean isConnected();
 
 
     /**
@@ -73,7 +73,7 @@ public interface LdapConnection
      *
      * @return <code>true</code> if we are connected.
      */
-    public abstract boolean isAuthenticated();
+    boolean isAuthenticated();
 
 
     /**
@@ -83,7 +83,7 @@ public interface LdapConnection
      * @throws LdapException if some error occurred
      * @throws IOException if an I/O exception occurred
      */
-    public abstract boolean connect() throws LdapException, IOException;
+    boolean connect() throws LdapException, IOException;
 
 
     /**
@@ -92,7 +92,7 @@ public interface LdapConnection
      * @return <code>true</code> if the connection is closed, false otherwise
      * @throws IOException if some I/O error occurs
      */
-    public abstract boolean close() throws IOException;
+    boolean close() throws IOException;
 
 
     //------------------------ The LDAP operations ------------------------//
@@ -106,7 +106,7 @@ public interface LdapConnection
      * @return the add operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract AddResponse add( Entry entry ) throws LdapException;
+    AddResponse add( Entry entry ) throws LdapException;
 
 
     /**
@@ -116,7 +116,7 @@ public interface LdapConnection
      * @return the add operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract AddResponse add( AddRequest addRequest ) throws LdapException;
+    AddResponse add( AddRequest addRequest ) throws LdapException;
 
 
     /**
@@ -126,7 +126,7 @@ public interface LdapConnection
      *
      * @param messageId the ID of the request message sent to the server
      */
-    public abstract void abandon( int messageId );
+    void abandon( int messageId );
 
 
     /**
@@ -137,7 +137,7 @@ public interface LdapConnection
      *
      * @param abandonRequest the abandon operation's request
      */
-    public abstract void abandon( AbandonRequest abandonRequest );
+    void abandon( AbandonRequest abandonRequest );
 
 
     /**
@@ -147,7 +147,7 @@ public interface LdapConnection
      * @throws LdapException if some error occurred
      * @throws IOException if an I/O exception occurred
      */
-    public abstract BindResponse bind() throws LdapException, IOException;
+    BindResponse bind() throws LdapException, IOException;
 
 
     /**
@@ -160,7 +160,7 @@ public interface LdapConnection
      * @throws LdapException if some error occurred
      * @throws IOException if an I/O exception occurred
      */
-    public abstract BindResponse bind( String name, String credentials ) throws LdapException, IOException;
+    BindResponse bind( String name, String credentials ) throws LdapException, IOException;
 
 
     /**
@@ -173,7 +173,7 @@ public interface LdapConnection
      * @throws LdapException if some error occurred
      * @throws IOException if an I/O exception occurred
      */
-    public abstract BindResponse bind( DN name, String credentials ) throws LdapException, IOException;
+    BindResponse bind( DN name, String credentials ) throws LdapException, IOException;
 
 
     /**
@@ -185,7 +185,7 @@ public interface LdapConnection
      * @throws LdapException if some error occurred
      * @throws IOException if an I/O exception occurred
      */
-    public abstract BindResponse bind( BindRequest bindRequest ) throws LdapException, IOException;
+    BindResponse bind( BindRequest bindRequest ) throws LdapException, IOException;
 
 
     /**
@@ -207,7 +207,7 @@ public interface LdapConnection
      * @return A cursor on the result.
      * @throws LdapException if some error occurred
      */
-    public abstract Cursor<Response> search( DN baseDn, String filter, SearchScope scope, String... attributes )
+    Cursor<Response> search( DN baseDn, String filter, SearchScope scope, String... attributes )
         throws LdapException;
 
 
@@ -230,7 +230,7 @@ public interface LdapConnection
      * @return A cursor on the result.
      * @throws LdapException if some error occurred
      */
-    public abstract Cursor<Response> search( String baseDn, String filter, SearchScope scope, String... attributes )
+    Cursor<Response> search( String baseDn, String filter, SearchScope scope, String... attributes )
         throws LdapException;
 
 
@@ -241,17 +241,17 @@ public interface LdapConnection
      * @return A {@link Cursor} containing Entries and References
      * @throws LdapException if some error occurred
      */
-    public abstract Cursor<Response> search( SearchRequest searchRequest ) throws LdapException;
+    Cursor<Response> search( SearchRequest searchRequest ) throws LdapException;
 
 
     //------------------------ The LDAP operations ------------------------//
     // Unbind operations                                                   //
     //---------------------------------------------------------------------//
     /**
-     * UnBind from a server. this is a request which expect no response.
+     * UnBind from a server. This is a request which expect no response.
      * @throws LdapException if some error occurred
      */
-    public abstract void unBind() throws LdapException;
+    void unBind() throws LdapException;
 
 
     /**
@@ -260,43 +260,40 @@ public interface LdapConnection
      *
      * @param timeOut The timeout, in milliseconds
      */
-    public abstract void setTimeOut( long timeOut );
+    void setTimeOut( long timeOut );
 
 
     /**
-     *
-     * Applies all the modifications to the entry specified by its DN
+     * Applies all the modifications to the entry specified by its DN.
      *
      * @param dn The entry's DN
      * @param modifications The list of modifications to be applied
      * @return the modify operation's response
      * @throws LdapException in case of modify operation failure or timeout happens
      */
-    public abstract ModifyResponse modify( DN dn, Modification... modifications ) throws LdapException;
+    ModifyResponse modify( DN dn, Modification... modifications ) throws LdapException;
 
 
     /**
-    *
-    * Applies all the modifications to the entry specified by its DN
-    *
-    * @param dn The entry's DN
-    * @param modifications The list of modifications to be applied
-    * @return the modify operation's response
-    * @throws LdapException in case of modify operation failure or timeout happens
-    */
-    public abstract ModifyResponse modify( String dn, Modification... modifications ) throws LdapException;
+     * Applies all the modifications to the entry specified by its DN.
+     *
+     * @param dn The entry's DN
+     * @param modifications The list of modifications to be applied
+     * @return the modify operation's response
+     * @throws LdapException in case of modify operation failure or timeout happens
+     */
+    ModifyResponse modify( String dn, Modification... modifications ) throws LdapException;
 
 
     /**
-     *
-     * modifies all the attributes present in the entry by applying the same operation.
+     * Modifies all the attributes present in the entry by applying the same operation.
      *
      * @param entry the entry with the attributes to be modified
      * @param modOp the operation to be applied on all the attributes of the above entry
      * @return the modify operation's response
      * @throws LdapException in case of modify operation failure or timeout happens
      */
-    public abstract ModifyResponse modify( Entry entry, ModificationOperation modOp ) throws LdapException;
+    ModifyResponse modify( Entry entry, ModificationOperation modOp ) throws LdapException;
 
 
     /**
@@ -307,131 +304,160 @@ public interface LdapConnection
      * @return the modify operation's response
      * @throws LdapException in case of modify operation failure or timeout happens
      */
-    public abstract ModifyResponse modify( ModifyRequest modRequest ) throws LdapException;
+    ModifyResponse modify( ModifyRequest modRequest ) throws LdapException;
 
 
     /**
-     * renames the given entryDn with new Rdn and deletes the old RDN.
-     * @see #rename(String, String, boolean)
+     * Renames the given entryDn with new RDN and deletes the old RDN.
+     *
+     * @param entryDn the target DN
+     * @param newRdn new RDN for the target DN
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
+     * @see #rename(String, String, boolean)
      */
-    public abstract ModifyDnResponse rename( String entryDn, String newRdn ) throws LdapException;
+    ModifyDnResponse rename( String entryDn, String newRdn ) throws LdapException;
 
 
     /**
-     * renames the given entryDn with new RDN and deletes the old RDN.
-     * @see #rename(DN, RDN, boolean)
+     * Renames the given entryDn with new RDN and deletes the old RDN.
+     *
+     * @param entryDn the target DN
+     * @param newRdn new RDN for the target DN
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
+     * @see #rename(DN, RDN, boolean)
      */
-    public abstract ModifyDnResponse rename( DN entryDn, RDN newRdn ) throws LdapException;
+    ModifyDnResponse rename( DN entryDn, RDN newRdn ) throws LdapException;
 
 
     /**
-     * @see #rename(DN, RDN, boolean)
+     * Renames the given entryDn with new RDN and deletes the old RDN if
+     * deleteOldRdn is set to true.
+     *
+     * @param entryDn the target DN
+     * @param newRdn new RDN for the target DN
+     * @param deleteOldRdn flag to indicate whether to delete the old RDN
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
+     * @see #rename(DN, RDN, boolean)
      */
-    public abstract ModifyDnResponse rename( String entryDn, String newRdn, boolean deleteOldRdn ) throws LdapException;
+    ModifyDnResponse rename( String entryDn, String newRdn, boolean deleteOldRdn ) throws LdapException;
 
 
     /**
-     *
-     * renames the given entryDn with new RDN and deletes the old Rdn if
+     * Renames the given entryDn with new RDN and deletes the old RDN if
      * deleteOldRdn is set to true.
      *
      * @param entryDn the target DN
-     * @param newRdn new Rdn for the target DN
-     * @param deleteOldRdn flag to indicate whether to delete the old Rdn
-     * @return modifyDn operations response
+     * @param newRdn new RDN for the target DN
+     * @param deleteOldRdn flag to indicate whether to delete the old RDN
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract ModifyDnResponse rename( DN entryDn, RDN newRdn, boolean deleteOldRdn ) throws LdapException;
+    ModifyDnResponse rename( DN entryDn, RDN newRdn, boolean deleteOldRdn ) throws LdapException;
 
 
     /**
+     * Moves the given entry DN under the new superior DN.
+     *
+     * @param entryDn the DN of the target entry
+     * @param newSuperiorDn DN of the new parent/superior
+     * @return modifyDn operation's response
+     * @throws LdapException if some error occurred
      * @see #move(DN, DN)
      */
-    public abstract ModifyDnResponse move( String entryDn, String newSuperiorDn ) throws LdapException;
+    ModifyDnResponse move( String entryDn, String newSuperiorDn ) throws LdapException;
 
 
     /**
-     * moves the given entry DN under the new superior DN
+     * Moves the given entry DN under the new superior DN.
      *
      * @param entryDn the DN of the target entry
      * @param newSuperiorDn DN of the new parent/superior
-     * @return modifyDn operations response
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract ModifyDnResponse move( DN entryDn, DN newSuperiorDn ) throws LdapException;
+    ModifyDnResponse move( DN entryDn, DN newSuperiorDn ) throws LdapException;
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted
+     * Moves and renames the given entryDn. The old RDN will be deleted.
      *
-     * @see #moveAndRename(DN, DN, boolean)
+     * @param entryDn The original entry DN
+     * @param newDn The new Entry DN
+     * @return modifyDn operations response
      * @throws LdapException if some error occurred
+     * @see #moveAndRename(DN, DN, boolean)
      */
-    public abstract ModifyDnResponse moveAndRename( DN entryDn, DN newDn ) throws LdapException;
+    ModifyDnResponse moveAndRename( DN entryDn, DN newDn ) throws LdapException;
 
 
     /**
      * Moves and renames the given entryDn.The old RDN will be deleted
      *
-     * @see #moveAndRename(DN, DN, boolean)
+     * @param entryDn The original entry DN
+     * @param newDn The new Entry DN
+     * @return modifyDn operations response
      * @throws LdapException if some error occurred
+     * @see #moveAndRename(DN, DN, boolean)
      */
-    public abstract ModifyDnResponse moveAndRename( String entryDn, String newDn ) throws LdapException;
+    ModifyDnResponse moveAndRename( String entryDn, String newDn ) throws LdapException;
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted if requested
+     * Moves and renames the given entryDn. The old RDN will be deleted if requested.
      *
      * @param entryDn The original entry DN
      * @param newDn The new Entry DN
      * @param deleteOldRdn Tells if the old RDN must be removed
+     * @return modifyDn operations response
      * @throws LdapException if some error occurred
      */
-    public abstract ModifyDnResponse moveAndRename( DN entryDn, DN newDn, boolean deleteOldRdn ) throws LdapException;
+    ModifyDnResponse moveAndRename( DN entryDn, DN newDn, boolean deleteOldRdn ) throws LdapException;
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted if requested
+     * Moves and renames the given entryDn. The old RDN will be deleted if requested.
      *
      * @param entryDn The original entry DN
      * @param newDn The new Entry DN
      * @param deleteOldRdn Tells if the old RDN must be removed
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract ModifyDnResponse moveAndRename( String entryDn, String newDn, boolean deleteOldRdn )
+    ModifyDnResponse moveAndRename( String entryDn, String newDn, boolean deleteOldRdn )
         throws LdapException;
 
 
     /**
-     *
-     * performs the modifyDn operation based on the given ModifyDnRequest.
+     * Performs the modifyDn operation based on the given ModifyDnRequest.
      *
      * @param modDnRequest the request
-     * @return modifyDn operations response, null if non-null listener is provided
+     * @return modifyDn operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract ModifyDnResponse modifyDn( ModifyDnRequest modDnRequest ) throws LdapException;
+    ModifyDnResponse modifyDn( ModifyDnRequest modDnRequest ) throws LdapException;
 
 
     /**
-     * deletes the entry with the given DN
+     * Deletes the entry with the given DN.
      *
      * @param dn the target entry's DN as a String
+     * @return the delete operation's response
      * @throws LdapException If the DN is not valid or if the deletion failed
      */
-    public abstract DeleteResponse delete( String dn ) throws LdapException;
+    DeleteResponse delete( String dn ) throws LdapException;
 
 
     /**
-     * deletes the entry with the given DN
+     * Deletes the entry with the given DN.
      *
      * @param dn the target entry's DN
+     * @return the delete operation's response
      * @throws LdapException If the DN is not valid or if the deletion failed
      */
-    public abstract DeleteResponse delete( DN dn ) throws LdapException;
+    DeleteResponse delete( DN dn ) throws LdapException;
 
 
     /**
@@ -441,25 +467,25 @@ public interface LdapConnection
      * @return delete operation's response, null if a non-null listener value is provided
      * @throws LdapException If the DN is not valid or if the deletion failed
      */
-    public abstract DeleteResponse delete( DeleteRequest deleteRequest ) throws LdapException;
+    DeleteResponse delete( DeleteRequest deleteRequest ) throws LdapException;
 
 
     /**
-     * Compares a whether a given attribute's value matches that of the
-     * existing value of the attribute present in the entry with the given DN
+     * Compares whether a given attribute's value matches that of the
+     * existing value of the attribute present in the entry with the given DN.
      *
      * @param dn the target entry's String DN
      * @param attributeName the attribute's name
      * @param value a String value with which the target entry's attribute value to be compared with
      * @return compare operation's response
-     * @throws LdapException
+     * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( String dn, String attributeName, String value ) throws LdapException;
+    CompareResponse compare( String dn, String attributeName, String value ) throws LdapException;
 
 
     /**
-     * Compares a whether a given attribute's value matches that of the
-     * existing value of the attribute present in the entry with the given DN
+     * Compares whether a given attribute's value matches that of the
+     * existing value of the attribute present in the entry with the given DN.
      *
      * @param dn the target entry's String DN
      * @param attributeName the attribute's name
@@ -467,12 +493,12 @@ public interface LdapConnection
      * @return compare operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( String dn, String attributeName, byte[] value ) throws LdapException;
+    CompareResponse compare( String dn, String attributeName, byte[] value ) throws LdapException;
 
 
     /**
-     * Compares a whether a given attribute's value matches that of the
-     * existing value of the attribute present in the entry with the given DN
+     * Compares whether a given attribute's value matches that of the
+     * existing value of the attribute present in the entry with the given DN.
      *
      * @param dn the target entry's String DN
      * @param attributeName the attribute's name
@@ -480,12 +506,12 @@ public interface LdapConnection
      * @return compare operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( String dn, String attributeName, Value<?> value ) throws LdapException;
+    CompareResponse compare( String dn, String attributeName, Value<?> value ) throws LdapException;
 
 
     /**
-     * Compares a whether a given attribute's value matches that of the
-     * existing value of the attribute present in the entry with the given DN
+     * Compares whether a given attribute's value matches that of the
+     * existing value of the attribute present in the entry with the given DN.
      *
      * @param dn the target entry's DN
      * @param attributeName the attribute's name
@@ -493,12 +519,12 @@ public interface LdapConnection
      * @return compare operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( DN dn, String attributeName, String value ) throws LdapException;
+    CompareResponse compare( DN dn, String attributeName, String value ) throws LdapException;
 
 
     /**
-     * Compares a whether a given attribute's value matches that of the
-     * existing value of the attribute present in the entry with the given DN
+     * Compares whether a given attribute's value matches that of the
+     * existing value of the attribute present in the entry with the given DN.
      *
      * @param dn the target entry's DN
      * @param attributeName the attribute's name
@@ -506,12 +532,12 @@ public interface LdapConnection
      * @return compare operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( DN dn, String attributeName, byte[] value ) throws LdapException;
+    CompareResponse compare( DN dn, String attributeName, byte[] value ) throws LdapException;
 
 
     /**
-     * Compares a whether a given attribute's value matches that of the
-     * existing value of the attribute present in the entry with the given DN
+     * Compares whether a given attribute's value matches that of the
+     * existing value of the attribute present in the entry with the given DN.
      *
      * @param dn the target entry's DN
      * @param attributeName the attribute's name
@@ -519,49 +545,62 @@ public interface LdapConnection
      * @return compare operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( DN dn, String attributeName, Value<?> value ) throws LdapException;
+    CompareResponse compare( DN dn, String attributeName, Value<?> value ) throws LdapException;
 
 
     /**
-     * compares an entry's attribute's value with that of the given value
+     * Compares an entry's attribute's value with that of the given value.
      *
      * @param compareRequest the CompareRequest which contains the target DN, attribute name and value
      * @return compare operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract CompareResponse compare( CompareRequest compareRequest ) throws LdapException;
+    CompareResponse compare( CompareRequest compareRequest ) throws LdapException;
 
 
     /**
-     * @see #extended(OID, byte[])
+     * Sends a extended operation request to the server with the given OID and no value.
+     *
+     * @param oid the object identifier of the extended operation
+     * @return extended operation's response
      * @throws LdapException if some error occurred
+     * @see #extended(OID, byte[])
      */
-    public abstract ExtendedResponse extended( String oid ) throws LdapException;
+    ExtendedResponse extended( String oid ) throws LdapException;
 
 
     /**
-     * @see #extended(OID, byte[])
+     * Sends a extended operation request to the server with the given OID and value.
+     *
+     * @param oid the object identifier of the extended operation
+     * @param value value to be used by the extended operation, can be a null value
+     * @return extended operation's response
      * @throws LdapException if some error occurred
+     * @see #extended(OID, byte[])
      */
-    public abstract ExtendedResponse extended( String oid, byte[] value ) throws LdapException;
+    ExtendedResponse extended( String oid, byte[] value ) throws LdapException;
 
 
     /**
-     * @see #extended(OID, byte[])
+     * Sends a extended operation request to the server with the given OID and no value.
+     *
+     * @param oid the object identifier of the extended operation
+     * @return extended operation's response
      * @throws LdapException if some error occurred
+     * @see #extended(OID, byte[])
      */
-    public abstract ExtendedResponse extended( OID oid ) throws LdapException;
+    ExtendedResponse extended( OID oid ) throws LdapException;
 
 
     /**
-     * sends a extended operation request to the server with the given OID and value
+     * Sends a extended operation request to the server with the given OID and value.
      *
      * @param oid the object identifier of the extended operation
      * @param value value to be used by the extended operation, can be a null value
      * @return extended operation's response
      * @throws LdapException if some error occurred
      */
-    public abstract ExtendedResponse extended( OID oid, byte[] value ) throws LdapException;
+    ExtendedResponse extended( OID oid, byte[] value ) throws LdapException;
 
 
     /**
@@ -571,104 +610,117 @@ public interface LdapConnection
      * @return Extended operation's response
      * @throws LdapException If the DN is not valid or if the extended operation failed
      */
-    public abstract ExtendedResponse extended( ExtendedRequest extendedRequest ) throws LdapException;
+    ExtendedResponse extended( ExtendedRequest extendedRequest ) throws LdapException;
 
 
     /**
-     * Tells if an Entry exists in the server
+     * Tells if an Entry exists in the server.
      * 
      * @param dn The DN for the entry we want to check the existence
      * @return <code>true</code> if the entry exists, <code>false</code> otherwise. 
-     * Note that if the entry exists but if the users does not have the permission to
+     * Note that if the entry exists but if the user does not have the permission to
      * read it, <code>false</code> will also be returned 
      * @throws LdapException if some error occurred
      */
-    public abstract boolean exists( String dn ) throws LdapException;
+    boolean exists( String dn ) throws LdapException;
 
 
     /**
-     * Tells if an Entry exists in the server
+     * Tells if an Entry exists in the server.
      * 
      * @param dn The DN for the entry we want to check the existence
      * @return <code>true</code> if the entry exists, <code>false</code> otherwise. 
-     * Note that if the entry exists but if the users does not have the permission to
+     * Note that if the entry exists but if the user does not have the permission to
      * read it, <code>false</code> will also be returned 
      * @throws LdapException if some error occurred
      */
-    public abstract boolean exists( DN dn ) throws LdapException;
+    boolean exists( DN dn ) throws LdapException;
 
 
     /**
+     * Searches for an entry having the given DN.
+     *
+     * @param dn the DN of the entry to be fetched
+     * @return the Entry with the given DN or null if no entry exists with that DN
+     * @throws LdapException in case of any problems while searching for the DN or if the returned response contains a referral
      * @see #lookup(DN, String...)
-     * @throws LdapException if some error occurred
      */
-    public abstract Entry lookup( DN dn ) throws LdapException;
+    Entry lookup( DN dn ) throws LdapException;
 
 
     /**
+     * Searches for an entry having the given DN.
+     *
+     * @param dn the DN of the entry to be fetched
+     * @return the Entry with the given DN or null if no entry exists with that DN
+     * @throws LdapException in case of any problems while searching for the DN or if the returned response contains a referral
      * @see #lookup(String, String...)
-     * @throws LdapException if some error occurred
      */
-    public abstract Entry lookup( String dn ) throws LdapException;
+    Entry lookup( String dn ) throws LdapException;
 
 
     /**
-     * searches for an entry having the given DN
+     * Searches for an entry having the given DN.
      *
      * @param dn the DN of the entry to be fetched
      * @param attributes the attributes to be returned along with entry
      * @return the Entry with the given DN or null if no entry exists with that DN
      * @throws LdapException in case of any problems while searching for the DN or if the returned response contains a referral
      */
-    public abstract Entry lookup( DN dn, String... attributes ) throws LdapException;
+    Entry lookup( DN dn, String... attributes ) throws LdapException;
 
 
     /**
+     * Searches for an entry having the given DN.
+     *
+     * @param dn the DN of the entry to be fetched
+     * @param attributes the attributes to be returned along with entry
+     * @return the Entry with the given DN or null if no entry exists with that DN
+     * @throws LdapException in case of any problems while searching for the DN or if the returned response contains a referral
      * @see #lookup(DN, String...)
-     * @throws LdapException if some error occurred
      */
-    public abstract Entry lookup( String dn, String... attributes ) throws LdapException;
+    Entry lookup( String dn, String... attributes ) throws LdapException;
 
 
     /**
-     * checks if a control with the given OID is supported
+     * Checks if a control with the given OID is supported.
      *
      * @param controlOID the OID of the control
      * @return true if the control is supported, false otherwise
      * @throws LdapException if some error occurred
      */
-    public abstract boolean isControlSupported( String controlOID ) throws LdapException;
+    boolean isControlSupported( String controlOID ) throws LdapException;
 
 
     /**
-     * get the Controls supported by server.
+     * Get the Controls supported by server.
      *
      * @return a list of control OIDs supported by server
      * @throws LdapException if some error occurred
      */
-    public abstract List<String> getSupportedControls() throws LdapException;
+    List<String> getSupportedControls() throws LdapException;
 
 
     /**
-     * loads the default schema that is bundled in the shared-ldap-schema.jar
+     * Loads the default schema that is bundled in the API.
      *
      * @throws LdapException in case of problems while loading the schema
      */
-    public abstract void loadSchema() throws LdapException;
+    void loadSchema() throws LdapException;
 
 
     /**
      * @return The SchemaManager associated with this LdapConection if any
      */
-    public abstract SchemaManager getSchemaManager();
+    SchemaManager getSchemaManager();
 
 
     /**
-     * checks if there is a ResponseFuture associated with the given message id
+     * Checks if there is a ResponseFuture associated with the given message ID.
      *
      * @param messageId ID of the request
      * @return true if there is a non-null future exists, false otherwise
      */
-    public abstract boolean doesFutureExistFor( int messageId );
+    boolean doesFutureExistFor( int messageId );
 
 }
\ No newline at end of file

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionConfig.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionConfig.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionConfig.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionConfig.java Mon Sep 27 08:29:26 2010
@@ -20,6 +20,7 @@
 
 package org.apache.directory.ldap.client.api;
 
+
 import java.security.SecureRandom;
 
 import javax.net.ssl.KeyManager;
@@ -34,25 +35,26 @@ import javax.net.ssl.TrustManager;
 public class LdapConnectionConfig
 {
 
-    /** Define the default ports for LDAP and LDAPS */
+    /** Default ports for LDAP */
     public static final int DEFAULT_LDAP_PORT = 389;
 
+    /** Default port for LDAPS */
     public static final int DEFAULT_LDAPS_PORT = 636;
 
     /** The default host : localhost */
     public static final String DEFAULT_LDAP_HOST = "127.0.0.1";
 
     /** The LDAP version */
-    public static int LDAP_V3 = 3;
+    public static final int LDAP_V3 = 3;
 
     /** The default timeout for operation : 30 seconds */
     public static final long DEFAULT_TIMEOUT = 30000L;
 
     /** the default protocol used for creating SSL context */
     public static final String DEFAULT_SSL_PROTOCOL = "TLS";
-    
+
     // --- private members ----
-    
+
     /** A flag indicating if we are using SSL or not, default value is false */
     private boolean useSsl = false;
 
@@ -70,151 +72,267 @@ public class LdapConnectionConfig
 
     /** an array of key managers, if set, will be used while initializing the SSL context */
     private KeyManager[] keyManagers;
-    
+
     /** an instance of SecureRandom, if set, will be used while initializing the SSL context */
     private SecureRandom secureRandom;
-    
+
     /** an array of certificate trust managers, if set, will be used while initializing the SSL context */
     private TrustManager[] trustManagers;
 
     /** name of the protocol used for creating SSL context, default value is "TLS" */
     private String sslProtocol = DEFAULT_SSL_PROTOCOL;
-    
+
+
+    /**
+     * Checks if SSL (ldaps://) is used.
+     *
+     * @return true, if SSL is used
+     */
     public boolean isUseSsl()
     {
         return useSsl;
     }
 
 
+    /**
+     * Sets whether SSL should be used.
+     *
+     * @param useSsl true to use SSL
+     */
     public void setUseSsl( boolean useSsl )
     {
         this.useSsl = useSsl;
     }
 
 
+    /**
+     * Gets the LDAP port.
+     *
+     * @return the LDAP port
+     */
     public int getLdapPort()
     {
         return ldapPort;
     }
 
 
+    /**
+     * Sets the LDAP port.
+     *
+     * @param ldapPort the new LDAP port
+     */
     public void setLdapPort( int ldapPort )
     {
         this.ldapPort = ldapPort;
     }
 
 
+    /**
+     * Gets the LDAP host.
+     *
+     * @return the LDAP host
+     */
     public String getLdapHost()
     {
         return ldapHost;
     }
 
 
+    /**
+     * Sets the LDAP host.
+     *
+     * @param ldapHost the new LDAP host
+     */
     public void setLdapHost( String ldapHost )
     {
         this.ldapHost = ldapHost;
     }
 
 
+    /**
+     * Gets the name that is used to authenticate the user.
+     *
+     * @return the name
+     */
     public String getName()
     {
         return name;
     }
 
 
+    /**
+     * Sets the name which is used to authenticate the user.
+     *
+     * @param name the new name
+     */
     public void setName( String name )
     {
         this.name = name;
     }
 
 
+    /**
+     * Gets the credentials.
+     *
+     * @return the credentials
+     */
     public String getCredentials()
     {
         return credentials;
     }
 
 
+    /**
+     * Sets the credentials.
+     *
+     * @param credentials the new credentials
+     */
     public void setCredentials( String credentials )
     {
         this.credentials = credentials;
     }
 
 
+    /**
+     * Gets the default LDAP port.
+     *
+     * @return the default LDAP port
+     */
     public int getDefaultLdapPort()
     {
         return DEFAULT_LDAP_PORT;
     }
 
 
+    /**
+     * Gets the default LDAPS port.
+     *
+     * @return the default LDAPS port
+     */
     public int getDefaultLdapsPort()
     {
         return DEFAULT_LDAPS_PORT;
     }
 
 
+    /**
+     * Gets the default LDAP host.
+     *
+     * @return the default LDAP host
+     */
     public String getDefaultLdapHost()
     {
         return DEFAULT_LDAP_HOST;
     }
 
 
+    /**
+     * Gets the default timeout.
+     *
+     * @return the default timeout
+     */
     public long getDefaultTimeout()
     {
         return DEFAULT_TIMEOUT;
     }
 
 
+    /**
+     * Gets the supported LDAP version.
+     *
+     * @return the supported LDAP version
+     */
     public int getSupportedLdapVersion()
     {
         return LDAP_V3;
     }
 
 
+    /**
+     * Gets the trust managers.
+     *
+     * @return the trust managers
+     */
     public TrustManager[] getTrustManagers()
     {
         return trustManagers;
     }
 
 
+    /**
+     * Sets the trust managers.
+     *
+     * @param trustManagers the new trust managers
+     */
     public void setTrustManagers( TrustManager... trustManagers )
     {
         this.trustManagers = trustManagers;
     }
 
 
+    /**
+     * Gets the SSL protocol.
+     *
+     * @return the SSL protocol
+     */
     public String getSslProtocol()
     {
         return sslProtocol;
     }
 
 
+    /**
+     * Sets the SSL protocol.
+     *
+     * @param sslProtocol the new SSL protocol
+     */
     public void setSslProtocol( String sslProtocol )
     {
         this.sslProtocol = sslProtocol;
     }
 
 
+    /**
+     * Gets the key managers.
+     *
+     * @return the key managers
+     */
     public KeyManager[] getKeyManagers()
     {
         return keyManagers;
     }
 
 
+    /**
+     * Sets the key managers.
+     *
+     * @param keyManagers the new key managers
+     */
     public void setKeyManagers( KeyManager[] keyManagers )
     {
         this.keyManagers = keyManagers;
     }
 
 
+    /**
+     * Gets the secure random.
+     *
+     * @return the secure random
+     */
     public SecureRandom getSecureRandom()
     {
         return secureRandom;
     }
 
 
+    /**
+     * Sets the secure random.
+     *
+     * @param secureRandom the new secure random
+     */
     public void setSecureRandom( SecureRandom secureRandom )
     {
         this.secureRandom = secureRandom;
     }
-    
+
 }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionFactory.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionFactory.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionFactory.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionFactory.java Mon Sep 27 08:29:26 2010
@@ -20,14 +20,27 @@
 
 package org.apache.directory.ldap.client.api;
 
+
 /**
- * A LdapConnection factory
+ * A LdapConnection factory.
  *  
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class LdapConnectionFactory
+public final class LdapConnectionFactory
 {
+
+    /**
+     * Private constructor.
+     *
+     */
+    private LdapConnectionFactory()
+    {
+    }
+
+
     /**
+     * Gets the core session connection.
+     *
      * @return a connection based on the the CoreSession
      */
     public static LdapConnection getCoreSessionConnection()
@@ -37,14 +50,18 @@ public class LdapConnectionFactory
             Class<?> cl = Class.forName( "org.apache.directory.server.core.LdapCoreSessionConnection" );
             return ( LdapConnection ) cl.newInstance();
         }
-        catch( Exception e )
+        catch ( Exception e )
         {
             throw new RuntimeException( e );
         }
     }
-    
-    
+
+
     /**
+     * Gets the network connection.
+     *
+     * @param host the host
+     * @param port the port
      * @return the LdapNetworkConnection
      */
     public static LdapAsyncConnection getNetworkConnection( String host, int port )
@@ -52,14 +69,14 @@ public class LdapConnectionFactory
         try
         {
             Class<?> cl = Class.forName( "org.apache.directory.ldap.client.api.LdapNetworkConnection" );
-            
+
             LdapAsyncConnection networkConnection = ( LdapAsyncConnection ) cl.newInstance();
             networkConnection.getConfig().setLdapHost( host );
             networkConnection.getConfig().setLdapPort( port );
-            
+
             return networkConnection;
         }
-        catch( Exception e )
+        catch ( Exception e )
         {
             throw new RuntimeException( e );
         }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionPool.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionPool.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionPool.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapConnectionPool.java Mon Sep 27 08:29:26 2010
@@ -28,44 +28,49 @@ import org.apache.commons.pool.impl.Gene
  * A pool implementation for LdapConnection objects.
  * 
  * This class is just a wrapper around the commons GenericObjectPool, and has 
- * a more meaningful name to represent the pool type
+ * a more meaningful name to represent the pool type.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class LdapConnectionPool extends GenericObjectPool
 {
-    /** the LdapConnection factory*/
-    private PoolableLdapConnectionFactory factory;
-
 
+    /**
+     * Instantiates a new LDAP connection pool.
+     */
     public LdapConnectionPool()
     {
         super();
     }
 
 
+    /**
+     * Instantiates a new LDAP connection pool.
+     *
+     * @param factory the LDAP connection factory
+     */
     public LdapConnectionPool( PoolableLdapConnectionFactory factory )
     {
         super( factory );
-        this.factory = factory;
     }
 
 
     /**
-     * @see org.apache.commons.pool.impl.GenericObjectPool#setFactory(PoolableObjectFactory factory)
+     * Sets the LDAP connection factory.
+     *
+     * @param factory the new LDAP connection factory
      */
     public void setFactory( PoolableLdapConnectionFactory factory )
     {
-        this.factory = factory;
         super.setFactory( factory );
     }
 
 
     /**
-     * gives a LdapConnection fetched from the pool 
+     * Gives a LdapConnection fetched from the pool.
      *
      * @return an LdapConnection object from pool 
-     * @throws Exception
+     * @throws Exception if an error occurs while obtaining a connection from the factory
      */
     public LdapNetworkConnection getConnection() throws Exception
     {
@@ -74,14 +79,14 @@ public class LdapConnectionPool extends 
 
 
     /**
-     * places the given LdapConnection back in the pool
+     * Places the given LdapConnection back in the pool.
      *  
      * @param connection the LdapConnection to be released
-     * @throws Exception
+     * @throws Exception if an error occurs while releasing the connection
      */
     public void releaseConnection( LdapNetworkConnection connection ) throws Exception
     {
         super.returnObject( connection );
     }
-    
+
 }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java Mon Sep 27 08:29:26 2010
@@ -1124,31 +1124,36 @@ public class LdapNetworkConnection exten
 
 
     /**
-     * @see #bindCramMd5(String, byte[], String)
+     * Bind using CRAM-MD5 SASL mechanism.
+     *
+     * @param name the DN of the user
+     * @param credentials password of the user
+     * @param authzId the authorization ID (can be null)
+     * @return response of the bind operation
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
+     * @see #bindCramMd5(String, byte[], String, Control...)
      */
     public BindResponse bindCramMd5( String name, String credentials, String authzId )
-        throws LdapException,
-        IOException
+        throws LdapException, IOException
     {
         return bindCramMd5( name, StringTools.getBytesUtf8( credentials ), authzId );
     }
 
 
     /**
-     * 
-     * bind using CRAM-MD5 SASL mechanism.
+     * Bind using CRAM-MD5 SASL mechanism.
      *
      * @param name the DN of the user
      * @param credentials password of the user
      * @param authzId the authorization ID (can be null)
      * @param ctrls controls to be sent with the bind request
      * @return response of the bind operation
-     * @throws LdapException
-     * @throws IOException
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      */
     public BindResponse bindCramMd5( String name, byte[] credentials, String authzId, Control... ctrls )
-        throws LdapException,
-        IOException
+        throws LdapException, IOException
     {
         BindFuture bindFuture = bindSasl( name, credentials, SupportedSaslMechanisms.CRAM_MD5, authzId, null, ctrls );
 
@@ -1169,43 +1174,55 @@ public class LdapNetworkConnection exten
 
 
     /**
+     * Bind using CRAM-MD5 SASL mechanism.
+     *
+     * @param name the DN of the user
+     * @param credentials password of the user
+     * @param authzId the authorization ID (can be null)
+     * @return response of the bind operation
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      * @see #bindCramMd5(String, byte[], String, Control...)
      */
     public BindResponse bindCramMd5( String name, byte[] credentials, String authzId )
-        throws LdapException,
-        IOException
+        throws LdapException, IOException
     {
         return bindCramMd5( name, credentials, authzId, new Control[0] );
     }
 
 
     /**
-     * @see #bindCramMd5(String, byte[], String)
+     * Bind using DIGEST-MD5 SASL mechanism.
+     *
+     * @param name the DN of the user
+     * @param credentials password of the user
+     * @param authzId the authorization ID (can be null)
+     * @param realmName the SASL realm name to be used
+     * @return response of the bind operation
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      */
     public BindResponse bindDigestMd5( String name, String credentials, String authzId, String realmName )
-        throws LdapException,
-        IOException
+        throws LdapException, IOException
     {
         return bindDigestMd5( name, StringTools.getBytesUtf8( credentials ), authzId, realmName );
     }
 
 
     /**
-     * 
-     * bind using DIGEST-MD5 SASL mechanism.
+     * Bind using DIGEST-MD5 SASL mechanism.
      *
      * @param name the DN of the user
      * @param credentials password of the user
      * @param authzId the authorization ID (can be null)
      * @param realmName the SASL realm name to be used
+     * @param ctrls the LDAP controls to be used
      * @return response of the bind operation
-     * @throws LdapException
-     * @throws IOException
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      */
     public BindResponse bindDigestMd5( String name, byte[] credentials, String authzId, String realmName,
-        Control... ctrls )
-        throws LdapException,
-        IOException
+        Control... ctrls ) throws LdapException, IOException
     {
         BindFuture bindFuture = bindSasl( name, credentials, SupportedSaslMechanisms.DIGEST_MD5, authzId, realmName,
             ctrls );
@@ -1227,17 +1244,36 @@ public class LdapNetworkConnection exten
 
 
     /**
+     * Bind using DIGEST-MD5 SASL mechanism.
+     *
+     * @param name the DN of the user
+     * @param credentials password of the user
+     * @param authzId the authorization ID (can be null)
+     * @param realmName the SASL realm name to be used
+     * @return response of the bind operation
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      * @see #bindDigestMd5(String, byte[], String, String, Control...)
      */
     public BindResponse bindDigestMd5( String name, byte[] credentials, String authzId, String realmName )
-        throws LdapException,
-        IOException
+        throws LdapException, IOException
     {
         return bindDigestMd5( name, credentials, authzId, realmName, new Control[0] );
     }
 
 
     /**
+     * Bind to the LDAP server using GSSAPI SASL mechanism.
+     *
+     * @param name the DN of the user entry
+     * @param credentials the credentials of the user
+     * @param realmName name of the kerberos realm in which the given user entry is present
+     * @param kdcHost the host name of the KDC server
+     * @param kdcPort the port of the KDC server
+     * @param ctrls controls to be passed along with the bind request
+     * @return response of this bind operation
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      * @see #bindGssApi(String, byte[], String, String, int, Control...)
      */
     public BindResponse bindGssApi( String name, String credentials, String realmName, String kdcHost, int kdcPort, Control... ctrls )
@@ -1248,7 +1284,7 @@ public class LdapNetworkConnection exten
     
     
     /**
-     * bind to the ldap server using GSSAPI sasl mechanism
+     * Bind to the LDAP server using GSSAPI SASL mechanism.
      *
      * @param name the DN of the user entry
      * @param credentials the credentials of the user
@@ -1257,8 +1293,8 @@ public class LdapNetworkConnection exten
      * @param kdcPort the port of the KDC server
      * @param ctrls controls to be passed along with the bind request
      * @return response of this bind operation
-     * @throws LdapException
-     * @throws IOException
+     * @throws LdapException if an LDAP error occurred during bind
+     * @throws IOException if an IO exception occurred
      */
     public BindResponse bindGssApi( String name, byte[] credentials, String realmName, String kdcHost, int kdcPort, Control... ctrls )
         throws LdapException, IOException
@@ -1839,6 +1875,8 @@ public class LdapNetworkConnection exten
 
                 break;
 
+            default:
+                throw new IllegalStateException( "Unexpected response type " + response.getType() );
         }
     }
 
@@ -2153,9 +2191,7 @@ public class LdapNetworkConnection exten
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted
-     *
-     * @see #moveAndRename(DN, DN, boolean)
+     * {@inheritDoc}
      */
     public ModifyDnResponse moveAndRename( DN entryDn, DN newDn ) throws LdapException
     {
@@ -2164,9 +2200,7 @@ public class LdapNetworkConnection exten
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted
-     *
-     * @see #moveAndRename(DN, DN, boolean)
+     * {@inheritDoc}
      */
     public ModifyDnResponse moveAndRename( String entryDn, String newDn ) throws LdapException
     {
@@ -2175,11 +2209,7 @@ public class LdapNetworkConnection exten
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted if requested
-     *
-     * @param entryDn The original entry DN
-     * @param newDn The new Entry DN
-     * @param deleteOldRdn Tells if the old RDN must be removed
+     * {@inheritDoc}
      */
     public ModifyDnResponse moveAndRename( DN entryDn, DN newDn, boolean deleteOldRdn ) throws LdapException
     {
@@ -2216,11 +2246,7 @@ public class LdapNetworkConnection exten
 
 
     /**
-     * Moves and renames the given entryDn.The old RDN will be deleted if requested
-     *
-     * @param entryDn The original entry DN
-     * @param newDn The new Entry DN
-     * @param deleteOldRdn Tells if the old RDN must be removed
+     * {@inheritDoc}
      */
     public ModifyDnResponse moveAndRename( String entryDn, String newDn, boolean deleteOldRdn ) throws LdapException
     {
@@ -3145,7 +3171,7 @@ public class LdapNetworkConnection exten
      * and adds all the SchemaObjects present in it to the SchemaManager
      *
      * @param schemaFile the schema file in OpenLDAP schema format
-     * @throws LdapException incase of any errors while parsing
+     * @throws LdapException in case of any errors while parsing
      */
     public void addSchema( File schemaFile ) throws LdapException
     {
@@ -3306,17 +3332,25 @@ public class LdapNetworkConnection exten
     }
 
 
-    public void addConnectionClosedEventListener( ConnectionClosedEventListener ccListenr )
+    /**
+     * Adds the connection closed event listener.
+     *
+     * @param ccListener the connection closed listener
+     */
+    public void addConnectionClosedEventListener( ConnectionClosedEventListener ccListener )
     {
         if ( conCloseListeners == null )
         {
             conCloseListeners = new ArrayList<ConnectionClosedEventListener>();
         }
 
-        conCloseListeners.add( ccListenr );
+        conCloseListeners.add( ccListener );
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     @Override
     public void sessionClosed( IoSession session ) throws Exception
     {
@@ -3351,7 +3385,7 @@ public class LdapNetworkConnection exten
 
 
     /**
-     * sends the StartTLS extended request to server and adds a security layer
+     * Sends the StartTLS extended request to server and adds a security layer
      * upon receiving a response with successful result
      *
      * @throws LdapException
@@ -3650,7 +3684,7 @@ public class LdapNetworkConnection exten
             .append( kdcHost )
             .append( ":" )
             .append( kdcPort )
-            .append( "\n\t}\n" );;
+            .append( "\n\t}\n" );
 
         File krb5Conf = File.createTempFile( "client-api-krb5", ".conf" );
         krb5Conf.deleteOnExit();

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NetworkSchemaLoader.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NetworkSchemaLoader.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NetworkSchemaLoader.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NetworkSchemaLoader.java Mon Sep 27 08:29:26 2010
@@ -48,18 +48,20 @@ public class NetworkSchemaLoader extends
     /** the connection to the ldap server */
     private LdapConnection connection;
 
+    /** the schema base DN */
     private static final String SCHEMA_BASE = "ou=schema";
 
+    /** the search filter */
     private static final String FILTER = "(objectClass=*)";
 
+    /** the logger */
     private static final Logger LOG = LoggerFactory.getLogger( NetworkSchemaLoader.class );
 
 
     /**
-     * 
      * Creates a new instance of NetworkSchemaLoader.
      *
-     * @param connection
+     * @param connection the LDAP connection
      * @throws Exception if the connection is not authenticated or if there are any problems
      *                   while loading the schema entries
      */

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NoVerificationTrustManager.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NoVerificationTrustManager.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NoVerificationTrustManager.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/NoVerificationTrustManager.java Mon Sep 27 08:29:26 2010
@@ -38,21 +38,31 @@ import org.slf4j.LoggerFactory;
 public class NoVerificationTrustManager implements X509TrustManager
 {
 
+    /** The logger. */
     private static final Logger LOG = LoggerFactory.getLogger( NoVerificationTrustManager.class );
 
 
+    /**
+     * {@inheritDoc}
+     */
     public void checkClientTrusted( X509Certificate[] x509Certificates, String s ) throws CertificateException
     {
         LOG.debug( "checkClientTrusted {}", x509Certificates[0] );
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public void checkServerTrusted( X509Certificate[] x509Certificates, String s ) throws CertificateException
     {
         LOG.debug( "checkServerTrusted {}", x509Certificates[0] );
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public X509Certificate[] getAcceptedIssuers()
     {
         return new X509Certificate[0];

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/PoolableLdapConnectionFactory.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/PoolableLdapConnectionFactory.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/PoolableLdapConnectionFactory.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/PoolableLdapConnectionFactory.java Mon Sep 27 08:29:26 2010
@@ -37,6 +37,7 @@ public class PoolableLdapConnectionFacto
     /** configuration object for the connection */
     private LdapConnectionConfig config;
 
+    /** the logger */
     private static final Logger LOG = LoggerFactory.getLogger( PoolableLdapConnectionFactory.class );
 
 

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/SearchCursor.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/SearchCursor.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/SearchCursor.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/SearchCursor.java Mon Sep 27 08:29:26 2010
@@ -38,7 +38,7 @@ import org.apache.directory.shared.ldap.
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class SearchCursor extends AbstractCursor
+public class SearchCursor extends AbstractCursor<Response>
 {
 
     /** the search future */
@@ -53,12 +53,20 @@ public class SearchCursor extends Abstra
     /** a reference to hold the retrieved SearchResponse object from SearchFuture */
     private Response response;
 
+    /** the done flag */
     private boolean done;
 
     /** a reference to hold the SearchResultDone response */
     private SearchResultDone searchDoneResp;
 
 
+    /**
+     * Instantiates a new search cursor.
+     *
+     * @param future the future
+     * @param timeout the timeout
+     * @param timeUnit the time unit
+     */
     public SearchCursor( SearchFuture future, long timeout, TimeUnit timeUnit )
     {
         this.future = future;
@@ -67,6 +75,9 @@ public class SearchCursor extends Abstra
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public boolean next() throws Exception
     {
         if ( done )
@@ -121,6 +132,9 @@ public class SearchCursor extends Abstra
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public Response get() throws Exception
     {
         if ( !available() )
@@ -143,18 +157,27 @@ public class SearchCursor extends Abstra
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public boolean isElementReused()
     {
         return true;
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public boolean available()
     {
         return response != null;
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     @Override
     public void close() throws Exception
     {
@@ -162,6 +185,9 @@ public class SearchCursor extends Abstra
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     @Override
     public void close( Exception cause ) throws Exception
     {
@@ -188,42 +214,71 @@ public class SearchCursor extends Abstra
 
 
     // rest of all operations will throw UnsupportedOperationException
-    public void after( Object element ) throws Exception
+
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
+    public void after( Response element ) throws Exception
     {
         throw new UnsupportedOperationException();
     }
 
 
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
     public void afterLast() throws Exception
     {
         throw new UnsupportedOperationException();
     }
 
 
-    public void before( Object element ) throws Exception
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
+    public void before( Response element ) throws Exception
     {
         throw new UnsupportedOperationException();
     }
 
 
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
     public void beforeFirst() throws Exception
     {
         throw new UnsupportedOperationException();
     }
 
 
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
     public boolean first() throws Exception
     {
         throw new UnsupportedOperationException();
     }
 
 
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
     public boolean last() throws Exception
     {
         throw new UnsupportedOperationException();
     }
 
 
+    /**
+     * This operation is not supported in SearchCursor.
+     * {@inheritDoc}
+     */
     public boolean previous() throws Exception
     {
         throw new UnsupportedOperationException();

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/callback/SaslCallbackHandler.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/callback/SaslCallbackHandler.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/callback/SaslCallbackHandler.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/callback/SaslCallbackHandler.java Mon Sep 27 08:29:26 2010
@@ -44,16 +44,27 @@ import org.slf4j.LoggerFactory;
 public class SaslCallbackHandler implements CallbackHandler
 {
 
+    /** The sasl request. */
     private SaslRequest saslReq;
 
+    /** The logger. */
     private static final Logger LOG = LoggerFactory.getLogger( SaslCallbackHandler.class );
-    
+
+
+    /**
+     * Instantiates a new SASL callback handler.
+     *
+     * @param saslReq the SASL request
+     */
     public SaslCallbackHandler( SaslRequest saslReq )
     {
         this.saslReq = saslReq;
     }
 
 
+    /**
+     * {@inheritDoc}
+     */
     public void handle( Callback[] callbacks ) throws IOException, UnsupportedCallbackException
     {
         for ( Callback cb : callbacks )
@@ -61,10 +72,10 @@ public class SaslCallbackHandler impleme
             if ( cb instanceof NameCallback )
             {
                 NameCallback ncb = ( NameCallback ) cb;
-                
+
                 String name = saslReq.getBindRequest().getName().getRdn().getUpValue().getString();
                 LOG.debug( "sending name {} in the NameCallback", name );
-                
+
                 ncb.setName( name );
             }
 
@@ -74,19 +85,21 @@ public class SaslCallbackHandler impleme
                 LOG.debug( "sending credentials in the PasswordCallback" );
                 pcb.setPassword( StringTools.utf8ToString( saslReq.getCredentials() ).toCharArray() );
             }
-            
-            else if( cb instanceof RealmCallback )
+
+            else if ( cb instanceof RealmCallback )
             {
                 RealmCallback rcb = ( RealmCallback ) cb;
-                
-                if( saslReq.getRealmName() != null )
+
+                if ( saslReq.getRealmName() != null )
                 {
                     LOG.debug( "sending the user specified realm value {} in the RealmCallback", saslReq.getRealmName() );
                     rcb.setText( saslReq.getRealmName() );
                 }
                 else
                 {
-                    LOG.debug( "No user specified relam value, sending the default realm value {} in the RealmCallback", rcb.getDefaultText() );
+                    LOG.debug(
+                        "No user specified relam value, sending the default realm value {} in the RealmCallback",
+                        rcb.getDefaultText() );
                     rcb.setText( rcb.getDefaultText() );
                 }
             }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/exception/InvalidConnectionException.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/exception/InvalidConnectionException.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/exception/InvalidConnectionException.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/exception/InvalidConnectionException.java Mon Sep 27 08:29:26 2010
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.ldap.client.api.exception;
 
+
 import org.apache.directory.shared.ldap.exception.LdapException;
 
 
@@ -29,16 +30,25 @@ import org.apache.directory.shared.ldap.
  */
 public class InvalidConnectionException extends LdapException
 {
+    /** The serialVersionUID. */
     static final long serialVersionUID = 1L;
 
 
+    /**
+     * Instantiates a new invalid connection exception.
+     */
     public InvalidConnectionException()
     {
         super();
     }
 
 
-    public InvalidConnectionException(String explanation)
+    /**
+     * Instantiates a new invalid connection exception.
+     *
+     * @param explanation the explanation
+     */
+    public InvalidConnectionException( String explanation )
     {
         super( explanation );
     }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/future/ResponseFuture.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/future/ResponseFuture.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/future/ResponseFuture.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/future/ResponseFuture.java Mon Sep 27 08:29:26 2010
@@ -34,6 +34,7 @@ import org.apache.directory.ldap.client.
 /**
  * A Future implementation used in LdapConnection operations.
  *
+ * @param <R> The result type returned by this Future's <tt>get</tt> method
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class ResponseFuture<R> implements Future<R>
@@ -141,7 +142,9 @@ public class ResponseFuture<R> implement
 
 
     /**
-     * This operation is not supported in this implementation of Future
+     * This operation is not supported in this implementation of Future.
+     * 
+     * {@inheritDoc}
      */
     public boolean isDone()
     {
@@ -167,6 +170,7 @@ public class ResponseFuture<R> implement
     }
 
 
+    @Override
     public String toString()
     {
         StringBuilder sb = new StringBuilder();

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/AddListener.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/AddListener.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/AddListener.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/AddListener.java Mon Sep 27 08:29:26 2010
@@ -40,5 +40,5 @@ public interface AddListener extends Ope
      * @param response the add operation's response
      * @throws LdapException
      */
-    public void entryAdded( LdapAsyncConnection connection, AddResponse response ) throws LdapException;
+    void entryAdded( LdapAsyncConnection connection, AddResponse response ) throws LdapException;
 }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/CompareListener.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/CompareListener.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/CompareListener.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/CompareListener.java Mon Sep 27 08:29:26 2010
@@ -40,6 +40,6 @@ public interface CompareListener extends
      * @param response the compare operation's response
      * @throws LdapException
      */
-    public void attributeCompared( LdapAsyncConnection connection, CompareResponse response )
+    void attributeCompared( LdapAsyncConnection connection, CompareResponse response )
         throws LdapException;
 }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/DeleteListener.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/DeleteListener.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/DeleteListener.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/DeleteListener.java Mon Sep 27 08:29:26 2010
@@ -40,5 +40,5 @@ public interface DeleteListener extends 
      * @param response the delete operation's response
      * @throws LdapException
      */
-    public void entryDeleted( LdapAsyncConnection connection, DeleteResponse response ) throws LdapException;
+    void entryDeleted( LdapAsyncConnection connection, DeleteResponse response ) throws LdapException;
 }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ExtendedListener.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ExtendedListener.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ExtendedListener.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ExtendedListener.java Mon Sep 27 08:29:26 2010
@@ -40,6 +40,6 @@ public interface ExtendedListener extend
      * @param response the extended operation's response
      * @throws LdapException
      */
-    public void extendedOperationCompleted( LdapAsyncConnection connection, ExtendedResponse response )
+    void extendedOperationCompleted( LdapAsyncConnection connection, ExtendedResponse response )
         throws LdapException;
 }

Modified: directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ModifyDnListener.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ModifyDnListener.java?rev=1001621&r1=1001620&r2=1001621&view=diff
==============================================================================
--- directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ModifyDnListener.java (original)
+++ directory/shared/trunk/ldap-client-api/src/main/java/org/apache/directory/ldap/client/api/listener/ModifyDnListener.java Mon Sep 27 08:29:26 2010
@@ -41,6 +41,6 @@ public interface ModifyDnListener extend
      * @param response the modifyDn operation's response
      * @throws LdapException
      */
-    public void modifyDnCompleted( LdapAsyncConnection connection, ModifyDnResponse response )
+    void modifyDnCompleted( LdapAsyncConnection connection, ModifyDnResponse response )
         throws LdapException;
 }