summaryrefslogtreecommitdiff
path: root/src/net/tuschhcm/routercontrol/ui/UserInterface.java
blob: 7a441c58863cc52c2a60340b4c3a6778f0d365dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package net.tuschhcm.routercontrol.ui;

/**
 * Interface specification for the view.
 */
public interface UserInterface {
	/**
	 * Tell the user interface about a preset.
	 * 
	 * @param number Preset number
	 * @param name Preset name
	 */
	public void addPreset(final int number, final String name);
	
	/**
	 * Set the action handler called when a preset is selected.
	 * @param action
	 */
	public void setPresetSelectionAction(final Action action);
	
	/**
	 * @return the selected preset.
	 */
	public int getSelectedPreset();
	
	/**
	 * Handle toggling the control lock
	 */
	public void setControlsLockAction(final Action action);
	
	/**
	 * Start the user interface.
	 */
	public void run();
	
	/**
	 * Interface specification for an action handler.
	 */
	public interface Action {
		public void onAction();
	}
}