directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r519438 - in /directory: apacheds/trunk/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/ apacheds/trunk/constants/src/main/java/org/apache/directory/server/constants/ apacheds/trunk/core/src/main/java/org/ap...
Date Sat, 17 Mar 2007 20:22:19 GMT
Author: elecharny
Date: Sat Mar 17 13:22:18 2007
New Revision: 519438

URL: http://svn.apache.org/viewvc?view=rev&rev=519438
Log:
Removed the "organizationalUnit" from the code (except from tests and antlr files) and replaced
it by 
a reference to the constant declared in the new SchemaConstants class in shared-ldap-constants

Modified:
    directory/apacheds/trunk/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
    directory/apacheds/trunk/constants/src/main/java/org/apache/directory/server/constants/CoreSchemaConstants.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaManager.java
    directory/apacheds/trunk/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
    directory/shared/trunk/ldap-constants/src/main/java/org/apache/directory/shared/ldap/constants/SchemaConstants.java

Modified: directory/apacheds/trunk/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/apacheds/trunk/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
(original)
+++ directory/apacheds/trunk/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
Sat Mar 17 13:22:18 2007
@@ -212,7 +212,7 @@
             {
                 Attributes entry = new AttributesImpl();
                 entry.put( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.TOP_OC );
-                entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( "organizationalUnit" );
+                entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( SchemaConstants.ORGANIZATIONAL_UNIT_OC
);
                 entry.put( CoreSchemaConstants.OU_AT, "schema" );
                 store.add( dn, entry );
             }
@@ -622,7 +622,8 @@
         }
         storeConfig.setIndexedAttributes( indexSet );
 
-        Attributes rootEntry = new AttributesImpl( SchemaConstants.OBJECT_CLASS_AT, "organizationalUnit",
true );
+        Attributes rootEntry = new AttributesImpl( SchemaConstants.OBJECT_CLASS_AT, 
+            SchemaConstants.ORGANIZATIONAL_UNIT_OC, true );
         rootEntry.put( CoreSchemaConstants.OU_AT, "schema" );
         storeConfig.setContextEntry( rootEntry );
 
@@ -774,7 +775,7 @@
 
         Attributes entry = new AttributesImpl();
         entry.put( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.TOP_OC );
-        entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( "organizationalUnit" );
+        entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( SchemaConstants.ORGANIZATIONAL_UNIT_OC
);
         entry.put( CoreSchemaConstants.OU_AT, dn.getRdn().getValue() );
         store.add( dn, entry );
     }

Modified: directory/apacheds/trunk/constants/src/main/java/org/apache/directory/server/constants/CoreSchemaConstants.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/constants/src/main/java/org/apache/directory/server/constants/CoreSchemaConstants.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/apacheds/trunk/constants/src/main/java/org/apache/directory/server/constants/CoreSchemaConstants.java
(original)
+++ directory/apacheds/trunk/constants/src/main/java/org/apache/directory/server/constants/CoreSchemaConstants.java
Sat Mar 17 13:22:18 2007
@@ -31,5 +31,5 @@
     String SCHEMA_NAME = "core";
 
     String OU_AT = "ou";
-    String ORGANIZATIONAL_UNIT_OC = "organizationalUnit";
+    //String ORGANIZATIONAL_UNIT_OC = "organizationalUnit";
 }

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
Sat Mar 17 13:22:18 2007
@@ -491,7 +491,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( "ou", "users" );
@@ -515,7 +515,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( "ou", "groups" );
@@ -584,7 +584,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( "ou", "configuration" );
@@ -608,7 +608,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( "ou", "partitions" );
@@ -632,7 +632,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( "ou", "services" );
@@ -656,7 +656,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( "ou", "interceptors" );
@@ -680,7 +680,7 @@
             Attributes attributes = new AttributesImpl();
             Attribute objectClass = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT );
             objectClass.add( SchemaConstants.TOP_OC );
-            objectClass.add( "organizationalUnit" );
+            objectClass.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             attributes.put( objectClass );
 
             attributes.put( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.EXTENSIBLE_OBJECT_OC
);
@@ -832,7 +832,7 @@
         
         Attributes entry = new AttributesImpl();
         entry.put( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.TOP_OC );
