directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r1081151 [1/2] - in /directory: apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/entry/ apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/ ...
Date Sun, 13 Mar 2011 16:58:32 GMT
Author: akarasulu
Date: Sun Mar 13 16:58:31 2011
New Revision: 1081151

URL: http://svn.apache.org/viewvc?rev=1081151&view=rev
Log:
Checkpoint commit to save changes without loosing data on my RAM drive. However
note that the build is severely broken thanks to a critical blocker bug in the
Java 5/6 SUN compiler, but not present in eclipse around covariant return types
and multiple interface inheritance. Here's the bug report and articles on this
annoying bug:

http://bugs.sun.com/view_bug.do?bug_id=6908259
http://www.coderanch.com/t/457998/java/java/Covariance-multiple-interface-inheritance

It's getting in the way of a clean design but I have a doable work around that 
will clean this up while allowing for better interface design. I'll see if that
holds and commit fixes.


Added:
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MatchingRule.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRule.java
Modified:
    directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/entry/TestServerEntryUtils.java
    directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SyntaxSynchronizer.java
    directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaMatchingRuleHandlerIT.java
    directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaSyntaxHandlerIT.java
    directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/SubschemaSubentryIT.java
    directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/LeafEvaluator.java
    directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/SubstringEvaluator.java
    directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/AttributesFactory.java
    directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/DefaultSchemaService.java
    directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/SchemaSubentryModifier.java
    directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmIndex.java
    directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmRdnIndex.java
    directory/apacheds/branches/akarasulu/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/MockComparatorRegistry.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateEvaluator.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityEvaluator.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LeafEvaluator.java
    directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/SubstringEvaluator.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/entry/AbstractValue.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/name/Ava.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractMutableSchemaObject.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractSchemaObject.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LdapSyntax.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LoadableSchemaObject.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLdapSyntaxImpl.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObject.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObjectImpl.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRuleImpl.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableSchemaObject.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaManager.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaUtils.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/normalizers/ConcreteNameComponentNormalizer.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/ComparatorRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/DefaultAttributeTypeRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/DefaultComparatorRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/DefaultMatchingRuleRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/ImmutableComparatorRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/ImmutableMatchingRuleRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/ImmutableSyntaxCheckerRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/MatchingRuleRegistry.java
    directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/registries/Registries.java
    directory/shared/branches/akarasulu/ldap/schema/data/src/main/java/org/apache/directory/shared/ldap/schemamanager/impl/DefaultSchemaManager.java
    directory/shared/branches/akarasulu/ldap/schema/data/src/test/java/org/apache/directory/shared/ldap/schemaloader/MatchingRuleTest.java
    directory/shared/branches/akarasulu/ldap/schema/data/src/test/java/org/apache/directory/shared/ldap/schemaloader/SchemaManagerAddTest.java
    directory/shared/branches/akarasulu/ldap/schema/data/src/test/java/org/apache/directory/shared/ldap/schemaloader/SchemaManagerDelTest.java
    directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleDescriptionPage.java
    directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowser.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaAdapter.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandler.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandlerListener.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaListener.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboComparator.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboContentProvider.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboLabelProvider.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/schema/SchemaEditorSourceCodePage.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/views/ProblemsViewLabelProvider.java
    directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/wizards/NewAttributeTypeMatchingRulesWizardPage.java

Modified: directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/entry/TestServerEntryUtils.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/entry/TestServerEntryUtils.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/entry/TestServerEntryUtils.java (original)
+++ directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/entry/TestServerEntryUtils.java Sun Mar 13 16:58:31 2011
@@ -26,6 +26,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
 import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
 import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
 import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
 import org.apache.directory.shared.ldap.model.schema.AbstractNormalizer;
@@ -54,9 +55,9 @@ public class TestServerEntryUtils
         }
     }
 
-    public static MutableMatchingRuleImpl matchingRuleFactory( String oid )
+    public static MatchingRule matchingRuleFactory( String oid )
     {
-        MutableMatchingRuleImpl matchingRule = new MutableMatchingRuleImpl( oid );
+        MatchingRule matchingRule = new MutableMatchingRuleImpl( oid );
         
         return matchingRule;
     }

Modified: directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SyntaxSynchronizer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SyntaxSynchronizer.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SyntaxSynchronizer.java (original)
+++ directory/apacheds/branches/akarasulu/core-api/src/main/java/org/apache/directory/server/core/schema/registries/synchronizers/SyntaxSynchronizer.java Sun Mar 13 16:58:31 2011
@@ -35,10 +35,9 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.name.Dn;
 import org.apache.directory.shared.ldap.model.name.Rdn;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
+import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
-import org.apache.directory.shared.ldap.model.schema.MutableSchemaObject;
 import org.apache.directory.shared.ldap.model.schema.SchemaObject;
 import org.apache.directory.shared.ldap.model.schema.registries.Schema;
 import org.apache.directory.shared.util.Strings;
@@ -79,7 +78,7 @@ public class SyntaxSynchronizer extends 
         Dn name = modifyContext.getDn();
         Entry entry = modifyContext.getEntry();
         String oid = getOid( entry );
