KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > oddjob > Structural


1 package org.oddjob;
2
3 import org.oddjob.structural.StructuralListener;
4
5 /**
6  * A class which implments this interface will inform listeners
7  * when it's structure changes. A structural change is when a child
8  * compeont is added or removed from the implmenting class. A new
9  * listener must recieve add notifications for all existing children
10  * as there is no other way to determine the existing structure of
11  * an implementing class.
12  *
13  * @author Rob Gordon
14  */

15
16 public interface Structural {
17     
18     /**
19      * Add a listener. The listener will immediately recieve add
20      * notifications for all existing children.
21      *
22      * @param listener The listener.
23      */

24     public void addStructuralListener(StructuralListener listener);
25     
26     /**
27      * Remove a listener.
28      *
29      * @param listener The listner.
30      */

31     public void removeStructuralListener(StructuralListener listener);
32 }
33
Popular Tags