public final class DNPropertyDefinition extends PropertyDefinition<DN>
Modifier and Type | Class and Description |
---|---|
static class |
DNPropertyDefinition.Builder
An interface for incrementally constructing DN property
definitions.
|
PropertyDefinition.AbstractBuilder<T,D extends PropertyDefinition<T>>
Modifier and Type | Method and Description |
---|---|
<R,P> R |
accept(PropertyDefinitionVisitor<R,P> v,
P p)
Apply a visitor to this property definition.
|
<R,P> R |
accept(PropertyValueVisitor<R,P> v,
DN value,
P p)
Apply a visitor to a property value associated with this property
definition.
|
int |
compare(DN o1,
DN o2)
Compares two property values for order.
|
static DNPropertyDefinition.Builder |
createBuilder(AbstractManagedObjectDefinition<?,?> d,
String propertyName)
Create a DN property definition builder.
|
DN |
decodeValue(String value)
Parse and validate a string representation of a property value.
|
DN |
getBaseDN()
Get the base DN which all valid values must be immediately
subordinate to, or
null if there is no based DN. |
void |
validateValue(DN value)
Determine if the provided property value is valid according to
this property definition.
|
castValue, compareTo, encodeValue, equals, getAdministratorAction, getDefaultBehaviorProvider, getDescription, getDescription, getManagedObjectDefinition, getName, getSynopsis, getSynopsis, hashCode, hasOption, initialize, normalizeValue, toString, toString
public static DNPropertyDefinition.Builder createBuilder(AbstractManagedObjectDefinition<?,?> d, String propertyName)
d
- The managed object definition associated with this
property definition.propertyName
- The property name.public DN getBaseDN()
null
if there is no based DN.public void validateValue(DN value) throws PropertyException
validateValue
in class PropertyDefinition<DN>
value
- The property value (must not be null
).PropertyException
- If the property value is invalid.public DN decodeValue(String value) throws PropertyException
decodeValue
in class PropertyDefinition<DN>
value
- The property string value (must not be null
).PropertyException
- If the property value string is invalid.public <R,P> R accept(PropertyDefinitionVisitor<R,P> v, P p)
accept
in class PropertyDefinition<DN>
R
- The return type of the visitor's methods.P
- The type of the additional parameters to the visitor's
methods.v
- The property definition visitor.p
- Optional additional visitor parameter.public <R,P> R accept(PropertyValueVisitor<R,P> v, DN value, P p)
accept
in class PropertyDefinition<DN>
R
- The return type of the visitor's methods.P
- The type of the additional parameters to the visitor's
methods.v
- The property value visitor.value
- The property value.p
- Optional additional visitor parameter.public int compare(DN o1, DN o2)
This default implementation normalizes both values using
PropertyDefinition.normalizeValue(Object)
and then performs a
case-sensitive string comparison.
compare
in interface Comparator<DN>
compare
in class PropertyDefinition<DN>
o1
- the first object to be compared.o2
- the second object to be compared.Copyright © 2010-2016 ForgeRock AS. All Rights Reserved.