directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r411589 - in /directory/branches/apacheds/optimization: core-unit/src/test/java/org/apache/directory/server/core/authz/ core/src/main/java/org/apache/directory/server/core/ core/src/main/java/org/apache/directory/server/core/authz/ core/src...
Date Sun, 04 Jun 2006 18:54:16 GMT
Author: akarasulu
Date: Sun Jun  4 11:54:15 2006
New Revision: 411589

URL: http://svn.apache.org/viewvc?rev=411589&view=rev
Log:
replacing use of LdapName with LdapDN in various files in core

Modified:
    directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/AddAuthorizationTest.java
    directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/DeleteAuthorizationTest.java
    directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/ModifyAuthorizationTest.java
    directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/MoveRenameAuthorizationTest.java
    directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/SearchAuthorizationTest.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java
    directory/branches/apacheds/optimization/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java

Modified: directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/AddAuthorizationTest.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/AddAuthorizationTest.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/AddAuthorizationTest.java
(original)
+++ directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/AddAuthorizationTest.java
Sun Jun  4 11:54:15 2006
@@ -18,7 +18,7 @@
 
 
 import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 import javax.naming.NamingException;
 import javax.naming.directory.*;
@@ -56,7 +56,7 @@
 
         try
         {
-            LdapName userName = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            LdapDN userName = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             DirContext userContext = getContextAs( userName, password );
             userContext.createSubcontext( entryRdn, testEntry );
 

Modified: directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/DeleteAuthorizationTest.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/DeleteAuthorizationTest.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/DeleteAuthorizationTest.java
(original)
+++ directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/DeleteAuthorizationTest.java
Sun Jun  4 11:54:15 2006
@@ -18,7 +18,7 @@
 
 
 import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 import javax.naming.NamingException;
 import javax.naming.directory.*;
@@ -63,7 +63,7 @@
         try
         {
             // create the entry as the admin
-            LdapName userName = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            LdapDN userName = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             adminContext.createSubcontext( entryRdn, testEntry );
 
             // delete the newly created context as the user

Modified: directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/ModifyAuthorizationTest.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/ModifyAuthorizationTest.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/ModifyAuthorizationTest.java
(original)
+++ directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/ModifyAuthorizationTest.java
Sun Jun  4 11:54:15 2006
@@ -18,7 +18,7 @@
 
 
 import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 import javax.naming.NamingException;
 import javax.naming.NamingEnumeration;
@@ -70,7 +70,7 @@
         try
         {
             // create the entry as admin
-            LdapName userName = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            LdapDN userName = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             adminContext.createSubcontext( entryRdn, testEntry );
 
             // modify the entry as the user
@@ -126,7 +126,7 @@
         try
         {
             // create the entry as admin
-            LdapName userName = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            LdapDN userName = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             adminContext.createSubcontext( entryRdn, testEntry );
 
             // modify the entry as the user
@@ -165,7 +165,7 @@
         try
         {
             // modify the entry as the user
-            Name userEntry = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            Name userEntry = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             DirContext userContext = getContextAs( userEntry, password, userEntry.toString()
);
             userContext.modifyAttributes( "", modOp, mods );
             return true;
@@ -194,7 +194,7 @@
         try
         {
             // modify the entry as the user
-            Name userEntry = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            Name userEntry = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             DirContext userContext = getContextAs( userEntry, password, userEntry.toString()
);
             userContext.modifyAttributes( "", mods );
             return true;

Modified: directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/MoveRenameAuthorizationTest.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/MoveRenameAuthorizationTest.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/MoveRenameAuthorizationTest.java
(original)
+++ directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/MoveRenameAuthorizationTest.java
Sun Jun  4 11:54:15 2006
@@ -18,7 +18,7 @@
 
 
 import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 import javax.naming.NamingException;
 import javax.naming.directory.*;
@@ -62,7 +62,7 @@
             // create the new entry as the admin user
             adminContext.createSubcontext( entryRdn, testEntry );
 
-            LdapName userName = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+            LdapDN userName = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
             DirContext userContext = getContextAs( userName, password );
             userContext.rename( entryRdn, newRdn );
 

Modified: directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/SearchAuthorizationTest.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/SearchAuthorizationTest.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/SearchAuthorizationTest.java
(original)
+++ directory/branches/apacheds/optimization/core-unit/src/test/java/org/apache/directory/server/core/authz/SearchAuthorizationTest.java
Sun Jun  4 11:54:15 2006
@@ -21,7 +21,7 @@
 import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
 import org.apache.directory.shared.ldap.message.LockableAttributeImpl;
 import org.apache.directory.shared.ldap.message.LockableAttributesImpl;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 import javax.naming.NamingException;
 import javax.naming.Name;
@@ -83,7 +83,7 @@
         Name[] childRdns = new Name[children.length];
         for ( int ii = 0; ii < children.length && count[0] < sizeLimit; ii++
)
         {
-            Name childRdn = new LdapName();
+            Name childRdn = new LdapDN();
             childRdn.addAll( parent );
             childRdn.add( "ou=" + ii );
             childRdns[ii] = childRdn;
@@ -138,7 +138,7 @@
         while ( results.hasMore() )
         {
             SearchResult result = ( SearchResult ) results.next();
-            Name childRdn = new LdapName( result.getName() );
+            Name childRdn = new LdapDN( result.getName() );
             childRdn.remove( 0 );
             recursivelyDelete( childRdn );
         }
@@ -215,8 +215,8 @@
             cons = new SearchControls();
         }
 
-        Name base = addSearchData( new LdapName(), 3, 10 );
-        Name userDn = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+        Name base = addSearchData( new LdapDN(), 3, 10 );
+        Name userDn = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
         try
         {
             results.clear();
@@ -259,9 +259,9 @@
             cons = new SearchControls();
         }
 
-        Name base = addSearchData( new LdapName(), 3, 10 );
+        Name base = addSearchData( new LdapDN(), 3, 10 );
         addEntryACI( rdn, aci );
-        Name userDn = new LdapName( "uid=" + uid + ",ou=users,ou=system" );
+        Name userDn = new LdapDN( "uid=" + uid + ",ou=users,ou=system" );
         try
         {
             results.clear();
@@ -296,7 +296,7 @@
      */
     public void testAddSearchData() throws NamingException
     {
-        Name base = addSearchData( new LdapName(), 3, 10 );
+        Name base = addSearchData( new LdapDN(), 3, 10 );
         SearchControls controls = new SearchControls();
         controls.setSearchScope( SearchControls.SUBTREE_SCOPE );
         NamingEnumeration results = sysRoot.search( base, "(objectClass=*)", controls );
@@ -640,7 +640,7 @@
         // try a search operation which should fail without any prescriptive ACI
         SearchControls cons = new SearchControls();
         cons.setSearchScope( SearchControls.SUBTREE_SCOPE );
-        LdapName rdn = new LdapName( "ou=tests" );
+        LdapDN rdn = new LdapDN( "ou=tests" );
         assertFalse( checkSearchAsWithEntryACI( "billyd", "billyd", cons, rdn, aci, 9 ) );
 
         // now add a subentry that enables anyone to search below ou=system
@@ -683,7 +683,7 @@
         // try a search operation which should fail without any prescriptive ACI
         SearchControls cons = new SearchControls();
         cons.setSearchScope( SearchControls.SUBTREE_SCOPE );
-        LdapName rdn = new LdapName( "ou=tests" );
+        LdapDN rdn = new LdapDN( "ou=tests" );
         assertFalse( checkSearchAsWithEntryACI( "billyd", "billyd", cons, rdn, aci, 9 ) );
 
         // now add a subentry that enables anyone to search below ou=system
@@ -728,7 +728,7 @@
      */
     private SearchResult checkCanSearhSubentryAs( String uid, String password, Name rdn )
throws NamingException
     {
-        DirContext userCtx = getContextAs( new LdapName( "uid=" + uid + ",ou=users,ou=system"
), password );
+        DirContext userCtx = getContextAs( new LdapDN( "uid=" + uid + ",ou=users,ou=system"
), password );
         SearchControls cons = new SearchControls();
         cons.setSearchScope( SearchControls.OBJECT_SCOPE );
         SearchResult result = null;
@@ -771,7 +771,7 @@
             + "grantsAndDenials { grantRead, grantReturnDN, grantBrowse } } } } }" );
 
         // check and see if we can access the subentry now
-        assertNotNull( checkCanSearhSubentryAs( "billyd", "billyd", new LdapName( "cn=anybodySearch"
) ) );
+        assertNotNull( checkCanSearhSubentryAs( "billyd", "billyd", new LdapDN( "cn=anybodySearch"
) ) );
 
         // now add a denial to prevent all users except the admin from accessing the subentry
         addSubentryACI( "{ " + "identificationTag \"searchAci\", " + "precedence 14, " +
"authenticationLevel none, "
@@ -780,7 +780,7 @@
             + "grantsAndDenials { denyRead, denyReturnDN, denyBrowse } } } } }" );
 
         // now we should not be able to access the subentry with a search
-        assertNull( checkCanSearhSubentryAs( "billyd", "billyd", new LdapName( "cn=anybodySearch"
) ) );
+        assertNull( checkCanSearhSubentryAs( "billyd", "billyd", new LdapDN( "cn=anybodySearch"
) ) );
     }
 
 
@@ -798,7 +798,7 @@
                 + "grantsAndDenials { grantRead, grantReturnDN, grantBrowse, grantDiscloseOnError
} } } } }" );
 
         // get a context as the user and try a lookup of a non-existant entry under ou=groups,ou=system
-        DirContext userCtx = getContextAs( new LdapName( "uid=billyd,ou=users,ou=system"
), "billyd" );
+        DirContext userCtx = getContextAs( new LdapDN( "uid=billyd,ou=users,ou=system" ),
"billyd" );
         try
         {
             userCtx.lookup( "cn=blah,ou=groups" );

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
(original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
Sun Jun  4 11:54:15 2006
@@ -53,7 +53,7 @@
 import org.apache.directory.shared.ldap.message.LockableAttributesImpl;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.name.DnOidContainer;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.schema.AttributeType;
 import org.apache.directory.shared.ldap.schema.NoOpNormalizer;
 import org.apache.directory.shared.ldap.schema.OidNormalizer;
@@ -455,7 +455,7 @@
         // create system users area
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "ou=users,ou=system" ) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "ou=users,ou=system" ) ) )
         {
             firstStart = true;
 
@@ -469,14 +469,14 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            partitionNexus.add( "ou=users,ou=system", new LdapName( "ou=users,ou=system"
), attributes );
+            partitionNexus.add( "ou=users,ou=system", new LdapDN( "ou=users,ou=system" ),
attributes );
         }
 
         // -------------------------------------------------------------------
         // create system groups area
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "ou=groups,ou=system" ) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "ou=groups,ou=system" ) ) )
         {
             firstStart = true;
 
@@ -490,7 +490,7 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            partitionNexus.add( "ou=groups,ou=system", new LdapName( "ou=groups,ou=system"
), attributes );
+            partitionNexus.add( "ou=groups,ou=system", new LdapDN( "ou=groups,ou=system"
), attributes );
         }
 
         // -------------------------------------------------------------------
