directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r891985 - /directory/apacheds/branches/apacheds-schema/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SchemaSynchronizer.java
Date Thu, 17 Dec 2009 23:22:29 GMT
Author: elecharny
Date: Thu Dec 17 23:22:29 2009
New Revision: 891985

URL: http://svn.apache.org/viewvc?rev=891985&view=rev
Log:
Uncommented the checkForDependencies method

Modified:
    directory/apacheds/branches/apacheds-schema/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SchemaSynchronizer.java

Modified: directory/apacheds/branches/apacheds-schema/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SchemaSynchronizer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-schema/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SchemaSynchronizer.java?rev=891985&r1=891984&r2=891985&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-schema/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SchemaSynchronizer.java
(original)
+++ directory/apacheds/branches/apacheds-schema/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SchemaSynchronizer.java
Thu Dec 17 23:22:29 2009
@@ -23,6 +23,7 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Map;
 
 import javax.naming.NamingException;
 
@@ -40,6 +41,7 @@
 import org.apache.directory.shared.ldap.entry.EntryAttribute;
 import org.apache.directory.shared.ldap.entry.Modification;
 import org.apache.directory.shared.ldap.entry.ModificationOperation;
+import org.apache.directory.shared.ldap.entry.Value;
 import org.apache.directory.shared.ldap.exception.LdapInvalidNameException;
 import org.apache.directory.shared.ldap.exception.LdapOperationNotSupportedException;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
@@ -55,6 +57,7 @@
 import org.apache.directory.shared.ldap.schema.registries.Registries;
 import org.apache.directory.shared.ldap.schema.registries.Schema;
 import org.apache.directory.shared.ldap.util.DateUtils;
+import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.directory.shared.schema.loader.ldif.SchemaEntityFactory;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -662,7 +665,6 @@
      */
     private void checkForDependencies( boolean isEnabled, ServerEntry entry ) throws Exception
     {
-        /*
         EntryAttribute dependencies = entry.get( this.dependenciesAT );
 
         if ( dependencies == null )
@@ -689,13 +691,11 @@
         }
         else
         {
-            Set<String> allSchemas = schemaManager.getSchemaNames();
-            
             for ( Value<?> value:dependencies )
             {
                 String dependency = value.getString();
                 
-                if ( ! allSchemas.contains( dependency ) )
+                if ( schemaManager.getLoadedSchema( StringTools.toLowerCase( dependency )
) == null )
                 {
                     throw new LdapOperationNotSupportedException( 
                         "Unwilling to perform operation on schema with missing dependencies:
" + dependency, 
@@ -703,7 +703,6 @@
                 }
             }
         }
-        */
     }
 
     



Mime
View raw message