summaryrefslogtreecommitdiffstats
path: root/src/jrummikub/util/IEvent.java
blob: 907bf8eb87e9257419b4c3ade8610084977a1e74 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package jrummikub.util;

/** Interface for classes that can generate parameterless events */
public interface IEvent {
	/**
	 * Start to publish all events to a given listener
	 * 
	 * @param listener
	 *          target listener
	 * @return a connection to remove the listener
	 */
	public Connection add(IListener listener);

	/**
	 * Stop publishing events to a given listener
	 * 
	 * @param listener
	 *          target listener
	 */
	public void remove(IListener listener);
}