- Syntaxes

The LdapSyntax class implements the LDAP Syntaxs schema objects. A Syntax defines constraints applied to the AttributeType value. Here is the RFC description of a Syntax :

 SyntaxDescription = LPAREN WSP
     numericoid                 ; object identifier
     [ SP "DESC" SP qdstring ]  ; description
     extensions WSP RPAREN      ; extensions

The important part of the Syntax is its OID which is used in the AttributeType and MatchingRule.

In order to enforce a Syntax, the LDAP API is associated with a SyntaxChecker, which is a Java class (see the chapter about ApacheDS Schema Elements).


The are the two most important methods that you might need:

  • getSyntaxChecker() : retreive the associated class that is used to check a syntax
  • isHumanReadable() : tells if the AttributeType is a String or a byte[]