Interface NameComponentNormalizer

All Known Implementing Classes:
ConcreteNameComponentNormalizer

public interface NameComponentNormalizer
Normalizers of ldap name component attributes and their values.
Author:
Apache Directory Project
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Checks to see if an attribute name/oid is defined.
    normalizeByName(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.
    normalizeByName(String attributeName, String value)
    Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.
    normalizeByName(AttributeType attributeType, String value)
    Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.
    normalizeByOid(String attributeOid, byte[] value)
    Normalizes an attribute's value given the OID of the attribute.
    normalizeByOid(String attributeOid, String value)
    Normalizes an attribute's value given the OID of the attribute.
    normalizeName(String attributeName)
    Normalizes the attribute name/alias to use the OID for it instead.
  • Method Details

    • isDefined

      boolean isDefined(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

      String normalizeName(String attributeName) throws LdapException
      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:
      LdapException - if the attributeName is not recognized as a valid alias
    • normalizeByName

      Object normalizeByName(String attributeName, String value) throws LdapException
      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:
      LdapException - if there is a recognition problem or a syntax issue
    • normalizeByName

      Object normalizeByName(AttributeType attributeType, String value) throws LdapException
      Normalizes an attribute's value given the name of the attribute - short names like 'cn' as well as 'commonName' should work here.
      Parameters:
      attributeType - the attributeType
      value - the value of the attribute to normalize
      Returns:
      the normalized value
      Throws:
      LdapException - if there is a recognition problem or a syntax issue
    • normalizeByName

      Object normalizeByName(String attributeName, byte[] value) throws LdapException
      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:
      LdapException - if there is a recognition problem or a syntax issue
    • normalizeByOid

      Object normalizeByOid(String attributeOid, String value) throws LdapException
      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:
      LdapException - if there is a recognition problem or a syntax issue
    • normalizeByOid

      Object normalizeByOid(String attributeOid, byte[] value) throws LdapException
      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:
      LdapException - if there is a recognition problem or a syntax issue