From 32034d853f3a284424ccfa87b6de210f1ca814e1 Mon Sep 17 00:00:00 2001
From: Matthew Swift <matthew.swift@forgerock.com>
Date: Tue, 29 Nov 2011 00:31:21 +0000
Subject: [PATCH] Fix OPENDJ-43 (Synchronous Connection decorator implementations should not use AsynchronousConnections) and OPENDJ-328 (Make it easier to implement connection decorators).

---
 opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/ConnectionFactory.java |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/ConnectionFactory.java b/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/ConnectionFactory.java
index 292fd69..c729819 100644
--- a/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/ConnectionFactory.java
+++ b/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/ConnectionFactory.java
@@ -23,6 +23,7 @@
  *
  *
  *      Copyright 2009-2010 Sun Microsystems, Inc.
+ *      Portions copyright 2011 ForgeRock AS.
  */
 
 package org.forgerock.opendj.ldap;
@@ -54,19 +55,19 @@
 public interface ConnectionFactory
 {
   /**
-   * Initiates an asynchronous connection request to the Directory Server
-   * associated with this connection factory. The returned {@code FutureResult}
-   * can be used to retrieve the completed asynchronous connection.
-   * Alternatively, if a {@code ResultHandler} is provided, the handler will be
-   * notified when the connection is available and ready for use.
+   * Asynchronously obtains a connection to the Directory Server associated with
+   * this connection factory. The returned {@code FutureResult} can be used to
+   * retrieve the completed connection. Alternatively, if a
+   * {@code ResultHandler} is provided, the handler will be notified when the
+   * connection is available and ready for use.
    *
    * @param handler
    *          The completion handler, or {@code null} if no handler is to be
    *          used.
-   * @return A future which can be used to retrieve the asynchronous connection.
+   * @return A future which can be used to retrieve the connection.
    */
-  FutureResult<AsynchronousConnection> getAsynchronousConnection(
-      ResultHandler<? super AsynchronousConnection> handler);
+  FutureResult<Connection> getConnectionAsync(
+      ResultHandler<? super Connection> handler);
 
 
 

--
Gitblit v1.10.0