directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r411683 - /directory/branches/shared/optimization/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
Date Mon, 05 Jun 2006 05:57:23 GMT
Author: akarasulu
Date: Sun Jun  4 22:57:22 2006
New Revision: 411683

URL: http://svn.apache.org/viewvc?rev=411683&view=rev
Log:
adding additional constructor to be used for converting a Name to an LdapName

Modified:
    directory/branches/shared/optimization/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java

Modified: directory/branches/shared/optimization/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
URL: http://svn.apache.org/viewvc/directory/branches/shared/optimization/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java?rev=411683&r1=411682&r2=411683&view=diff
==============================================================================
--- directory/branches/shared/optimization/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
(original)
+++ directory/branches/shared/optimization/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
Sun Jun  4 22:57:22 2006
@@ -108,11 +108,30 @@
 
 
     /**
+     * Transduces, or copies a Name to an LdapDN.
+     *
+     * @param name composed of String name components.
+     */
+    public LdapDN( Name name ) throws InvalidNameException
+    {
+        super();
+
+        if ( ( name != null ) && ( name.size() != 0 ) )
+        {
+            for ( int ii = 0; ii < name.size(); ii++ )
+            {
+                String nameComponent = ( String ) name.get( ii );
+                add( 0, nameComponent );
+            }
+        }
+    }
+
+
+    /**
      * Creates an ldap name using a list of NameComponents. Each NameComponent
      * is a String
      * 
-     * @param a_list
-     *            of String name components.
+     * @param list of String name components.
      */
     LdapDN(List list) throws InvalidNameException
     {



Mime
View raw message