The wizard interface.

Component Java
Build Wizards Quickly Using a Swing-Based Wizard Framework
Chang Sau Sheong
Listing 2. The wizard interface.


public interface Wizard {

public WizardData getData();

	public void putData(String key, Object value);
	public void pushFrame(Wizard frame);
	public Wizard popFrame();
	public void purgeFrames();

	public void showCancelButton(boolean show);
	public void showNextButton(boolean show);
	public void showPreviousButton(boolean show);
	public void showFinishButton(boolean show);

	public void setFrameLabel1(String newLabel);
	public void setFrameLabel2(String newLabel);

	public void cancelAction();
	public void nextAction();
	public void previousAction();
	public void finishAction();

	public void customize();
}

About the Author

Chang Sau Sheong is vice president of product engineering at elipva Ltd. (formerly known as sstarfire.com). He can be contacted at [email protected].