summaryrefslogtreecommitdiff
path: root/src/com/memberwebs/ldapxml/LXHook.java
blob: 2c8cff7e35344002b9271e17017568bb49e754ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package com.memberwebs.ldapxml;

import org.w3c.dom.Element;

import com.novell.ldap.LDAPEntry;

/**
 * Interface for hooking into LX processing.
 *
 * @author nielsen@memberwebs.com
 * @version 0.5
 */
public interface LXHook
{
    /**
     * Initialize this hook.
     *
     * @param obj An initialization parameter passed into LXSpecs.setData
     */
    public void initialize(Object obj)
            throws LXException;

    /**
     * Allows pre processing of an entry retrieved from LDAP
     *
     * @param entry The LDAP entry retrieved
     * @return If false then this element will not be included in tree.
     */
    public boolean prefix(LDAPEntry entry)
            throws LXException;

    /**
     * Allows post processing of an element retrieved from LDAP.
     *
     * @param entry The LDAP entry retrieved.
     * @param el The DOM element constructed.
     * @return If false then this element will not be included in tree.
     */
    public boolean postfix(LDAPEntry entry, Element el)
            throws LXException;
}