directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r663599 - /directory/studio/trunk/ldapbrowser-core/src/main/java/org/apache/directory/studio/ldapbrowser/core/model/schema/Schema.java
Date Thu, 05 Jun 2008 12:57:22 GMT
Author: seelmann
Date: Thu Jun  5 05:57:22 2008
New Revision: 663599

URL: http://svn.apache.org/viewvc?rev=663599&view=rev
Log:
Fix for DIRSTUDIO-336: Use schema parser with enabled quirks mode.

Modified:
    directory/studio/trunk/ldapbrowser-core/src/main/java/org/apache/directory/studio/ldapbrowser/core/model/schema/Schema.java

Modified: directory/studio/trunk/ldapbrowser-core/src/main/java/org/apache/directory/studio/ldapbrowser/core/model/schema/Schema.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapbrowser-core/src/main/java/org/apache/directory/studio/ldapbrowser/core/model/schema/Schema.java?rev=663599&r1=663598&r2=663599&view=diff
==============================================================================
--- directory/studio/trunk/ldapbrowser-core/src/main/java/org/apache/directory/studio/ldapbrowser/core/model/schema/Schema.java
(original)
+++ directory/studio/trunk/ldapbrowser-core/src/main/java/org/apache/directory/studio/ldapbrowser/core/model/schema/Schema.java
Thu Jun  5 05:57:22 2008
@@ -247,36 +247,41 @@
             {
                 if ( attributeName.equalsIgnoreCase( Schema.SCHEMA_ATTRIBUTE_OBJECTCLASSES
) )
                 {
-                    ObjectClassDescription ocd = new ObjectClassDescriptionSchemaParser()
-                        .parseObjectClassDescription( value );
+                    ObjectClassDescriptionSchemaParser parser = new ObjectClassDescriptionSchemaParser();
+                    parser.setQuirksMode( true );
+                    ObjectClassDescription ocd = parser.parseObjectClassDescription( value
);
                     ocd.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                     addObjectClassDescription( ocd );
                 }
                 else if ( attributeName.equalsIgnoreCase( Schema.SCHEMA_ATTRIBUTE_ATTRIBUTETYPES
) )
                 {
-                    AttributeTypeDescription atd = new AttributeTypeDescriptionSchemaParser()
-                        .parseAttributeTypeDescription( value );
+                    AttributeTypeDescriptionSchemaParser parser = new AttributeTypeDescriptionSchemaParser();
+                    parser.setQuirksMode( true );
+                    AttributeTypeDescription atd = parser.parseAttributeTypeDescription(
value );
                     atd.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                     addAttributeTypeDescription( atd );
                 }
                 else if ( attributeName.equalsIgnoreCase( Schema.SCHEMA_ATTRIBUTE_LDAPSYNTAXES
) )
                 {
-                    LdapSyntaxDescription lsd = new LdapSyntaxDescriptionSchemaParser()
-                        .parseLdapSyntaxDescription( value );
+                    LdapSyntaxDescriptionSchemaParser parser = new LdapSyntaxDescriptionSchemaParser();
+                    parser.setQuirksMode( true );
+                    LdapSyntaxDescription lsd = parser.parseLdapSyntaxDescription( value
);
                     lsd.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                     addLdapSyntaxDescription( lsd );
                 }
                 else if ( attributeName.equalsIgnoreCase( Schema.SCHEMA_ATTRIBUTE_MATCHINGRULES
) )
                 {
-                    MatchingRuleDescription mrd = new MatchingRuleDescriptionSchemaParser()
-                        .parseMatchingRuleDescription( value );
+                    MatchingRuleDescriptionSchemaParser parser = new MatchingRuleDescriptionSchemaParser();
+                    parser.setQuirksMode( true );
+                    MatchingRuleDescription mrd = parser.parseMatchingRuleDescription( value
);
                     mrd.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                     addMatchingRuleDescription( mrd );
                 }
                 else if ( attributeName.equalsIgnoreCase( Schema.SCHEMA_ATTRIBUTE_MATCHINGRULEUSE
) )
                 {
-                    MatchingRuleUseDescription mrud = new MatchingRuleUseDescriptionSchemaParser()
-                        .parseMatchingRuleUseDescription( value );
+                    MatchingRuleUseDescriptionSchemaParser parser = new MatchingRuleUseDescriptionSchemaParser();
+                    parser.setQuirksMode( true );
+                    MatchingRuleUseDescription mrud = parser.parseMatchingRuleUseDescription(
value );
                     mrud.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                     addMatchingRuleUseDescription( mrud );
                 }



Mime
View raw message