1 package org.apache.jcs.engine.behavior;
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22 /***
23 * ShutdownObservers can observer ShutdownObservable objects.
24 * The CacheManager is the primary observable that this is intended for.
25 * <p>
26 * Most shutdown operations will occur outside this framework for now. The initial
27 * goal is to allow background threads that are not reachable through any reference
28 * that the cahe manager maintains to be killed on shutdown.
29 * <p>
30 * Perhaps the composite cache itself should be the observable object.
31 * It doesn't make much of a difference. There are some problems with
32 * region by region shutdown. Some auxiliaries are glocal. They will
33 * need to track when every region has shutdown before doing things like
34 * closing the socket with a lateral.
35 * <p>
36 * @author Aaron Smuts
37 *
38 */
39 public interface IShutdownObservable
40 {
41
42 /***
43 * Registers an observer with the observable object.
44 * @param observer
45 */
46 abstract void registerShutdownObserver( IShutdownObserver observer );
47
48 /***
49 * Deregisters the observer with the observable.
50 *
51 * @param observer
52 */
53 abstract void deregisterShutdownObserver( IShutdownObserver observer );
54
55 }