directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r514789 - /directory/shared/branches/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
Date Mon, 05 Mar 2007 18:34:10 GMT
Author: elecharny
Date: Mon Mar  5 10:34:09 2007
New Revision: 514789

URL: http://svn.apache.org/viewvc?view=rev&rev=514789
Log:
replaced the getType() method by a call to the getNormType() or getUpType()
methods.

Modified:
    directory/shared/branches/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java

Modified: directory/shared/branches/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java?view=diff&rev=514789&r1=514788&r2=514789
==============================================================================
--- directory/shared/branches/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
(original)
+++ directory/shared/branches/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/name/LdapDN.java
Mon Mar  5 10:34:09 2007
@@ -1261,14 +1261,14 @@
    private static AttributeTypeAndValue atavOidToName( AttributeTypeAndValue atav, Map oidsMap
)
        throws InvalidNameException, NamingException
    {
-       String type = StringTools.trim( atav.getType() );
+       String type = StringTools.trim( atav.getNormType() );
 
        if ( ( type.startsWith( "oid." ) ) || ( type.startsWith( "OID." ) ) )
        {
            type = type.substring( 4 );
        }
 
-       if ( StringTools.isNotEmpty( StringTools.lowerCase( type ) ) )
+       if ( StringTools.isNotEmpty( type ) )
        {
            if ( oidsMap == null )
            {
@@ -1328,20 +1328,20 @@
            {
                Object val = atavs.next();
                AttributeTypeAndValue newAtav = atavOidToName( ( AttributeTypeAndValue ) val,
oidsMap );
-               rdn.addAttributeTypeAndValue( newAtav.getType(), newAtav.getValue() );
+               rdn.addAttributeTypeAndValue( newAtav.getUpType(), newAtav.getValue() );
            }
 
        }
        else
        {
-           String type = StringTools.trim( rdn.getType() );
+           String type = rdn.getNormType();
 
            if ( ( type.startsWith( "oid." ) ) || ( type.startsWith( "OID." ) ) )
            {
                type = type.substring( 4 );
            }
 
-           if ( StringTools.isNotEmpty( StringTools.lowerCase( type ) ) )
+           if ( StringTools.isNotEmpty( type ) )
            {
                if ( oidsMap == null )
                {
@@ -1357,11 +1357,11 @@
                        Rdn rdnCopy = ( Rdn ) rdn.clone();
                        rdn.clear();
                        Object value = rdnCopy.getValue();
-                       value = DefaultStringNormalizer.normalizeString( ( String ) value
);
+                       Object normValue = DefaultStringNormalizer.normalizeString( ( String
) value );
 
                        rdn.addAttributeTypeAndValue( oidNormalizer.getAttributeTypeOid(),
                            ( String ) oidNormalizer.getNormalizer()
-                           .normalize( value ) );
+                           .normalize( normValue ) );
 
                    }
                    else



Mime
View raw message