org.apache.directory.shared.ldap.name
Interface NameComponentNormalizer

All Known Implementing Classes:
SimpleNameComponentNormalizer

public interface NameComponentNormalizer

Normalizers of ldap name component attributes and their values.

Version:
$Revision: 437312 $
Author:
Apache Directory Project

Method Summary
 boolean isDefined(java.lang.String id)
          Checks to see if an attribute name/oid is defined.
 java.lang.Object normalizeByName(java.lang.String attributeName, byte[] value)
          Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.
 java.lang.Object normalizeByName(java.lang.String attributeName, java.lang.String value)
          Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.
 java.lang.Object normalizeByOid(java.lang.String attributeOid, byte[] value)
          Normalizes an attribute's value given the OID of the attribute.
 java.lang.Object normalizeByOid(java.lang.String attributeOid, java.lang.String value)
          Normalizes an attribute's value given the OID of the attribute.
 java.lang.String normalizeName(java.lang.String attributeName)
          Normalizes the attribute name/alias to use the OID for it instead.
 

Method Detail

isDefined

boolean isDefined(java.lang.String id)
Checks to see if an attribute name/oid is defined.

Parameters:
id - the name/oid of the attribute to see if it is defined
Returns:
true if it is, false otherwise

normalizeName

java.lang.String normalizeName(java.lang.String attributeName)
                               throws javax.naming.NamingException
Normalizes the attribute name/alias to use the OID for it instead.

Parameters:
attributeName - the name or OID of the attributeType
Returns:
the OID of the attributeType if it is recognized
Throws:
javax.naming.NamingException - if the attributeName is not recognized as a valid alias

normalizeByName

java.lang.Object normalizeByName(java.lang.String attributeName,
                                 java.lang.String value)
                                 throws javax.naming.NamingException
Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.

Parameters:
attributeName - the name of the attribute
value - the value of the attribute to normalize
Returns:
the normalized value
Throws:
javax.naming.NamingException - if there is a recognition problem or a syntax issue

normalizeByName

java.lang.Object normalizeByName(java.lang.String attributeName,
                                 byte[] value)
                                 throws javax.naming.NamingException
Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.

Parameters:
attributeName - the name of the attribute
value - the value of the attribute to normalize
Returns:
the normalized value
Throws:
javax.naming.NamingException - if there is a recognition problem or a syntax issue

normalizeByOid

java.lang.Object normalizeByOid(java.lang.String attributeOid,
                                java.lang.String value)
                                throws javax.naming.NamingException
Normalizes an attribute's value given the OID of the attribute.

Parameters:
attributeOid - the OID of the attribute
value - the value of the attribute to normalize
Returns:
the normalized value
Throws:
javax.naming.NamingException - if there is a recognition problem or a syntax issue

normalizeByOid

java.lang.Object normalizeByOid(java.lang.String attributeOid,
                                byte[] value)
                                throws javax.naming.NamingException
Normalizes an attribute's value given the OID of the attribute.

Parameters:
attributeOid - the OID of the attribute
value - the value of the attribute to normalize
Returns:
the normalized value
Throws:
javax.naming.NamingException - if there is a recognition problem or a syntax issue


Copyright © 2004-2009. All Rights Reserved.