public final class Syntax extends Object
Syntax implementations must extend the SyntaxImpl interface so they
can be used by OpenDJ to validate attribute values.
Where ordered sets of names, or extra properties are provided, the ordering
will be preserved when the associated fields are accessed via their getters
or via the toString() methods.
| Modifier and Type | Class and Description |
|---|---|
static class |
Syntax.Builder
A fluent API for incrementally constructing syntaxes.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o)
Returns
true if the provided object is an attribute syntax having
the same numeric OID as this attribute syntax. |
MatchingRule |
getApproximateMatchingRule()
Retrieves the default approximate matching rule that will be used for
attributes with this syntax.
|
String |
getDescription()
Returns the description of this schema element, or the empty string if it
does not have a description.
|
MatchingRule |
getEqualityMatchingRule()
Retrieves the default equality matching rule that will be used for
attributes with this syntax.
|
Map<String,List<String>> |
getExtraProperties()
Returns an unmodifiable map containing all of the extra properties
associated with this schema element.
|
String |
getName()
Retrieves the name for this attribute syntax.
|
String |
getOID()
Retrieves the OID for this attribute syntax.
|
MatchingRule |
getOrderingMatchingRule()
Retrieves the default ordering matching rule that will be used for
attributes with this syntax.
|
MatchingRule |
getSubstringMatchingRule()
Retrieves the default substring matching rule that will be used for
attributes with this syntax.
|
int |
hashCode()
Returns the hash code for this attribute syntax.
|
boolean |
isBEREncodingRequired()
Indicates whether this attribute syntax requires that values must be
encoded using the Basic Encoding Rules (BER) used by X.500 directories
and always include the
binary attribute description option. |
boolean |
isHumanReadable()
Indicates whether this attribute syntax would likely be a human readable
string.
|
String |
toString()
Returns the string representation of this schema element as defined in
RFC 2252.
|
boolean |
valueIsAcceptable(ByteSequence value,
LocalizableMessageBuilder invalidReason)
Indicates whether the provided value is acceptable for use in an
attribute with this syntax.
|
public boolean equals(Object o)
true if the provided object is an attribute syntax having
the same numeric OID as this attribute syntax.o - The object to be compared.true if the provided object is an attribute syntax having
the same numeric OID as this attribute syntax.public MatchingRule getApproximateMatchingRule()
null if approximate
matches will not be allowed for this type by default.public MatchingRule getEqualityMatchingRule()
null if equality matches
will not be allowed for this type by default.public String getOID()
public String getName()
public MatchingRule getOrderingMatchingRule()
null if ordering matches
will not be allowed for this type by default.public MatchingRule getSubstringMatchingRule()
null if substring matches
will not be allowed for this type by default.public int hashCode()
public boolean isBEREncodingRequired()
binary attribute description option.true this attribute syntax requires that values must be
BER encoded and always include the binary attribute
description option, or false if not.public boolean isHumanReadable()
true if this attribute syntax would likely be a human
readable string or false if not.public boolean valueIsAcceptable(ByteSequence value, LocalizableMessageBuilder invalidReason)
value - The value for which to make the determination.invalidReason - The buffer to which the invalid reason should be appended.true if the provided value is acceptable for use with
this syntax, or false if not.public final String getDescription()
public final Map<String,List<String>> getExtraProperties()
Copyright © 2011-2015 ForgeRock AS. All Rights Reserved.