UpdateDescriptorEntry
objects that are
returned by the UpdateDescriptor
object. There are two different scenarios for working with these objects:
UpdateDescriptor
object
and save it to the installer variable named "updateDescriptor". A "Set a variable" action is used to save the
appropriate UpdateDescriptorEntry
object to te installer variable named "updateDescriptorEntry"
You can use the above installer variables directly in your updater application.
com.install4j.api.update.UpdateChecker.getUpdateDescriptor(...)
to obtain an instance of
UpdateDescriptor
.
sys.updatesUrl
compiler variable.
When you insert an updater on the screens & actions tab,
it contains a "Check for updates" action, that will have its "Update descriptor URL" property set to
${compiler:sys.updatesUrl}. If there are any "Check for updates" actions in your project that use
this compiler variable, you have to define it in this text field. Note that this must be the full URL to which
you will upload the update descriptor file updates.xml, for example https://www.server.com/donwload/updates.xml.
You do not have to name the file updates.xml on the server, it can have any name.
The base URL setting controls how the download URL of a new installer is constructed by an auto-updater. By default, new installers have to be located in the same directory as the updates.xml update descriptor file. If they should be downloaded from another source, activate the base URL setting and specify the base URL. The URL should start with http:// or https:// and point to a directory where the installers are located, not to a particular installer.
The configured value is returned by UpdateDescriptor#getBaseUrl()
. It is not possible to
set different base URLs for different media files by using a compiler variable.
UpdateDescriptor#getPossibleUpdateEntry()
will be null
and the updater application
will not detect a new version.
The configured values are returned by UpdateDescriptorEntry#getUpdatableVersionMin()
and
UpdateDescriptorEntry#getUpdatableVersionMax()
. They can be overridden for each media file in the
"Customize project defaults->Auto-update options" step of the media file wizard.
The comment in the user-selected language is returned by UpdateDescriptorEntry#getComment()
.
Comment files can be overridden for each media file in the "Customize project defaults->Auto-update options"
step of the media file wizard.
The files with comments must be encoded in UTF-8.
The configured attributes are returned by UpdateDescriptorEntry#getAdditionalAttribute(...)
.
They can be overridden for each media file in the "Customize project defaults->Auto-update options" step
of the media file wizard.