1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.apache.ldap.server.schema;
18
19
20 import javax.naming.NamingException;
21 import java.util.List;
22
23
24 /***
25 * Monitor used to track notable OidRegistry events.
26 *
27 * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
28 * @version $Rev: 159259 $
29 */
30 public interface OidRegistryMonitor
31 {
32 /***
33 * Monitors situations where an OID is used to resolve an OID. The caller
34 * does not know that the argument is the same as the return value.
35 *
36 * @param oid the OID argument and return value
37 */
38 void getOidWithOid( String oid );
39
40 /***
41 * Monitors when an OID is resolved successfully for a name.
42 *
43 * @param name the name used to lookup an OID
44 * @param oid the OID returned for the name
45 */
46 void oidResolved( String name, String oid );
47
48 /***
49 * Monitors when an OID is resolved successfully by using a normalized form
50 * of the name.
51 *
52 * @param name the name used to lookup an OID
53 * @param normalized the normalized name that mapped to the OID
54 * @param oid the OID returned for the name
55 */
56 void oidResolved( String name, String normalized, String oid );
57
58 /***
59 * Monitors when resolution of an OID by name fails.
60 *
61 * @param name the name used to lookup an OID
62 * @param fault the exception thrown for the failure after this call
63 */
64 void oidResolutionFailed( String name, NamingException fault );
65
66 /***
67 * Monitors when a name lookups fail due to the use of an unknown OID.
68 *
69 * @param oid the OID used to lookup object names
70 * @param fault the exception thrown for the failure after this call
71 */
72 void oidDoesNotExist( String oid, NamingException fault );
73
74 /***
75 * Monitors situations where a primary name is resolved for a OID.
76 *
77 * @param oid the OID used for the lookup
78 * @param primaryName the primary name found for the OID
79 */
80 void nameResolved( String oid, String primaryName );
81
82 /***
83 * Monitors situations where a names are resolved for a OID.
84 *
85 * @param oid the OID used for the lookup
86 * @param names the names found for the OID
87 */
88 void namesResolved( String oid, List names );
89
90 /***
91 * Monitors the successful registration of a name for an OID.
92 *
93 * @param name the one of many names registered with an OID
94 * @param oid the OID to be associated with the name
95 */
96 void registered( String name, String oid );
97 }