|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface ContextMapper
An interface used by LdapTemplate to map LDAP Contexts to beans. Responsible
for mapping from LDAP Contexts to beans. When a DirObjectFactory is set on
the ContextSource, the objects returned from search and
listBindings operations are automatically transformed to
DirContext objects (when using the DefaultDirObjectFactory, you get
a DirContextAdapter object). This object will then be passed to the
ContextMapper implementation for transformation to the desired bean.
ContextMapper implementations are typically stateless and thus reusable; they are ideal for implementing mapping logic in one place.
Alternatively, consider using an AttributesMapper in stead.
LdapTemplate.search(Name, String,
ContextMapper),
LdapTemplate.listBindings(Name, ContextMapper),
LdapTemplate.lookup(Name, ContextMapper),
AttributesMapper,
DefaultDirObjectFactory,
DirContextAdapter| Method Summary | |
|---|---|
java.lang.Object |
mapFromContext(java.lang.Object ctx)
Map a single LDAP Context to an object. |
| Method Detail |
|---|
java.lang.Object mapFromContext(java.lang.Object ctx)
ctx is the object from a single SearchResult,
Binding, or a lookup operation.
ctx - the context to map to an object.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||