When persisting a Java object to an LDAP datastore clearly the user would like some control
over where and how in the LDAP DIT (directory information tree) we are persisting the object.
In general Java objects are mapped to LDAP entries and fields of the Java objects are mapped
to attributes of the LDAP entries.

Arrays, Collections, Sets and Lists of these data types are stored as multi-valued attributes.
Please note that when using Arrays and Lists no order could be guaranteed and no duplicate values are allowed!

For the class as a whole we use the
table
attribute to set the
distinguished name
of the container under which to store objects of a type. So, for example, we are mapping all
objects of class Group as subordinates to "ou=Groups,dc=example,dc=com".
You can also use the extension "dn" to specify the same thing.

For the class as a whole we use the
schema
attribute to define the object classes
of the LDAP entry. So, for example, all objects of type Person are mapped to the
common "top,person,organizationalPerson,inetOrgPerson" object classes in LDAP.
You can also use the extension "objectClass" to specify the same thing.

For each field we use the
column
attribute to define the
LDAP attribute
that
we are mapping this field to. So, for example, we map the Group "name" to "cn" in our LDAP.
You can also use the extension "attribute" to specify the same thing.