org.apache.directory.api.ldap.model.schema.normalizers
Class RegexNormalizer
java.lang.Object
org.apache.directory.api.ldap.model.schema.AbstractSchemaObject
org.apache.directory.api.ldap.model.schema.LoadableSchemaObject
org.apache.directory.api.ldap.model.schema.Normalizer
org.apache.directory.api.ldap.model.schema.normalizers.RegexNormalizer
- All Implemented Interfaces:
- Serializable, SchemaObject
public class RegexNormalizer
- extends Normalizer
A Normalizer that uses Perl5 based regular expressions to normalize values.
- Author:
- Apache Directory Project
- See Also:
- Serialized Form
| Fields inherited from class org.apache.directory.api.ldap.model.schema.AbstractSchemaObject |
description, extensions, isEnabled, isObsolete, isReadOnly, locked, names, objectType, oid, schemaName, specification |
| Methods inherited from class org.apache.directory.api.ldap.model.schema.AbstractSchemaObject |
addExtension, addExtension, addName, clear, compareOid, copy, getDescription, getExtensions, getName, getNames, getObjectType, getOid, getSchemaName, getSpecification, hashCode, isDisabled, isEnabled, isObsolete, isReadOnly, lock, setDescription, setEnabled, setExtensions, setNames, setNames, setObsolete, setOid, setReadOnly, setSchemaName, setSpecification, unlock |
RegexNormalizer
public RegexNormalizer(String oid,
Pattern[] regexes)
- Creates a Perl5 regular expression based normalizer.
- Parameters:
oid - The MR OID to use for this Normalizerregexes - the set of regular expressions used to transform values
normalize
public Value<?> normalize(Value<?> value)
- Gets the normalized value.
- Specified by:
normalize in class Normalizer
- Parameters:
value - the value to normalize. It must *not* be null !
- Returns:
- the normalized form for a value
normalize
public String normalize(String value)
- Gets the normalized value.
- Specified by:
normalize in class Normalizer
- Parameters:
value - the value to normalize. It must *not* be null !
- Returns:
- the normalized form for a value
toString
public String toString()
- Description copied from class:
Normalizer
-
- Overrides:
toString in class Normalizer
- See Also:
Object.toString()
Copyright © 2003-2013 The Apache Software Foundation. All Rights Reserved.