From c01c421b26e6409febd6af1db1c9db11b7b347a4 Mon Sep 17 00:00:00 2001
From: Nicolas Capponi <nicolas.capponi@forgerock.com>
Date: Tue, 07 Jan 2014 15:06:31 +0000
Subject: [PATCH] Align server types API with SDK types API

---
 opendj3-server-dev/src/guitools/org/opends/guitools/controlpanel/ui/DuplicateEntryPanel.java |   22 +++++++++++-----------
 1 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/opendj3-server-dev/src/guitools/org/opends/guitools/controlpanel/ui/DuplicateEntryPanel.java b/opendj3-server-dev/src/guitools/org/opends/guitools/controlpanel/ui/DuplicateEntryPanel.java
index 4701123..5491b5b 100644
--- a/opendj3-server-dev/src/guitools/org/opends/guitools/controlpanel/ui/DuplicateEntryPanel.java
+++ b/opendj3-server-dev/src/guitools/org/opends/guitools/controlpanel/ui/DuplicateEntryPanel.java
@@ -22,7 +22,7 @@
  *
  *
  *      Copyright 2009-2010 Sun Microsystems, Inc.
- *      Portions Copyright 2012 ForgeRock AS
+ *      Portions Copyright 2012-2014 ForgeRock AS
  */
 
 package org.opends.guitools.controlpanel.ui;
@@ -141,16 +141,16 @@
     String aRdn;
     try
     {
-      DN nodeDN = DN.decode(node.getDN());
-      if (nodeDN.isNullDN())
+      DN nodeDN = DN.valueOf(node.getDN());
+      if (nodeDN.isRootDN())
       {
         aParentDN = nodeDN;
         aRdn = "(1)";
       }
       else
       {
-        aParentDN = nodeDN.getParent();
-        aRdn = nodeDN.getRDN().getAttributeValue(0).toString()+"-1";
+        aParentDN = nodeDN.parent();
+        aRdn = nodeDN.rdn().getAttributeValue(0).toString()+"-1";
       }
     }
     catch (DirectoryException de)
@@ -431,8 +431,8 @@
         String newValue = null;
         try
         {
-          DN theDN = DN.decode(dn);
-          newValue = theDN.getRDN().getAttributeValue(0).toString();
+          DN theDN = DN.valueOf(dn);
+          newValue = theDN.rdn().getAttributeValue(0).toString();
         }
         catch (DirectoryException de)
         {
@@ -449,8 +449,8 @@
           String oldValue = null;
           try
           {
-            DN oldDN = DN.decode(entryToDuplicate.getDN());
-            oldValue = oldDN.getRDN().getAttributeValue(0).toString();
+            DN oldDN = DN.valueOf(entryToDuplicate.getDN());
+            oldValue = oldDN.rdn().getAttributeValue(0).toString();
           }
           catch (DirectoryException de)
           {
@@ -533,8 +533,8 @@
           entryToDuplicate = sr;
           try
           {
-            DN dn = DN.decode(sr.getDN());
-            rdnAttribute = dn.getRDN().getAttributeType(0).getNameOrOID();
+            DN dn = DN.valueOf(sr.getDN());
+            rdnAttribute = dn.rdn().getAttributeType(0).getNameOrOID();
 
             updateDNValue();
             Boolean hasPassword = !sr.getAttributeValues(

--
Gitblit v1.10.0