@@ -498,7 +498,7 @@
         // -------------------------------------------------------------------
 
         String upName = "cn=Administrators,ou=groups,ou=system";
-        Name normName = new LdapName( "cn=administrators,ou=groups,ou=system" );
+        Name normName = new LdapDN( "cn=administrators,ou=groups,ou=system" );
         if ( !partitionNexus.hasEntry( normName ) )
         {
             firstStart = true;
@@ -522,7 +522,7 @@
         // create system configuration area
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "ou=configuration,ou=system" ) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "ou=configuration,ou=system" ) ) )
         {
             firstStart = true;
 
@@ -536,14 +536,14 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            partitionNexus.add( "ou=configuration,ou=system", new LdapName( "ou=configuration,ou=system"
), attributes );
+            partitionNexus.add( "ou=configuration,ou=system", new LdapDN( "ou=configuration,ou=system"
), attributes );
         }
 
         // -------------------------------------------------------------------
         // create system configuration area for partition information
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "ou=partitions,ou=configuration,ou=system"
) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "ou=partitions,ou=configuration,ou=system"
) ) )
         {
             firstStart = true;
 
@@ -557,7 +557,7 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            partitionNexus.add( "ou=partitions,ou=configuration,ou=system", new LdapName(
+            partitionNexus.add( "ou=partitions,ou=configuration,ou=system", new LdapDN(
                 "ou=partitions,ou=configuration,ou=system" ), attributes );
         }
 
@@ -565,7 +565,7 @@
         // create system configuration area for services
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "ou=services,ou=configuration,ou=system"
) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "ou=services,ou=configuration,ou=system"
) ) )
         {
             firstStart = true;
 
@@ -579,7 +579,7 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            partitionNexus.add( "ou=services,ou=configuration,ou=system", new LdapName(
+            partitionNexus.add( "ou=services,ou=configuration,ou=system", new LdapDN(
                 "ou=services,ou=configuration,ou=system" ), attributes );
         }
 
@@ -587,7 +587,7 @@
         // create system configuration area for interceptors
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "ou=interceptors,ou=configuration,ou=system"
) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "ou=interceptors,ou=configuration,ou=system"
) ) )
         {
             firstStart = true;
 
@@ -601,7 +601,7 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            partitionNexus.add( "ou=interceptors,ou=configuration,ou=system", new LdapName(
+            partitionNexus.add( "ou=interceptors,ou=configuration,ou=system", new LdapDN(
                 "ou=interceptors,ou=configuration,ou=system" ), attributes );
         }
 
@@ -609,7 +609,7 @@
         // create system preferences area
         // -------------------------------------------------------------------
 
-        if ( !partitionNexus.hasEntry( new LdapName( "prefNodeName=sysPrefRoot,ou=system"
) ) )
+        if ( !partitionNexus.hasEntry( new LdapDN( "prefNodeName=sysPrefRoot,ou=system" )
) )
         {
             firstStart = true;
 
@@ -624,7 +624,7 @@
             attributes.put( "creatorsName", DirectoryPartitionNexus.ADMIN_PRINCIPAL );
             attributes.put( "createTimestamp", DateUtils.getGeneralizedTime() );
 
-            LdapName dn = new LdapName( "prefNodeName=sysPrefRoot,ou=system" );
+            LdapDN dn = new LdapDN( "prefNodeName=sysPrefRoot,ou=system" );
 
             partitionNexus.add( "prefNodeName=sysPrefRoot,ou=system", dn, attributes );
         }
@@ -641,7 +641,7 @@
         // Warn if the default password is not changed.
         boolean needToChangeAdminPassword = false;
 
-        Attributes adminEntry = partitionNexus.lookup( new LdapName( DirectoryPartitionNexus.ADMIN_PRINCIPAL
) );
+        Attributes adminEntry = partitionNexus.lookup( new LdapDN( DirectoryPartitionNexus.ADMIN_PRINCIPAL
) );
         Object userPassword = adminEntry.get( "userPassword" ).get();
         if ( userPassword instanceof byte[] )
         {

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java
(original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java
Sun Jun  4 11:54:15 2006
@@ -42,7 +42,7 @@
 import org.apache.directory.shared.ldap.filter.ExprNode;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.name.DnParser;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -168,7 +168,7 @@
         // stuff for dealing with subentries (garbage for now)
         String subschemaSubentry = ( String ) factoryCfg.getPartitionNexus().getRootDSE().get(
"subschemaSubentry" )
             .get();
-        subschemaSubentryDn = new LdapName( subschemaSubentry ).toString().toLowerCase();
+        subschemaSubentryDn = new LdapDN( subschemaSubentry ).toString().toLowerCase();
     }
 
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
(original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
Sun Jun  4 11:54:15 2006
@@ -23,7 +23,7 @@
 import org.apache.directory.shared.ldap.filter.BranchNode;
 import org.apache.directory.shared.ldap.filter.SimpleNode;
 import org.apache.directory.shared.ldap.name.DnParser;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -93,7 +93,7 @@
         while ( suffixes.hasNext() )
         {
             String suffix = ( String ) suffixes.next();
-            Name baseDn = new LdapName( suffix );
+            Name baseDn = new LdapDN( suffix );
             SearchControls ctls = new SearchControls();
             ctls.setSearchScope( SearchControls.SUBTREE_SCOPE );
             NamingEnumeration results = nexus.search( baseDn, env, filter, ctls );
@@ -432,7 +432,7 @@
                     memberGroups = new HashSet();
                 }
 
-                memberGroups.add( new LdapName( group ) );
+                memberGroups.add( new LdapDN( group ) );
             }
         }
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
(original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
Sun Jun  4 11:54:15 2006
@@ -40,7 +40,7 @@
 import org.apache.directory.shared.ldap.filter.SimpleNode;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.name.DnParser;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.name.NameComponentNormalizer;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -104,7 +104,7 @@
         while ( suffixes.hasNext() )
         {
             String suffix = ( String ) suffixes.next();
-            Name baseDn = new LdapName( suffix );
+            Name baseDn = new LdapDN( suffix );
             ExprNode filter = new SimpleNode( OC_ATTR, ACSUBENTRY_OC, SimpleNode.EQUALITY
);
             SearchControls ctls = new SearchControls();
             ctls.setSearchScope( SearchControls.SUBTREE_SCOPE );

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java
(original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java
Sun Jun  4 11:54:15 2006
@@ -31,7 +31,7 @@
 import org.apache.directory.shared.ldap.aci.ACITuple;
 import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
 import org.apache.directory.shared.ldap.aci.UserClass;
-import org.apache.directory.shared.ldap.name.LdapName;
+import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.subtree.SubtreeSpecification;
 
 
@@ -44,7 +44,7 @@
  */
 public class RelatedUserClassFilter implements ACITupleFilter
 {
-    private static final LdapName ROOTDSE_NAME = LdapName.EMPTY_LDAP_NAME;
+    private static final LdapDN ROOTDSE_NAME = LdapDN.EMPTY_LDAPDN;
 
     private final SubtreeEvaluator subtreeEvaluator;
 

Modified: directory/branches/apacheds/optimization/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java?rev=411589&r1=411588&r2=411589&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
(original)
+++ directory/branches/apacheds/optimization/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
Sun Jun  4 11:54:15 2006
@@ -27,7 +27,6 @@
 import org.apache.directory.shared.ldap.filter.FilterParser;
 import org.apache.directory.shared.ldap.filter.FilterParserImpl;
 import org.apache.directory.shared.ldap.name.LdapDN;
-import org.apache.directory.shared.ldap.name.LdapName;
 import org.apache.directory.shared.ldap.subtree.SubtreeSpecification;
 import org.apache.directory.shared.ldap.subtree.SubtreeSpecificationModifier;
 
@@ -86,16 +85,16 @@
     {
         SubtreeSpecificationModifier modifier = new SubtreeSpecificationModifier();
         SubtreeSpecification ss = modifier.getSubtreeSpecification();
-        Name apDn = new LdapName( "ou=system" );
-        Name entryDn = new LdapName( "ou=users,ou=system" );
+        Name apDn = new LdapDN( "ou=system" );
+        Name entryDn = new LdapDN( "ou=users,ou=system" );
         Attribute objectClasses = new BasicAttribute( "objectClass" );
 
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=system" );
+        entryDn = new LdapDN( "ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=abc" );
+        entryDn = new LdapDN( "ou=abc" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
     }
 
@@ -105,16 +104,16 @@
         SubtreeSpecificationModifier modifier = new SubtreeSpecificationModifier();
         modifier.setBase( new LdapDN( "ou=users" ) );
         SubtreeSpecification ss = modifier.getSubtreeSpecification();
-        Name apDn = new LdapName( "ou=system" );
-        Name entryDn = new LdapName( "ou=users,ou=system" );
+        Name apDn = new LdapDN( "ou=system" );
+        Name entryDn = new LdapDN( "ou=users,ou=system" );
         Attribute objectClasses = new BasicAttribute( "objectClass" );
 
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=system" );
+        entryDn = new LdapDN( "ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
     }
 
@@ -126,25 +125,25 @@
         modifier.setMaxBaseDistance( 3 );
         modifier.setBase( new LdapDN( "ou=users" ) );
         SubtreeSpecification ss = modifier.getSubtreeSpecification();
-        Name apDn = new LdapName( "ou=system" );
-        Name entryDn = new LdapName( "ou=users,ou=system" );
+        Name apDn = new LdapDN( "ou=system" );
+        Name entryDn = new LdapDN( "ou=users,ou=system" );
         Attribute objectClasses = new BasicAttribute( "objectClass" );
 
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=system" );
+        entryDn = new LdapDN( "ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
     }
 
@@ -187,32 +186,32 @@
     {
         SubtreeSpecificationModifier modifier = new SubtreeSpecificationModifier();
         Set chopBefore = new HashSet();
-        chopBefore.add( new LdapName( "uid=Tori Amos" ) );
-        chopBefore.add( new LdapName( "ou=threelevels,ou=twolevels,uid=akarasulu" ) );
+        chopBefore.add( new LdapDN( "uid=Tori Amos" ) );
+        chopBefore.add( new LdapDN( "ou=threelevels,ou=twolevels,uid=akarasulu" ) );
         modifier.setChopBeforeExclusions( chopBefore );
         modifier.setMinBaseDistance( 1 );
         modifier.setMaxBaseDistance( 3 );
         modifier.setBase( new LdapDN( "ou=users" ) );
         SubtreeSpecification ss = modifier.getSubtreeSpecification();
-        Name apDn = new LdapName( "ou=system" );
-        Name entryDn = new LdapName( "ou=users,ou=system" );
+        Name apDn = new LdapDN( "ou=system" );
+        Name entryDn = new LdapDN( "ou=users,ou=system" );
         Attribute objectClasses = new BasicAttribute( "objectClass" );
 
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=system" );
+        entryDn = new LdapDN( "ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
     }
 
@@ -228,25 +227,25 @@
         modifier.setMaxBaseDistance( 3 );
         modifier.setBase( new LdapDN( "ou=users" ) );
         SubtreeSpecification ss = modifier.getSubtreeSpecification();
-        Name apDn = new LdapName( "ou=system" );
-        Name entryDn = new LdapName( "ou=users,ou=system" );
+        Name apDn = new LdapDN( "ou=system" );
+        Name entryDn = new LdapDN( "ou=users,ou=system" );
         Attribute objectClasses = new BasicAttribute( "objectClass", "person" );
 
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=system" );
+        entryDn = new LdapDN( "ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertTrue( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
         // now change the refinement so the entry is rejected
@@ -254,19 +253,19 @@
 
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "uid=akarasulu,ou=users,ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=system" );
+        entryDn = new LdapDN( "ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
+        entryDn = new LdapDN( "ou=twolevels,uid=akarasulu,ou=users,ou=system" );
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
-        entryDn = new LdapName( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
+        entryDn = new LdapDN( "ou=fourlevels,ou=threelevels,ou=twolevels,uid=akarasulu,ou=users,ou=system"
);
         assertFalse( evaluator.evaluate( ss, apDn, entryDn, objectClasses ) );
 
     }



Mime
View raw message