Class AbstractWizardPane

    • Field Detail

      • m_Logger

        protected Logger m_Logger
        the logger to use.
      • m_ID

        protected String m_ID
        the ID of the wizard.
      • m_PanelButtons

        protected JPanel m_PanelButtons
        the panel for the buttons.
      • m_ButtonBack

        protected BaseButton m_ButtonBack
        the button for the previous page.
      • m_ButtonNext

        protected BaseButton m_ButtonNext
        the button for the next page.
      • m_ButtonCancelFinish

        protected BaseButton m_ButtonCancelFinish
        the button for the cancelling/finishing.
      • m_ActionListeners

        protected HashSet<ActionListener> m_ActionListeners
        the action listeners (ie hitting cancel/finish).
      • m_CustomFinishText

        protected String m_CustomFinishText
        the custom text for the "finish" button.
      • m_PanelButtonsProperties

        protected JPanel m_PanelButtonsProperties
        the panel for the properties buttons.
      • m_ButtonLoad

        protected BaseButton m_ButtonLoad
        the load props button.
      • m_ButtonSave

        protected BaseButton m_ButtonSave
        the save props button.
      • m_FileChooser

        protected BaseFileChooser m_FileChooser
        the filechooser for loading/saving properties.
    • Constructor Detail

      • AbstractWizardPane

        public AbstractWizardPane()
        Initializes the wizard with no ID.
      • AbstractWizardPane

        public AbstractWizardPane​(String id)
        Initializes the wizard.
        Parameters:
        id - the ID of the wizard, used for logging purposes
    • Method Detail

      • initialize

        protected void initialize()
        Initializes the members.
        Overrides:
        initialize in class BasePanel
      • initGUI

        protected void initGUI()
        Initializes the widgets.
        Overrides:
        initGUI in class BasePanel
      • finishInit

        protected void finishInit()
        Finishes the initialization.
        Overrides:
        finishInit in class BasePanel
      • previousPage

        protected abstract void previousPage()
        Goes to the previous page.
      • nextPage

        protected abstract void nextPage()
        Goes to the next page.
      • cancelFinish

        protected void cancelFinish()
        Gets called when the cancel/finish button gets clicked.
      • getID

        public String getID()
        Returns the ID of the wizard, if any.
        Returns:
        the ID
      • removeAllPages

        public void removeAllPages()
        Removes all pages.
      • addPage

        public void addPage​(AbstractWizardPage page)
        Adds the page under the given name.
        Parameters:
        page - the page
      • getSelectedPage

        public abstract AbstractWizardPage getSelectedPage()
        Returns the currently active page.
        Returns:
        the page, null if not available
      • setProperties

        public void setProperties​(Properties props,
                                  boolean usePrefix)
        Sets the properties of all the pages.
        Parameters:
        props - the combined properties
        usePrefix - whether to use the page name as prefix
      • getProperties

        public Properties getProperties​(boolean usePrefix)
        Returns the properties from all the pages.
        Parameters:
        usePrefix - whether to use the page name as prefix
        Returns:
        the combined properties
      • updateButtons

        public abstract void updateButtons()
        Updates the status of the buttons.
      • getFileChooser

        protected BaseFileChooser getFileChooser()
        Returns the file chooser to use for loading/saving of props files.
        Returns:
        the file chooser
      • loadProperties

        protected void loadProperties()
        Loads properties from a file, prompts the user to select props file.
      • saveProperties

        protected void saveProperties()
        Saves properties to a file, prompts the user to select props file.
      • addActionListener

        public void addActionListener​(ActionListener l)
        Adds the specified listener.
        Parameters:
        l - the listener to add
      • removeActionListener

        public void removeActionListener​(ActionListener l)
        Removes the specified listener.
        Parameters:
        l - the listener to remove
      • notifyActionListeners

        protected void notifyActionListeners​(ActionEvent e)
        Notifies all change listeners with the specified event.
        Parameters:
        e - the event to send
      • setCustomFinishText

        public void setCustomFinishText​(String value)
        Sets custom text to use for the "finish" button.
        Parameters:
        value - the text, null or empty string to use default
      • getCustomFinishText

        public String getCustomFinishText()
        Returns the custom text to use for the "finish" button, if any.
        Returns:
        the text, null if not used
      • isLoggingEnabled

        public boolean isLoggingEnabled()
        Returns whether logging is enabled.
        Specified by:
        isLoggingEnabled in interface LoggingSupporter
        Returns:
        always true