com.izforge.izpack.installer.console
Interface ConsolePanel

All Known Implementing Classes:
AbstractConsolePanel, AbstractTextConsolePanel, NoOpConsolePanel

public interface ConsolePanel

Defines the Interface that must be implemented for running Panels in console mode.

Implementing classes MUST NOT link against AWT/Swing classes. Thus the panels cannot implement this interface directly, they should use e.g. helper classes instead.

Author:
Mounir El Hajj, Tim Anderon

Method Summary
 void createInstallationRecord(IXMLElement rootElement)
          Create th auto-xml
 boolean generateOptions(InstallData installData, Options options)
          Generates a properties file for each input field or variable.
 boolean handlePanelValidationResult(boolean valid)
          Do some user interaction on the console depending on the result of a panel validation.
 boolean run(InstallData installData, Console console)
          Runs the panel in an interactive console.
 boolean run(InstallData installData, Properties properties)
          Runs the panel using the supplied properties.
 

Method Detail

generateOptions

boolean generateOptions(InstallData installData,
                        Options options)
Generates a properties file for each input field or variable.

Parameters:
installData - the installation data
options - the options file to write to
Returns:
true if the generation is successful, otherwise false

run

boolean run(InstallData installData,
            Properties properties)
Runs the panel using the supplied properties.

Parameters:
installData - the installation data
properties - the properties
Returns:
true if the installation is successful, otherwise false

run

boolean run(InstallData installData,
            Console console)
Runs the panel in an interactive console.

Parameters:
installData - the installation data
console - the console
Returns:
true if the panel ran successfully, otherwise false

createInstallationRecord

void createInstallationRecord(IXMLElement rootElement)
Create th auto-xml

Parameters:
rootElement -

handlePanelValidationResult

boolean handlePanelValidationResult(boolean valid)
Do some user interaction on the console depending on the result of a panel validation. This is necessary to inform the user on the console about the forbidden progress and to prevent failing the installer in case the panel data validator treats the data to be wrong. Instead the user should be asked whether to redisplay the input fields to fix the wrong values.

Parameters:
valid - whether the validation has been successful
Returns:
false - let the installer fail, true - let the installer continue to run
See Also:
DataValidator


Copyright © 2018. All rights reserved.