directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r807560 - in /directory/shared/branches/shared-schema/ldap/src: main/java/org/apache/directory/shared/ldap/schema/ main/java/org/apache/directory/shared/ldap/schema/parsers/ test/java/org/apache/directory/shared/ldap/schema/syntax/parser/
Date Tue, 25 Aug 2009 11:16:58 GMT
Author: elecharny
Date: Tue Aug 25 11:16:58 2009
New Revision: 807560

URL: http://svn.apache.org/viewvc?rev=807560&view=rev
Log:
The getSyntaxOid method does not throw anymore a NamingException. Remoived e reference to
the MatchingRulmeDescription class

Modified:
    directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/MatchingRule.java
    directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/parsers/ParserDescriptionUtils.java
    directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/schema/syntax/parser/SchemaParserTestUtils.java

Modified: directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/MatchingRule.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/MatchingRule.java?rev=807560&r1=807559&r2=807560&view=diff
==============================================================================
--- directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/MatchingRule.java
(original)
+++ directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/MatchingRule.java
Tue Aug 25 11:16:58 2009
@@ -145,7 +145,7 @@
      * @return the LdapSyntax of this MatchingRule
      * @throws NamingException if there is a failure resolving the object
      */
-    public String getSyntaxOid() throws NamingException
+    public String getSyntaxOid()
     {
         return ldapSyntaxOid;
     }

Modified: directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/parsers/ParserDescriptionUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/parsers/ParserDescriptionUtils.java?rev=807560&r1=807559&r2=807560&view=diff
==============================================================================
--- directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/parsers/ParserDescriptionUtils.java
(original)
+++ directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/parsers/ParserDescriptionUtils.java
Tue Aug 25 11:16:58 2009
@@ -24,6 +24,7 @@
 
 import org.apache.directory.shared.ldap.schema.LdapSyntax;
 import org.apache.directory.shared.ldap.schema.LoadableSchemaObject;
+import org.apache.directory.shared.ldap.schema.MatchingRule;
 import org.apache.directory.shared.ldap.schema.SchemaObject;
 
 
@@ -180,16 +181,16 @@
      * @param mrd1 the second matchingRule description to compare
      * @return true if the matchingRules match exactly, false otherwise
      */
-    public static boolean matchingRulesMatch( MatchingRuleDescription mrd0, MatchingRuleDescription
mrd1 )
+    public static boolean matchingRulesMatch( MatchingRule matchingRule0, MatchingRule matchingRule1
)
     {
         // compare all common description parameters
-        if ( ! descriptionsMatch( mrd0, mrd1 ) )
+        if ( ! descriptionsMatch( matchingRule0, matchingRule1 ) )
         {
             return false;
         }
 
         // check that the syntaxes of the matchingRules match
-        if ( ! mrd0.getSyntax().equals( mrd1.getSyntax() ) )
+        if ( ! matchingRule0.getSyntaxOid().equals( matchingRule1.getSyntaxOid() ) )
         {
             return false;
         }

Modified: directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/schema/syntax/parser/SchemaParserTestUtils.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/schema/syntax/parser/SchemaParserTestUtils.java?rev=807560&r1=807559&r2=807560&view=diff
==============================================================================
--- directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/schema/syntax/parser/SchemaParserTestUtils.java
(original)
+++ directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/schema/syntax/parser/SchemaParserTestUtils.java
Tue Aug 25 11:16:58 2009
@@ -216,14 +216,14 @@
         value = "( " + oid + " " + required + " NAME 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'
)";
         asd = parser.parse( value );
         assertEquals( 1, asd.getNames().size() );
-        assertEquals( "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz", asd.getNames().get(
0 ) );
+        assertEquals( "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ", asd.getNames().get(
0 ) );
 
         // alpha-num-hypen
         value = "( " + oid + " " + required
             + " NAME 'abcdefghijklmnopqrstuvwxyz-ABCDEFGHIJKLMNOPQRSTUVWXYZ-0123456789' )";
         asd = parser.parse( value );
         assertEquals( 1, asd.getNames().size() );
-        assertEquals( "abcdefghijklmnopqrstuvwxyz-abcdefghijklmnopqrstuvwxyz-0123456789",
asd.getNames().get( 0 ) );
+        assertEquals( "abcdefghijklmnopqrstuvwxyz-ABCDEFGHIJKLMNOPQRSTUVWXYZ-0123456789",
asd.getNames().get( 0 ) );
 
         // with parentheses
         value = "( " + oid + " " + required + " NAME ( 'a-z-0-9' ) )";



Mime
View raw message