1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 /***
18 * Created on Jan 13, 2004
19 *
20 *
21 * @author
22 */
23 package org.apache.jetspeed.deployment.simpleregistry;
24
25 import java.util.Collection;
26
27 /***
28 * <p>
29 * SimpleRegistry
30 * </p>
31 * <p>
32 * This is an interface for creating simple registry systems. A good example would be an
33 * in memory registry that gets populate at runtime and is lost on shutdown.
34 *
35 * @author <a href="mailto:weaver@apache.org">Scott T. Weaver</a>
36 * @version $Id: SimpleRegistry.java 516881 2007-03-11 10:34:21Z ate $
37 *
38 */
39 public interface SimpleRegistry
40 {
41 /***
42 * Registers the entry.
43 *
44 * @throws java.lang.IllegalAgrumentException in <code>entry</code> is null or
45 * <code>entry.getId()</code> is null
46 * @throws org.apache.jetspeed.cps.simpleregistry if this <code>entry</code> is
47 * already registered.
48 * @param entry
49 */
50 public void register(Entry entry) throws SimpleRegistryException;
51
52 /***
53 * De-registers the entry
54 * @param entry
55 * @throws java.lang.IllegalAgrumentException in <code>entry</code> is null or
56 * <code>entry.getId()</code> is null
57 */
58 public void deRegister(Entry entry);
59
60 /***
61 * Verifies whether or not this entry is registered.
62 * @param entry
63 *
64 * @return boolean <code>true</code> is the <code>entry</code> is registered
65 * otherwise <code>false</code>.
66 * @throws java.lang.IllegalAgrumentException in <code>entry</code> is null or
67 * <code>entry.getId()</code> is null
68 */
69 public boolean isRegistered(Entry entry);
70
71 /***
72 * Provides a Cloolection of <code>org.apache.jetspeed.cps.simpleregistry.Entry</code>
73 * objects that are currently registered to this registery
74 * @return
75 */
76 public Collection getRegistry();
77
78 }