directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r593526 - /directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifUtils.java
Date Fri, 09 Nov 2007 13:59:27 GMT
Author: elecharny
Date: Fri Nov  9 05:59:25 2007
New Revision: 593526

URL: http://svn.apache.org/viewvc?rev=593526&view=rev
Log:
Modified a return type for the reverseModify() method : we now return an Entry, not a String

Modified:
    directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifUtils.java

Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifUtils.java?rev=593526&r1=593525&r2=593526&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifUtils.java
(original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifUtils.java
Fri Nov  9 05:59:25 2007
@@ -557,7 +557,7 @@
      * @return A reversed LDIF 
      * @throws NamingException If something went wrong
      */
-    public static String reverseModify( ModifyRequest modifyRequest, Attributes modifiedEntry
) throws NamingException
+    public static Entry reverseModify( ModifyRequest modifyRequest, Attributes modifiedEntry
) throws NamingException
     {
         Entry entry = new Entry();
         entry.setChangeType( ChangeType.Modify );
@@ -632,7 +632,7 @@
         // Special case if we don't have any reverse modifications
         if ( reverseModifications.size() == 0 )
         {
-            return "";
+            return null;
         }
         
         // Now, push the reversed list into the entry
@@ -641,8 +641,8 @@
             entry.addModificationItem( modification );
         }
         
-        // Return the LDIF generated from this entry.
-        return LdifUtils.convertToLdif( entry );
+        // Return the reverted entry
+        return entry;
     }
 }
 



Mime
View raw message