From a7e5e371915be741db2dac2656b779dba93bf9f9 Mon Sep 17 00:00:00 2001
From: Jean-Noël Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Thu, 07 Jul 2016 13:03:33 +0000
Subject: [PATCH] ConnectionWrapper.java: simplified code

---
 opendj-server-legacy/src/main/java/org/opends/admin/ads/util/ConnectionUtils.java |   33 ---------------------------------
 1 files changed, 0 insertions(+), 33 deletions(-)

diff --git a/opendj-server-legacy/src/main/java/org/opends/admin/ads/util/ConnectionUtils.java b/opendj-server-legacy/src/main/java/org/opends/admin/ads/util/ConnectionUtils.java
index 49c23f3..86c219b 100644
--- a/opendj-server-legacy/src/main/java/org/opends/admin/ads/util/ConnectionUtils.java
+++ b/opendj-server-legacy/src/main/java/org/opends/admin/ads/util/ConnectionUtils.java
@@ -359,39 +359,6 @@
   }
 
   /**
-   * Returns the LDAP URL used in the provided InitialLdapContext.
-   * @param ctx the context to analyze.
-   * @return the LDAP URL used in the provided InitialLdapContext.
-   */
-  static String getLdapUrl(InitialLdapContext ctx)
-  {
-    return getEnvProperty(ctx, Context.PROVIDER_URL);
-  }
-
-  private static String getEnvProperty(InitialLdapContext ctx, String property) {
-    try {
-      return (String) ctx.getEnvironment().get(property);
-    } catch (NamingException ne) {
-      // This is really strange.  Seems like a bug somewhere.
-      logger.warn(LocalizableMessage.raw("Naming exception getting environment of " + ctx, ne));
-      return null;
-    }
-  }
-
-  /**
-   * Tells whether we are using StartTLS in the provided InitialLdapContext.
-   * @param ctx the context to analyze.
-   * @return <CODE>true</CODE> if we are using StartTLS and <CODE>false</CODE>
-   * otherwise.
-   */
-  static boolean isStartTLS(InitialLdapContext ctx)
-  {
-    return "true".equalsIgnoreCase(getEnvProperty(ctx, STARTTLS_PROPERTY));
-  }
-
-
-
-  /**
    * Method used to know if we are connected as administrator in a server with a
    * given InitialLdapContext.
    * @param ctx the context.

--
Gitblit v1.10.0