package com.onaro.util.jfc.wizard; import java.awt.Component; import java.beans.PropertyChangeListener; import java.net.URL; /** * A step in a multi step data entry wizard. A step is a three part dialog providing * a description, data entry and buttons. *

* The step implementation should issue ProperyChangeEvenet whenever * the data entered becomes valid or invalid. Doing so will allow the wizard to * control the buttons. */ public interface WizardStep { /** * Property name for listening to step validity state changes. */ public static final String PROPERTY_VALID = "valid"; //$NON-NLS-1$ /** * Gets the title of this step. * * @return this step's title */ public String getTitle(); /** * Gets a URL to an HTML file containing the description of this step. * * @return a URL to the HTML description file or null if not * exists. */ public URL getDescriptionUrl() ; public Component getDescriptionComponent(); /** * Gets the data entry component. * * @return the component displaying the data entry for this step */ public Component getDataEntry(); /** * Tests if the data entered in this step is valid. * * @return true if the data entered is valid and the wizard can proceed to * the next step or finish */ public boolean isValid(); /** * Gets the next step after this one. * * @return the next WizardStep or null if this is the last */ public WizardStep getNext(); /** * Adds a property change listener for this step. * * @param l the listener */ public void addPropertyChangeListener(PropertyChangeListener l); /** * Removes a property change listener from this step. * * @param l the listener */ public void removePropertyChangeListener(PropertyChangeListener l); /** * notify the wizard step to stop the editing in its component * */ public void stopEditing(); }