-        MutableLdapSyntaxImpl syntax = factory.getSyntax( schemaManager, targetEntry, schemaManager.getRegistries(),
+        MutableLdapSyntax syntax = factory.getSyntax( schemaManager, targetEntry, schemaManager.getRegistries(),
             getSchemaName( name ) );
         String schemaName = getSchemaName( entry.getDn() );
 
@@ -112,7 +111,7 @@ public class SyntaxSynchronizer extends 
         // Build the new Syntax from the given entry
         String schemaName = getSchemaName( dn );
 
-        MutableLdapSyntaxImpl syntax = factory.getSyntax( schemaManager, entry, schemaManager.getRegistries(), schemaName );
+        MutableLdapSyntax syntax = factory.getSyntax( schemaManager, entry, schemaManager.getRegistries(), schemaName );
 
         // At this point, the constructed Syntax has not been checked against the 
         // existing Registries. It may be broken (missing SUP, or such), it will be checked
@@ -144,9 +143,9 @@ public class SyntaxSynchronizer extends 
     /**
      * Check if a syntax is used by an AT or a MR
      */
-    private List<MutableSchemaObject> checkInUse( String oid )
+    private List<SchemaObject> checkInUse( String oid )
     {
-        List<MutableSchemaObject> dependees = new ArrayList<MutableSchemaObject>();
+        List<SchemaObject> dependees = new ArrayList<SchemaObject>();
 
         for ( AttributeType attributeType : schemaManager.getAttributeTypeRegistry() )
         {
@@ -156,7 +155,7 @@ public class SyntaxSynchronizer extends 
             }
         }
 
-        for ( MutableMatchingRuleImpl matchingRule : schemaManager.getMatchingRuleRegistry() )
+        for ( MatchingRule matchingRule : schemaManager.getMatchingRuleRegistry() )
         {
             if ( oid.equals( matchingRule.getSyntax().getOid() ) )
             {
@@ -171,7 +170,7 @@ public class SyntaxSynchronizer extends 
     /**
      * Get the list of SchemaObject's name using a given syntax
      */
-    private String getNames( List<MutableSchemaObject> schemaObjects )
+    private String getNames( List<SchemaObject> schemaObjects )
     {
         StringBuilder sb = new StringBuilder();
         boolean isFirst = true;
@@ -221,7 +220,7 @@ public class SyntaxSynchronizer extends 
         }
 
         // Test that the Oid exists
-        MutableLdapSyntaxImpl syntax = ( MutableLdapSyntaxImpl ) checkOidExists( entry );
+        MutableLdapSyntax syntax = ( MutableLdapSyntax ) checkOidExists( entry );
 
         List<Throwable> errors = new ArrayList<Throwable>();
 
@@ -256,7 +255,7 @@ public class SyntaxSynchronizer extends 
         String schemaName = getSchemaName( entry.getDn() );
 
         // Check that this syntax is not used by an AttributeType
-        List<MutableSchemaObject> dependees = checkInUse( oldOid );
+        List<SchemaObject> dependees = checkInUse( oldOid );
 
         if ( dependees.size() != 0 )
         {
@@ -269,7 +268,7 @@ public class SyntaxSynchronizer extends 
         checkOidIsUnique( newOid );
 
         targetEntry.put( MetaSchemaConstants.M_OID_AT, newOid );
-        MutableLdapSyntaxImpl syntax = factory.getSyntax( schemaManager, targetEntry, schemaManager.getRegistries(),
+        MutableLdapSyntax syntax = factory.getSyntax( schemaManager, targetEntry, schemaManager.getRegistries(),
             getSchemaName( entry.getDn() ) );
 
         if ( isSchemaEnabled( schemaName ) )
@@ -296,7 +295,7 @@ public class SyntaxSynchronizer extends 
         String newSchemaName = getSchemaName( newParentName );
 
         // Check that this syntax is not used by an AttributeType
-        List<MutableSchemaObject> dependees = checkInUse( oldOid );
+        List<SchemaObject> dependees = checkInUse( oldOid );
 
         if ( dependees.size() != 0 )
         {
@@ -309,7 +308,7 @@ public class SyntaxSynchronizer extends 
         checkOidIsUnique( newOid );
 
         targetEntry.put( MetaSchemaConstants.M_OID_AT, newOid );
-        MutableLdapSyntaxImpl syntax = factory.getSyntax( schemaManager, targetEntry, schemaManager.getRegistries(),
+        MutableLdapSyntax syntax = factory.getSyntax( schemaManager, targetEntry, schemaManager.getRegistries(),
             getSchemaName( newParentName ) );
 
         if ( isSchemaEnabled( oldSchemaName ) )
@@ -353,7 +352,7 @@ public class SyntaxSynchronizer extends 
         //                ResultCodeEnum.UNWILLING_TO_PERFORM );
         //        }
 
-        MutableLdapSyntaxImpl syntax = factory.getSyntax( schemaManager, entry, schemaManager.getRegistries(),
+        MutableLdapSyntax syntax = factory.getSyntax( schemaManager, entry, schemaManager.getRegistries(),
             getSchemaName( newParentName ) );
 
         if ( isSchemaEnabled( oldSchemaName ) )

Modified: directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaMatchingRuleHandlerIT.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaMatchingRuleHandlerIT.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaMatchingRuleHandlerIT.java (original)
+++ directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaMatchingRuleHandlerIT.java Sun Mar 13 16:58:31 2011
@@ -42,7 +42,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.ldif.LdifUtils;
 import org.apache.directory.shared.ldap.model.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.model.name.Dn;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.ldap.model.schema.comparators.StringComparator;
 import org.apache.directory.shared.ldap.util.JndiUtils;
@@ -250,7 +250,7 @@ public class MetaMatchingRuleHandlerIT e
     {
         testAddMatchingRuleToEnabledSchema();
 
-        MutableMatchingRuleImpl mr = schemaManager.getMatchingRuleRegistry().lookup( OID );
+        MatchingRule mr = schemaManager.getMatchingRuleRegistry().lookup( OID );
         assertEquals( mr.getDescription(), DESCRIPTION0 );
         assertEquals( mr.getSyntax().getOid(), SchemaConstants.INTEGER_SYNTAX );
 
@@ -282,7 +282,7 @@ public class MetaMatchingRuleHandlerIT e
     {
         testAddMatchingRuleToEnabledSchema();
 
-        MutableMatchingRuleImpl mr = schemaManager.getMatchingRuleRegistry().lookup( OID );
+        MatchingRule mr = schemaManager.getMatchingRuleRegistry().lookup( OID );
         assertEquals( mr.getDescription(), DESCRIPTION0 );
         assertEquals( mr.getSyntax().getOid(), SchemaConstants.INTEGER_SYNTAX );
 

Modified: directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaSyntaxHandlerIT.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaSyntaxHandlerIT.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaSyntaxHandlerIT.java (original)
+++ directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/MetaSyntaxHandlerIT.java Sun Mar 13 16:58:31 2011
@@ -50,7 +50,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.ldif.LdifUtils;
 import org.apache.directory.shared.ldap.model.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.model.name.Dn;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.ldap.model.schema.syntaxCheckers.OctetStringSyntaxChecker;
 import org.apache.directory.shared.ldap.util.JndiUtils;
@@ -309,7 +309,7 @@ public class MetaSyntaxHandlerIT extends
     {
         testAddSyntaxToEnabledSchema();
 
-        MutableLdapSyntax syntax = schemaManager.getLdapSyntaxRegistry().lookup( OID );
+        LdapSyntax syntax = schemaManager.getLdapSyntaxRegistry().lookup( OID );
         assertEquals( syntax.getDescription(), DESCRIPTION0 );
 
         Dn dn = getSyntaxContainer( "apachemeta" );
@@ -337,7 +337,7 @@ public class MetaSyntaxHandlerIT extends
     {
         testAddSyntaxToEnabledSchema();
 
-        MutableLdapSyntax syntax = schemaManager.getLdapSyntaxRegistry().lookup( OID );
+        LdapSyntax syntax = schemaManager.getLdapSyntaxRegistry().lookup( OID );
         assertEquals( syntax.getDescription(), DESCRIPTION0 );
 
         Dn dn = getSyntaxContainer( "apachemeta" );

Modified: directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/SubschemaSubentryIT.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/SubschemaSubentryIT.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/SubschemaSubentryIT.java (original)
+++ directory/apacheds/branches/akarasulu/core-integ/src/test/java/org/apache/directory/server/core/schema/SubschemaSubentryIT.java Sun Mar 13 16:58:31 2011
@@ -1987,6 +1987,7 @@ public class SubschemaSubentryIT extends
         env.put( Context.SECURITY_CREDENTIALS, "secret" );
         env.put( Context.SECURITY_PRINCIPAL, "cn=bogus user,ou=system" );
         env.put( DirectoryService.JNDI_KEY, getService() );
+        @SuppressWarnings("unused")
         InitialDirContext ctx = new InitialDirContext( env );
 
         // now let's add another attribute type definition to the schema but

Modified: directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/LeafEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/LeafEvaluator.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/LeafEvaluator.java (original)
+++ directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/LeafEvaluator.java Sun Mar 13 16:58:31 2011
@@ -22,8 +22,6 @@ package org.apache.directory.server.core
 
 import java.util.Comparator;
 
-import javax.management.modelmbean.ModelMBean;
-
 import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.shared.ldap.model.entry.Entry;
 import org.apache.directory.shared.ldap.model.entry.EntryAttribute;
@@ -42,8 +40,8 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.filter.SubstringNode;
 import org.apache.directory.shared.ldap.model.name.Dn;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapComparator;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.util.exception.NotImplementedException;
@@ -65,9 +63,6 @@ public class LeafEvaluator implements Ev
     /** substring matching type constant */
     private static final int SUBSTRING_MATCH = 3;
 
-    /** SchemaManager needed for normalizing and comparing values */
-    private SchemaManager schemaManager;
-    
     /** Substring node evaluator we depend on */
     private SubstringEvaluator substringEvaluator;
     
@@ -87,7 +82,6 @@ public class LeafEvaluator implements Ev
     public LeafEvaluator( SchemaManager schemaManager,
         SubstringEvaluator substringEvaluator )
     {
-        this.schemaManager = schemaManager;
         this.scopeEvaluator = new ScopeEvaluator();
         this.substringEvaluator = substringEvaluator;
     }
@@ -157,7 +151,6 @@ public class LeafEvaluator implements Ev
      * @return the ava evaluation on the perspective candidate
      * @throws LdapException if there is a database access failure
      */
-    @SuppressWarnings("unchecked")
     private boolean evalGreaterOrLesser( SimpleNode<?> node, Entry entry, boolean isGreaterOrLesser )
         throws LdapException
     {
@@ -177,7 +170,7 @@ public class LeafEvaluator implements Ev
          * and use the comparator to determine if a match exists.
          */
         Normalizer normalizer = getNormalizer( attributeType );
-        Comparator comparator = getComparator( attributeType );
+        Comparator<Object> comparator = getComparator( attributeType );
         Object filterValue = normalizer.normalize( node.getValue() );
 
         /*
@@ -244,11 +237,10 @@ public class LeafEvaluator implements Ev
      * @return the ava evaluation on the perspective candidate
      * @throws org.apache.directory.shared.ldap.model.exception.LdapException if there is a database access failure
      */
-    @SuppressWarnings("unchecked")
     private boolean evalEquality( EqualityNode<?> node, Entry entry ) throws LdapException
     {
         Normalizer normalizer = getNormalizer( node.getAttributeType() );
-        Comparator comparator = getComparator( node.getAttributeType() );
+        Comparator<Object> comparator = getComparator( node.getAttributeType() );
 
         // get the attribute associated with the node
         EntryAttribute attr = entry.get( node.getAttribute() );
@@ -320,9 +312,9 @@ public class LeafEvaluator implements Ev
      * @return the comparator for equality matching
      * @throws LdapException if there is a failure
      */
-    private AbstractLdapComparator<? super Object> getComparator( AttributeType attributeType ) throws LdapException
+    private LdapComparator<Object> getComparator( AttributeType attributeType ) throws LdapException
     {
-        MutableMatchingRuleImpl mrule = getMatchingRule( attributeType, EQUALITY_MATCH );
+        MatchingRule mrule = getMatchingRule( attributeType, EQUALITY_MATCH );
         
         return mrule.getLdapComparator();
     }
@@ -337,7 +329,7 @@ public class LeafEvaluator implements Ev
      */
     private Normalizer getNormalizer( AttributeType attributeType ) throws LdapException
     {
-        MutableMatchingRuleImpl mrule = getMatchingRule( attributeType, EQUALITY_MATCH );
+        MatchingRule mrule = getMatchingRule( attributeType, EQUALITY_MATCH );
         
         return mrule.getNormalizer();
     }
@@ -350,9 +342,9 @@ public class LeafEvaluator implements Ev
      * @return the matching rule
      * @throws LdapException if there is a failure
      */
-    private MutableMatchingRuleImpl getMatchingRule( AttributeType attributeType, int matchType ) throws LdapException
+    private MatchingRule getMatchingRule( AttributeType attributeType, int matchType ) throws LdapException
     {
-        MutableMatchingRuleImpl mrule = null;
+        MatchingRule mrule = null;
 
         switch ( matchType )
         {

Modified: directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/SubstringEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/SubstringEvaluator.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/SubstringEvaluator.java (original)
+++ directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/event/SubstringEvaluator.java Sun Mar 13 16:58:31 2011
@@ -33,7 +33,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.filter.SubstringNode;
 import org.apache.directory.shared.ldap.model.name.Dn;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 
 
@@ -60,7 +60,7 @@ public class SubstringEvaluator implemen
         Pattern regex = null;
         SubstringNode snode = (SubstringNode)node;
         AttributeType attributeType = snode.getAttributeType();
-        MutableMatchingRuleImpl matchingRule = attributeType.getSubstring();
+        MatchingRule matchingRule = attributeType.getSubstring();
         
         if ( matchingRule == null )
         {

Modified: directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/AttributesFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/AttributesFactory.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/AttributesFactory.java (original)
+++ directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/AttributesFactory.java Sun Mar 13 16:58:31 2011
@@ -35,6 +35,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.schema.DITStructureRule;
 import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
 import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
 import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
 import org.apache.directory.shared.ldap.model.schema.MatchingRuleUse;
@@ -63,7 +64,7 @@ public class AttributesFactory
         {
             return getAttributes( ( MutableLdapSyntaxImpl ) obj, schema, schemaManager );
         }
-        else if ( obj instanceof MutableMatchingRuleImpl )
+        else if ( obj instanceof MatchingRule )
         {
             return getAttributes( ( MutableMatchingRuleImpl ) obj, schema, schemaManager );
         }

Modified: directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/DefaultSchemaService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/DefaultSchemaService.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/DefaultSchemaService.java (original)
+++ directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/DefaultSchemaService.java Sun Mar 13 16:58:31 2011
@@ -35,9 +35,9 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
 import org.apache.directory.shared.ldap.model.schema.DITContentRule;
 import org.apache.directory.shared.ldap.model.schema.DITStructureRule;
-import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapComparator;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.MatchingRuleUse;
 import org.apache.directory.shared.ldap.model.schema.NameForm;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
@@ -110,7 +110,7 @@ public class DefaultSchemaService implem
         EntryAttribute attr = new DefaultEntryAttribute( 
             getSchemaManager().lookupAttributeTypeRegistry( SchemaConstants.COMPARATORS_AT ) );
 
-        for ( AbstractLdapComparator<?> comparator : getSchemaManager().getComparatorRegistry() )
+        for ( LdapComparator<?> comparator : getSchemaManager().getComparatorRegistry() )
         {
             attr.add( SchemaUtils.render( comparator ) );
         }
@@ -182,7 +182,7 @@ public class DefaultSchemaService implem
         EntryAttribute attr = new DefaultEntryAttribute( 
             getSchemaManager().getAttributeType( SchemaConstants.MATCHING_RULES_AT ) );
 
-        for ( MutableMatchingRuleImpl matchingRule : getSchemaManager().getMatchingRuleRegistry() )
+        for ( MatchingRule matchingRule : getSchemaManager().getMatchingRuleRegistry() )
         {
             attr.add( SchemaUtils.render( matchingRule ).toString() );
         }
@@ -210,7 +210,7 @@ public class DefaultSchemaService implem
         EntryAttribute attr = new DefaultEntryAttribute( 
             getSchemaManager().getAttributeType( SchemaConstants.LDAP_SYNTAXES_AT ) );
 
-        for ( MutableLdapSyntax syntax : getSchemaManager().getLdapSyntaxRegistry() )
+        for ( LdapSyntax syntax : getSchemaManager().getLdapSyntaxRegistry() )
         {
             attr.add( SchemaUtils.render( syntax ).toString() );
         }

Modified: directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/SchemaSubentryModifier.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/SchemaSubentryModifier.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/SchemaSubentryModifier.java (original)
+++ directory/apacheds/branches/akarasulu/core/src/main/java/org/apache/directory/server/core/schema/SchemaSubentryModifier.java Sun Mar 13 16:58:31 2011
@@ -42,7 +42,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.schema.DITContentRule;
 import org.apache.directory.shared.ldap.model.schema.DITStructureRule;
 import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.MatchingRuleUse;
 import org.apache.directory.shared.ldap.model.schema.NameForm;
 import org.apache.directory.shared.ldap.model.schema.ObjectClass;
@@ -109,7 +109,7 @@ public class SchemaSubentryModifier
         {
             buf.append( "syntaxes" );
         }
-        else if ( obj instanceof MutableMatchingRuleImpl )
+        else if ( obj instanceof MatchingRule )
         {
             buf.append( SchemaConstants.MATCHING_RULES_AT );
         }

Modified: directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmIndex.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmIndex.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmIndex.java (original)
+++ directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmIndex.java Sun Mar 13 16:58:31 2011
@@ -40,6 +40,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.cursor.Tuple;
 import org.apache.directory.shared.ldap.model.entry.BinaryValue;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
+import org.apache.directory.shared.ldap.model.schema.MutableMatchingRule;
 import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.ldap.model.schema.comparators.SerializableComparator;
@@ -210,7 +211,7 @@ public class JdbmIndex<K, O> extends Abs
     {
         SerializableComparator<K> comp;
 
-        MutableMatchingRuleImpl mr = attributeType.getEquality();
+        MutableMatchingRule mr = attributeType.getEquality();
 
         if ( mr == null )
         {

Modified: directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmRdnIndex.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmRdnIndex.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmRdnIndex.java (original)
+++ directory/apacheds/branches/akarasulu/jdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmRdnIndex.java Sun Mar 13 16:58:31 2011
@@ -17,7 +17,6 @@
  *   under the License.
  *
  */
-
 package org.apache.directory.server.core.partition.impl.btree.jdbm;
 
 
@@ -36,7 +35,7 @@ import org.apache.directory.server.i18n.
 import org.apache.directory.server.xdbm.ParentIdAndRdn;
 import org.apache.directory.server.xdbm.ParentIdAndRdnComparator;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.util.SynchronizedLRUMap;
 import org.slf4j.Logger;
@@ -128,7 +127,7 @@ public class JdbmRdnIndex<E> extends Jdb
      */
     private void initTables( SchemaManager schemaManager ) throws IOException
     {
-        MutableMatchingRuleImpl mr = attributeType.getEquality();
+        MatchingRule mr = attributeType.getEquality();
 
         if ( mr == null )
         {

Modified: directory/apacheds/branches/akarasulu/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/MockComparatorRegistry.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/MockComparatorRegistry.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/MockComparatorRegistry.java (original)
+++ directory/apacheds/branches/akarasulu/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/MockComparatorRegistry.java Sun Mar 13 16:58:31 2011
@@ -24,6 +24,7 @@ import java.util.Iterator;
 
 import org.apache.directory.shared.ldap.model.exception.LdapException;
 import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
+import org.apache.directory.shared.ldap.model.schema.MutableLdapComparator;
 import org.apache.directory.shared.ldap.model.schema.parsers.LdapComparatorDescription;
 import org.apache.directory.shared.ldap.model.schema.registries.DefaultComparatorRegistry;
 
@@ -42,6 +43,8 @@ class MockComparatorRegistry extends Def
 
     private AbstractLdapComparator<Integer> comparator = new AbstractLdapComparator<Integer>( "1.1.1" )
     {
+        private static final long serialVersionUID = 1L;
+
         public int compare( Integer i1, Integer i2 )
         {
             return i1.compareTo( i2 );
@@ -77,7 +80,7 @@ class MockComparatorRegistry extends Def
     }
 
 
-    public Iterator<AbstractLdapComparator<?>> iterator()
+    public Iterator<MutableLdapComparator<?>> iterator()
     {
         return null;
     }

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java Sun Mar 13 16:58:31 2011
@@ -52,7 +52,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.name.Dn;
 import org.apache.directory.shared.ldap.model.name.Rdn;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -276,7 +276,7 @@ public abstract class AbstractStore<E, I
         {
             // check that the attributeType has an EQUALITY matchingRule
             AttributeType attributeType = schemaManager.lookupAttributeTypeRegistry( oid );
-            MutableMatchingRuleImpl mr = attributeType.getEquality();
+            MatchingRule mr = attributeType.getEquality();
 
             if ( mr != null )
             {

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java Sun Mar 13 16:58:31 2011
@@ -32,7 +32,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.entry.BinaryValue;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
 import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 
@@ -65,7 +65,7 @@ public class AvlIndex<K, O> extends Abst
     {
         this.attributeType = attributeType;
 
-        MutableMatchingRuleImpl mr = attributeType.getEquality();
+        MatchingRule mr = attributeType.getEquality();
 
         if ( mr == null )
         {

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java Sun Mar 13 16:58:31 2011
@@ -17,7 +17,6 @@
  *   under the License.
  *
  */
-
 package org.apache.directory.server.xdbm.impl.avl;
 
 
@@ -26,7 +25,7 @@ import org.apache.directory.server.i18n.
 import org.apache.directory.server.xdbm.ParentIdAndRdn;
 import org.apache.directory.server.xdbm.ParentIdAndRdnComparator;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 
 
@@ -53,7 +52,7 @@ public class AvlRdnIndex<E> extends AvlI
     {
         this.attributeType = attributeType;
 
-        MutableMatchingRuleImpl mr = attributeType.getEquality();
+        MatchingRule mr = attributeType.getEquality();
 
         if ( mr == null )
         {

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateEvaluator.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateEvaluator.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/ApproximateEvaluator.java Sun Mar 13 16:58:31 2011
@@ -31,7 +31,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.entry.Value;
 import org.apache.directory.shared.ldap.model.filter.ApproximateNode;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 
 
@@ -58,7 +58,7 @@ public class ApproximateEvaluator<T, ID 
         {
             idx = null;
 
-            MutableMatchingRuleImpl mr = attributeType.getEquality();
+            MatchingRule mr = attributeType.getEquality();
 
             if ( mr == null )
             {

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityEvaluator.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityEvaluator.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/EqualityEvaluator.java Sun Mar 13 16:58:31 2011
@@ -31,7 +31,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.entry.Value;
 import org.apache.directory.shared.ldap.model.filter.EqualityNode;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.ldap.model.schema.comparators.ByteArrayComparator;
 import org.apache.directory.shared.ldap.model.schema.comparators.StringComparator;
@@ -70,7 +70,7 @@ public class EqualityEvaluator<T, ID ext
         {
             idx = null;
 
-            MutableMatchingRuleImpl mr = attributeType.getEquality();
+            MatchingRule mr = attributeType.getEquality();
 
             if ( mr == null )
             {

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LeafEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LeafEvaluator.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LeafEvaluator.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/LeafEvaluator.java Sun Mar 13 16:58:31 2011
@@ -25,7 +25,7 @@ import org.apache.directory.server.xdbm.
 import org.apache.directory.shared.ldap.model.entry.Entry;
 import org.apache.directory.shared.ldap.model.filter.SimpleNode;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
+import org.apache.directory.shared.ldap.model.schema.LdapComparator;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 
@@ -54,12 +54,12 @@ public abstract class LeafEvaluator<T, I
     protected Normalizer normalizer;
     
     /** The associated comparator */
-    protected AbstractLdapComparator<? super Object> ldapComparator;
+    protected LdapComparator<Object> ldapComparator;
     
     /** The index to use if any */
     protected Index<T, Entry, ID> idx;
 
-    @SuppressWarnings("unchecked")
+
     public LeafEvaluator( SimpleNode<T> node, Store<Entry, ID> db, SchemaManager schemaManager )
     throws Exception
     {
@@ -91,7 +91,7 @@ public abstract class LeafEvaluator<T, I
     /**
      * @return The LdapComparator associated with the AttributeType
      */
-    public AbstractLdapComparator<? super Object> getComparator()
+    public LdapComparator<Object> getComparator()
     {
         return ldapComparator;
     }

Modified: directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/SubstringEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/SubstringEvaluator.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/SubstringEvaluator.java (original)
+++ directory/apacheds/branches/akarasulu/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/impl/SubstringEvaluator.java Sun Mar 13 16:58:31 2011
@@ -34,7 +34,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.entry.Value;
 import org.apache.directory.shared.ldap.model.filter.SubstringNode;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.ldap.model.schema.normalizers.NoOpNormalizer;
@@ -86,7 +86,7 @@ public class SubstringEvaluator<ID exten
         this.schemaManager = schemaManager;
         this.attributeType = node.getAttributeType();
 
-        MutableMatchingRuleImpl rule = attributeType.getSubstring();
+        MatchingRule rule = attributeType.getSubstring();
 
         if ( rule == null )
         {

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/entry/AbstractValue.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/entry/AbstractValue.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/entry/AbstractValue.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/entry/AbstractValue.java Sun Mar 13 16:58:31 2011
@@ -27,7 +27,7 @@ import org.apache.directory.shared.i18n.
 import org.apache.directory.shared.ldap.model.exception.LdapException;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
 import org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.ldap.model.schema.SyntaxChecker;
@@ -169,7 +169,7 @@ public abstract class AbstractValue<T> i
     {
         if ( attributeType != null )
         {
-            MutableMatchingRuleImpl mr = getMatchingRule();
+            MatchingRule mr = getMatchingRule();
     
             if ( mr == null )
             {
@@ -194,11 +194,11 @@ public abstract class AbstractValue<T> i
      * @return a matchingRule or null if one cannot be found for the attributeType
      * @throws LdapException if resolution of schema entities fail
      */
-    protected final MutableMatchingRuleImpl getMatchingRule() throws LdapException
+    protected final MatchingRule getMatchingRule() throws LdapException
     {
         if ( attributeType != null )
         {
-            MutableMatchingRuleImpl mr = attributeType.getEquality();
+            MatchingRule mr = attributeType.getEquality();
     
             if ( mr == null )
             {
@@ -230,7 +230,7 @@ public abstract class AbstractValue<T> i
     {
         if ( attributeType != null )
         {
-            MutableMatchingRuleImpl mr = getMatchingRule();
+            MatchingRule mr = getMatchingRule();
     
             if ( mr == null )
             {

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/name/Ava.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/name/Ava.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/name/Ava.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/name/Ava.java Sun Mar 13 16:58:31 2011
@@ -33,7 +33,8 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.shared.ldap.model.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapComparator;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.util.Strings;
 import org.slf4j.Logger;
@@ -211,7 +212,7 @@ public final class Ava implements Extern
             
         try
         {
-            MutableMatchingRuleImpl equalityMatchingRule = attributeType.getEquality();
+            MatchingRule equalityMatchingRule = attributeType.getEquality();
             
             if ( equalityMatchingRule != null )
             {
@@ -676,11 +677,15 @@ public final class Ava implements Extern
         {
             if ( schemaManager != null )
             {
-                MutableMatchingRuleImpl equalityMatchingRule = attributeType.getEquality();
+                MatchingRule equalityMatchingRule = attributeType.getEquality();
                 
                 if ( equalityMatchingRule != null )
                 {
-                    return equalityMatchingRule.getLdapComparator().compare( normValue.get(), instance.normValue.get() ) == 0;
+                    Object o1 = normValue.get();
+                    Object o2 = instance.normValue.get();
+                    @SuppressWarnings("unchecked")
+                    LdapComparator<Object> comparator = ( LdapComparator<Object> ) equalityMatchingRule.getLdapComparator();
+                    return comparator.compare( o1, o2 ) == 0;
                 }
                 
                 return false;

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractMutableSchemaObject.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractMutableSchemaObject.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractMutableSchemaObject.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractMutableSchemaObject.java Sun Mar 13 16:58:31 2011
@@ -75,7 +75,8 @@ public abstract class AbstractMutableSch
     private static final long serialVersionUID = 1L;
 
     /** A locked to avoid modifications when set to true */
-    protected volatile boolean locked;
+    protected volatile boolean locked = false;
+    
     
     /**
      * A constructor for a SchemaObject instance. It must be

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractSchemaObject.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractSchemaObject.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractSchemaObject.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AbstractSchemaObject.java Sun Mar 13 16:58:31 2011
@@ -25,7 +25,7 @@ import java.util.List;
 import java.util.Map;
 
 
-public abstract class AbstractSchemaObject
+public abstract class AbstractSchemaObject implements SchemaObject
 {
 
     /** The serial version UID */
@@ -53,11 +53,7 @@ public abstract class AbstractSchemaObje
     /** The hashcode for this schemaObject */
     protected int h;
 
-    public AbstractSchemaObject()
-    {
-        super();
-    }
-
+    
     /**
      * Gets usually what is the numeric object identifier assigned to this
      * SchemaObject. All schema objects except for MatchingRuleUses have an OID
@@ -384,8 +380,9 @@ public abstract class AbstractSchemaObje
      *
      * @return The copied SchemaObject
      */
-    public abstract MutableSchemaObject copy();
-
+    public abstract SchemaObject copy();
+    
+    
     /**
      * Compare two oids, and return true if they are both null or equal.
      *

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/AttributeType.java Sun Mar 13 16:58:31 2011
@@ -156,19 +156,19 @@ public class AttributeType extends Abstr
     private String equalityOid;
 
     /** The equality MatchingRule associated with the equalityID */
-    private MutableMatchingRuleImpl equality;
+    private MutableMatchingRule equality;
 
     /** The substring OID associated with this AttributeType */
     private String substringOid;
 
     /** The substring MatchingRule associated with the substringID */
-    private MutableMatchingRuleImpl substring;
+    private MutableMatchingRule substring;
 
     /** The ordering OID associated with this AttributeType */
     private String orderingOid;
 
     /** The ordering MatchingRule associated with the orderingID */
-    private MutableMatchingRuleImpl ordering;
+    private MutableMatchingRule ordering;
 
     /** The superior AttributeType OID */
     private String superiorOid;
@@ -407,7 +407,7 @@ public class AttributeType extends Abstr
         // The equality MR. It can be null
         if ( equalityOid != null )
         {
-            MutableMatchingRuleImpl currentEquality = null;
+            MutableMatchingRule currentEquality = null;
 
             try
             {
@@ -463,7 +463,7 @@ public class AttributeType extends Abstr
     {
         if ( orderingOid != null )
         {
-            MutableMatchingRuleImpl currentOrdering = null;
+            MutableMatchingRule currentOrdering = null;
 
             try
             {
@@ -520,7 +520,7 @@ public class AttributeType extends Abstr
         // The Substring MR. It can be null
         if ( substringOid != null )
         {
-            MutableMatchingRuleImpl currentSubstring = null;
+            MutableMatchingRule currentSubstring = null;
 
             try
             {
@@ -1147,7 +1147,7 @@ public class AttributeType extends Abstr
      *
      * @param syntax The Syntax for this AttributeType
      */
-    public void setSyntax( MutableLdapSyntaxImpl syntax )
+    public void setSyntax( MutableLdapSyntax syntax )
     {
         if ( locked )
         {
@@ -1167,7 +1167,7 @@ public class AttributeType extends Abstr
      *
      * @param newSyntax The Syntax for this AttributeType
      */
-    public void updateSyntax( MutableLdapSyntaxImpl newSyntax )
+    public void updateSyntax( MutableLdapSyntax newSyntax )
     {
         if ( locked )
         {
@@ -1184,7 +1184,7 @@ public class AttributeType extends Abstr
      *
      * @return the equality matching rule
      */
-    public MutableMatchingRuleImpl getEquality()
+    public MutableMatchingRule getEquality()
     {
         return equality;
     }
@@ -1263,7 +1263,7 @@ public class AttributeType extends Abstr
      *
      * @param newEquality The Equality MR for this AttributeType
      */
-    public void updateEquality( MutableMatchingRuleImpl newEquality )
+    public void updateEquality( MutableMatchingRule newEquality )
     {
         if ( locked )
         {
@@ -1280,7 +1280,7 @@ public class AttributeType extends Abstr
      *
      * @return the Ordering matching rule
      */
-    public MutableMatchingRuleImpl getOrdering()
+    public MutableMatchingRule getOrdering()
     {
         return ordering;
     }
@@ -1339,7 +1339,7 @@ public class AttributeType extends Abstr
      *
      * @param ordering The Ordering MR for this AttributeType
      */
-    public void setOrdering( MutableMatchingRuleImpl ordering )
+    public void setOrdering( MutableMatchingRule ordering )
     {
         if ( locked )
         {
@@ -1359,7 +1359,7 @@ public class AttributeType extends Abstr
      *
      * @param newOrdering The Ordering MR for this AttributeType
      */
-    public void updateOrdering( MutableMatchingRuleImpl newOrdering )
+    public void updateOrdering( MutableMatchingRule newOrdering )
     {
         if ( locked )
         {
@@ -1376,7 +1376,7 @@ public class AttributeType extends Abstr
      *
      * @return the Substr matching rule
      */
-    public MutableMatchingRuleImpl getSubstring()
+    public MutableMatchingRule getSubstring()
     {
         return substring;
     }
@@ -1435,7 +1435,7 @@ public class AttributeType extends Abstr
      *
      * @param substring The Substr MR for this AttributeType
      */
-    public void setSubstring( MutableMatchingRuleImpl substring )
+    public void setSubstring( MutableMatchingRule substring )
     {
         if ( locked )
         {
@@ -1455,7 +1455,7 @@ public class AttributeType extends Abstr
      *
      * @param newSubstring The Substr MR for this AttributeType
      */
-    public void updateSubstring( MutableMatchingRuleImpl newSubstring )
+    public void updateSubstring( MutableMatchingRule newSubstring )
     {
         if ( locked )
         {

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LdapSyntax.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LdapSyntax.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LdapSyntax.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LdapSyntax.java Sun Mar 13 16:58:31 2011
@@ -29,7 +29,7 @@ public interface LdapSyntax extends Sche
      */
     boolean isHumanReadable();
 
-
+    
     /**
      * Gets the SyntaxChecker used to validate values in accordance with this
      * Syntax.

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LoadableSchemaObject.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LoadableSchemaObject.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LoadableSchemaObject.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/LoadableSchemaObject.java Sun Mar 13 16:58:31 2011
@@ -27,6 +27,9 @@ package org.apache.directory.shared.ldap
  */
 public interface LoadableSchemaObject extends SchemaObject
 {
+    /**
+     * {@inheritDoc}
+     */
     LoadableSchemaObject copy();
     
     /**

Added: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MatchingRule.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MatchingRule.java?rev=1081151&view=auto
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MatchingRule.java (added)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MatchingRule.java Sun Mar 13 16:58:31 2011
@@ -0,0 +1,43 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *  
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *  
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License. 
+ *  
+ */
+package org.apache.directory.shared.ldap.model.schema;
+
+
+/**
+ * The interface for an immutable MatchingRule.
+ * 
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public interface MatchingRule extends SchemaObject
+{
+    LdapSyntax getSyntax();
+
+
+    String getSyntaxOid();
+
+
+    LdapComparator<Object> getLdapComparator();
+
+    
+    Normalizer getNormalizer();
+
+
+    MatchingRule copy();
+}
\ No newline at end of file

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLdapSyntaxImpl.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLdapSyntaxImpl.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLdapSyntaxImpl.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLdapSyntaxImpl.java Sun Mar 13 16:58:31 2011
@@ -154,8 +154,8 @@ public class MutableLdapSyntaxImpl exten
     }
 
 
-    /* (non-Javadoc)
-     * @see org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax#setSyntaxChecker(org.apache.directory.shared.ldap.model.schema.MutableSyntaxCheckerImpl)
+    /**
+     * {@inheritDoc}
      */
     public void setSyntaxChecker( MutableSyntaxChecker syntaxChecker )
     {

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObject.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObject.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObject.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObject.java Sun Mar 13 16:58:31 2011
@@ -27,7 +27,12 @@ package org.apache.directory.shared.ldap
  */
 public interface MutableLoadableSchemaObject extends LoadableSchemaObject, MutableSchemaObject
 {
-    MutableLoadableSchemaObject copy();
+    LoadableSchemaObject copy();
+    
+    /**
+     * {@inheritDoc}
+     */
+    MutableLoadableSchemaObject copyMutable();
     
     /**
      * Stores some bytecode representing the compiled Java class for this

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObjectImpl.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObjectImpl.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObjectImpl.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableLoadableSchemaObjectImpl.java Sun Mar 13 16:58:31 2011
@@ -136,7 +136,7 @@ public abstract class MutableLoadableSch
     /**
      * {@inheritDoc}
      */
-    public MutableLoadableSchemaObjectImpl copy()
+    public LoadableSchemaObject copy()
     {
         return null;
     }

Added: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRule.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRule.java?rev=1081151&view=auto
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRule.java (added)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRule.java Sun Mar 13 16:58:31 2011
@@ -0,0 +1,84 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *  
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *  
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License. 
+ *  
+ */
+package org.apache.directory.shared.ldap.model.schema;
+
+
+/**
+ * 
+ * 
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public interface MutableMatchingRule extends MutableSchemaObject, MatchingRule
+{
+    /**
+     * Sets the Syntax's OID
+     *
+     * @param oid The Syntax's OID
+     */
+    void setSyntaxOid( String oid );
+
+
+    /**
+     * Sets the Syntax
+     *
+     * @param ldapSyntax The Syntax
+     */
+    void setSyntax( MutableLdapSyntax ldapSyntax );
+    
+    
+    /**
+     * {@inheritDoc}
+     */
+    MutableLdapSyntax getSyntax();
+
+    
+    /**
+     * Sets the LdapComparator
+     *
+     * @param ldapComparator The LdapComparator
+     */
+    void setLdapComparator( MutableLdapComparator<?> ldapComparator );
+
+    
+    /**
+     * {@inheritDoc}
+     */
+    MutableLdapComparator<Object> getLdapComparator();
+
+    
+    /**
+     * Sets the Normalizer
+     *
+     * @param normalizer The Normalizer
+     */
+    void setNormalizer( MutableNormalizer normalizer );
+
+    
+    /**
+     * {@inheritDoc}
+     */
+    MutableNormalizer getNormalizer();
+    
+
+    /**
+     * {@inheritDoc}
+     */
+    MutableMatchingRule copy();
+}
\ No newline at end of file

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRuleImpl.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRuleImpl.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRuleImpl.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableMatchingRuleImpl.java Sun Mar 13 16:58:31 2011
@@ -22,8 +22,6 @@ package org.apache.directory.shared.ldap
 
 import java.util.List;
 
-import javax.naming.NamingException;
-
 import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.model.exception.LdapException;
 import org.apache.directory.shared.ldap.model.exception.LdapSchemaException;
@@ -85,7 +83,7 @@ import org.slf4j.LoggerFactory;
  * @see DescriptionUtils#getDescription(MutableMatchingRuleImpl)
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class MutableMatchingRuleImpl extends AbstractMutableSchemaObject implements MatchingRule
+public class MutableMatchingRuleImpl extends AbstractMutableSchemaObject implements MutableMatchingRule
 {
     private static final long serialVersionUID = 1L;
 
@@ -93,7 +91,7 @@ public class MutableMatchingRuleImpl ext
     private static final Logger LOG = LoggerFactory.getLogger( MutableMatchingRuleImpl.class );
 
     /** The associated Comparator */
-    protected AbstractLdapComparator<? super Object> ldapComparator;
+    protected MutableLdapComparator<? super Object> ldapComparator;
 
     /** The associated Normalizer */
     protected MutableNormalizer normalizer;
@@ -231,8 +229,8 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /* (non-Javadoc)
-     * @see org.apache.directory.shared.ldap.model.schema.MatchingRule#getSyntax()
+    /**
+     * {@inheritDoc}
      */
     public MutableLdapSyntax getSyntax()
     {
@@ -240,8 +238,8 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /* (non-Javadoc)
-     * @see org.apache.directory.shared.ldap.model.schema.MatchingRule#getSyntaxOid()
+    /**
+     * {@inheritDoc}
      */
     public String getSyntaxOid()
     {
@@ -249,10 +247,8 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /**
-     * Sets the Syntax's OID
-     *
-     * @param oid The Syntax's OID
+    /* (non-Javadoc)
+     * @see org.apache.directory.shared.ldap.model.schema.MutableMatchingRule#setSyntaxOid(java.lang.String)
      */
     public void setSyntaxOid( String oid )
     {
@@ -268,12 +264,10 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /**
-     * Sets the Syntax
-     *
-     * @param ldapSyntax The Syntax
+    /* (non-Javadoc)
+     * @see org.apache.directory.shared.ldap.model.schema.MutableMatchingRule#setSyntax(org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl)
      */
-    public void setSyntax( MutableLdapSyntaxImpl ldapSyntax )
+    public void setSyntax( MutableLdapSyntax ldapSyntax )
     {
         if ( locked )
         {
@@ -305,22 +299,20 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /* (non-Javadoc)
-     * @see org.apache.directory.shared.ldap.model.schema.MatchingRule#getLdapComparator()
+    /**
+     * {@inheritDoc}
      */
-    public AbstractLdapComparator<? super Object> getLdapComparator()
+    public MutableLdapComparator<? super Object> getLdapComparator()
     {
         return ldapComparator;
     }
 
 
-    /**
-     * Sets the LdapComparator
-     *
-     * @param ldapComparator The LdapComparator
+    /* (non-Javadoc)
+     * @see org.apache.directory.shared.ldap.model.schema.MutableMatchingRule#setLdapComparator(org.apache.directory.shared.ldap.model.schema.AbstractLdapComparator)
      */
     @SuppressWarnings("unchecked")
-    public void setLdapComparator( AbstractLdapComparator<?> ldapComparator )
+    public void setLdapComparator( MutableLdapComparator<?> ldapComparator )
     {
         if ( locked )
         {
@@ -351,8 +343,8 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /* (non-Javadoc)
-     * @see org.apache.directory.shared.ldap.model.schema.MatchingRule#getNormalizer()
+    /**
+     * {@inheritDoc}
      */
     public MutableNormalizer getNormalizer()
     {
@@ -361,11 +353,9 @@ public class MutableMatchingRuleImpl ext
 
 
     /**
-     * Sets the Normalizer
-     *
-     * @param normalizer The Normalizer
+     * {@inheritDoc}
      */
-    public void setNormalizer( AbstractNormalizer normalizer )
+    public void setNormalizer( MutableNormalizer normalizer )
     {
         if ( locked )
         {
@@ -404,10 +394,10 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /* (non-Javadoc)
-     * @see org.apache.directory.shared.ldap.model.schema.MatchingRule#copy()
+    /**
+     * {@inheritDoc}
      */
-    public MatchingRule copy()
+    public MutableMatchingRuleImpl copy()
     {
         MutableMatchingRuleImpl copy = new MutableMatchingRuleImpl( oid );
 
@@ -502,8 +492,8 @@ public class MutableMatchingRuleImpl ext
     }
 
 
-    /**
-     * {@inheritDoc}
+    /* (non-Javadoc)
+     * @see org.apache.directory.shared.ldap.model.schema.MutableMatchingRule#clear()
      */
     public void clear()
     {

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableSchemaObject.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableSchemaObject.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableSchemaObject.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/MutableSchemaObject.java Sun Mar 13 16:58:31 2011
@@ -87,7 +87,7 @@ public interface MutableSchemaObject ext
      * 
      * {@inheritDoc}
      */
-    MutableSchemaObject copy();
+    MutableSchemaObject copyMutable();
     
 
     /**
@@ -148,6 +148,15 @@ public interface MutableSchemaObject ext
 
 
     /**
+     * Sets the list of names for this SchemaObject. The names are
+     * lower cased and trimmed.
+     *  
+     * @param names The list of names. Can be empty
+     */
+    void setNames( String...names );
+
+
+    /**
      * Sets the SchemaObject's specification
      * 
      * @param specification The SchemaObject's specification

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaManager.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaManager.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaManager.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaManager.java Sun Mar 13 16:58:31 2011
@@ -460,7 +460,7 @@ public interface SchemaManager
      * @return The found Comparator 
      * @throws LdapException if the OID is not found in the Comparator registry
      */
-    AbstractLdapComparator<?> lookupComparatorRegistry( String oid ) throws LdapException;
+    MutableLdapComparator<?> lookupComparatorRegistry( String oid ) throws LdapException;
 
 
     /**
@@ -470,7 +470,7 @@ public interface SchemaManager
      * @return The found MatchingRule 
      * @throws LdapException if the OID is not found in the MatchingRule registry
      */
-    MutableMatchingRuleImpl lookupMatchingRuleRegistry( String oid ) throws LdapException;
+    MutableMatchingRule lookupMatchingRuleRegistry( String oid ) throws LdapException;
 
 
     /**
@@ -526,7 +526,7 @@ public interface SchemaManager
      * 
      * @return A reference to the Comparator registry.
      */
-    ComparatorRegistry getComparatorRegistry();
+    ComparatorRegistry<LdapComparator<?>> getComparatorRegistry();
 
 
     /**
@@ -550,7 +550,7 @@ public interface SchemaManager
      * 
      * @return A reference to the MatchingRule registry.
      */
-    MatchingRuleRegistry getMatchingRuleRegistry();
+    MatchingRuleRegistry<MatchingRule> getMatchingRuleRegistry();
 
 
     /**
@@ -590,7 +590,7 @@ public interface SchemaManager
      * 
      * @return A reference to the LdapSyntax registry.
      */
-    LdapSyntaxRegistry<MutableLdapSyntax> getLdapSyntaxRegistry();
+    LdapSyntaxRegistry<LdapSyntax> getLdapSyntaxRegistry();
 
 
     /**

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaUtils.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaUtils.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/SchemaUtils.java Sun Mar 13 16:58:31 2011
@@ -756,7 +756,7 @@ public final class SchemaUtils
      * @throws LdapException if there are problems accessing the objects
      * associated with the MatchingRule.
      */
-    public static StringBuffer render( MutableMatchingRuleImpl mr ) throws LdapException
+    public static StringBuffer render( MatchingRule mr ) throws LdapException
     {
         StringBuffer buf = new StringBuffer();
         buf.append( "( " ).append( mr.getOid() );

Modified: directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/normalizers/ConcreteNameComponentNormalizer.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/normalizers/ConcreteNameComponentNormalizer.java?rev=1081151&r1=1081150&r2=1081151&view=diff
==============================================================================
--- directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/normalizers/ConcreteNameComponentNormalizer.java (original)
+++ directory/shared/branches/akarasulu/ldap/model/src/main/java/org/apache/directory/shared/ldap/model/schema/normalizers/ConcreteNameComponentNormalizer.java Sun Mar 13 16:58:31 2011
@@ -27,7 +27,7 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.model.exception.LdapException;
 import org.apache.directory.shared.ldap.model.name.NameComponentNormalizer;
 import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
 import org.apache.directory.shared.ldap.model.schema.Normalizer;
 import org.apache.directory.shared.ldap.model.schema.SchemaManager;
 import org.apache.directory.shared.util.Hex;
@@ -195,7 +195,7 @@ public class ConcreteNameComponentNormal
     private Normalizer lookup( String id ) throws LdapException
     {
         AttributeType type = schemaManager.lookupAttributeTypeRegistry( id );
-        MutableMatchingRuleImpl mrule = type.getEquality();
+        MatchingRule mrule = type.getEquality();
         
         if ( mrule == null )
         {



Mime
View raw message