We need you!

Icon

The IzPack documentation needs work, and you are invited to edit it!

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
titleCommon Example
languagehtml/xml
<dynamicinstallerrequirements>
  <installerrequirement severity="errorERROR"
                        condition="this.condition.must.not.happen"
                        messageid="this.condition.must.not.happen.translation.id"/>
  <installerrequirement severity="errorERROR"
                        condition="this.condition.may.happen"
                        messageid="this.condition.may.happen.translation.id"/>
  ...
</dynamicinstallerrequirements>

...

If a condition applies, a messagebox is shown with the appropriate content from translation. Depending on the value of severity attribute the installation might be continued or is aborted:

  • "errorERROR"
    The messagebox is shown and the installation aborts.
  • "warningWARNING"
    The messagebox is shown and the installation can continue after the OK button is pressed.

...

Code Block
languagehtml/xml
<condition type="variable" id="isNew">
  <name>previous.version</name>
  <value>XX.XX.XX</value>
</condition>
<condition type="not" id="isUpgrade">
  <condition type="ref" refid="isNew"/>
</condition>
...
<dynamicinstallerrequirements>
  <installerrequirement condition="isUpgrade" severity="warningWARNING" messageid="not.an.upgrade.warning.message"/>
</dynamicinstallerrequirements>
...
<panels>
  <panel classname="HelloPanel"/>
  <panel classname="TargetPanel">
    <validator classname="DynamicInstallerRequirementValidator"/>
  </panel>
  <panel classname="PacksPanel"/>
  <panel classname="InstallPanel"/>
  <panel classname="FinishPanel"/>
</panels>

...

AttributeDescriptionDefaultRequired
severity
Note

Please see the note in the code above about severity vs status.

The severity the validator should apply in case of the condition gets true.

Possible values: "warningWARNING" | "errorERROR"

  •  "warningWARNING"
    Shows a warning message but does not abort.
  • "errorERROR"
    Shows a message and aborts the installation.
noneyes
condition
A valid condition ID defined within the <conditions/> element.noneyes
messageid
A valid message ID from the appropriate translation file. If it can't be found the mentioned ID itself is displayed instead of the translated text.noneyes