-        entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( "organizationalUnit" );
+        entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( SchemaConstants.ORGANIZATIONAL_UNIT_OC
);
         entry.put( "ou", "schema" );
         schemaPartitionConfig.setContextEntry( entry );
         JdbmPartition schemaPartition = new JdbmPartition();

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
Sat Mar 17 13:22:18 2007
@@ -261,7 +261,7 @@
                 systemEntry.put( objectClassAttr );
             }
             objectClassAttr.add( SchemaConstants.TOP_OC );
-            objectClassAttr.add( "organizationalUnit" );
+            objectClassAttr.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             objectClassAttr.add( SchemaConstants.EXTENSIBLE_OBJECT_OC );
             systemEntry.put( "creatorsName", PartitionNexus.ADMIN_PRINCIPAL );
             systemEntry.put( "createTimestamp", DateUtils.getGeneralizedTime() );
@@ -357,7 +357,7 @@
             Attributes systemEntry = new AttributesImpl();
             Attribute objectClassAttr = new AttributeImpl( SchemaConstants.OBJECT_CLASS_AT
);
             objectClassAttr.add( SchemaConstants.TOP_OC );
-            objectClassAttr.add( "organizationalUnit" );
+            objectClassAttr.add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
             objectClassAttr.add( SchemaConstants.EXTENSIBLE_OBJECT_OC );
             systemEntry.put( objectClassAttr );
             systemEntry.put( "creatorsName", PartitionNexus.ADMIN_PRINCIPAL );

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaManager.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaManager.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaManager.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/schema/SchemaManager.java
Sat Mar 17 13:22:18 2007
@@ -34,7 +34,6 @@
 import javax.naming.directory.DirContext;
 
 import org.apache.directory.server.constants.ApacheSchemaConstants;
-import org.apache.directory.server.constants.CoreSchemaConstants;
 import org.apache.directory.server.constants.MetaSchemaConstants;
 import org.apache.directory.server.constants.SystemSchemaConstants;
 import org.apache.directory.server.core.invocation.Invocation;
@@ -301,7 +300,7 @@
             return;
         }
         
-        if ( AttributeUtils.containsValue( oc, CoreSchemaConstants.ORGANIZATIONAL_UNIT_OC,
objectClassAT ) )
+        if ( AttributeUtils.containsValue( oc, SchemaConstants.ORGANIZATIONAL_UNIT_OC, objectClassAT
) )
         {
             if ( name.size() != 3 )
             {
@@ -348,7 +347,7 @@
             return;
         }
         
-        if ( AttributeUtils.containsValue( oc, CoreSchemaConstants.ORGANIZATIONAL_UNIT_OC,
objectClassAT ) )
+        if ( AttributeUtils.containsValue( oc, SchemaConstants.ORGANIZATIONAL_UNIT_OC, objectClassAT
) )
         {
             if ( name.size() != 3 )
             {

Modified: directory/apacheds/trunk/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/apacheds/trunk/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
(original)
+++ directory/apacheds/trunk/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
Sat Mar 17 13:22:18 2007
@@ -222,7 +222,7 @@
     {
         Attributes entry = new AttributesImpl( "ou", "loadedLdifFiles", true );
         entry.put( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.TOP_OC );
-        entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( "organizationalUnit" );
+        entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( SchemaConstants.ORGANIZATIONAL_UNIT_OC
);
         try
         {
             root.createSubcontext( LDIF_FILES_DN, entry );

Modified: directory/shared/trunk/ldap-constants/src/main/java/org/apache/directory/shared/ldap/constants/SchemaConstants.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap-constants/src/main/java/org/apache/directory/shared/ldap/constants/SchemaConstants.java?view=diff&rev=519438&r1=519437&r2=519438
==============================================================================
--- directory/shared/trunk/ldap-constants/src/main/java/org/apache/directory/shared/ldap/constants/SchemaConstants.java
(original)
+++ directory/shared/trunk/ldap-constants/src/main/java/org/apache/directory/shared/ldap/constants/SchemaConstants.java
Sat Mar 17 13:22:18 2007
@@ -33,6 +33,7 @@
     public static final String SUBENTRY_OC = "subentry";
     public static final String TOP_OC = "top";
     public static final String EXTENSIBLE_OBJECT_OC = "extensibleObject";
+    public static final String ORGANIZATIONAL_UNIT_OC = "organizationalUnit";
     
     // AttributeTypes
     public static final String OBJECT_CLASS_AT = "objectClass";



Mime
View raw message