gwa.app API

Functions for querying version numbers and for working with application updates.

Table 1. Functions
Function Description
FUNCTION checkUpToDate() RETURNS gwa.app.TUpdateDialogResult
Checks if the application is up to date by comparing versions and date time stamps.
FUNCTION getBuild() RETURNS gwa.app.TBuildDateTime 
Returns the date time stamp of when the application was built.
FUNCTION getGBCVersion() RETURNS STRING
Returns the version of the GBC embedded in the application.
FUNCTION getInformation() RETURNS gwa.app.TAppInformation
Returns the application version information.
FUNCTION getServerVersionAndBuild() RETURNS gwa.app.TAppInformation
Returns server application version information.
FUNCTION getTitle() RETURNS STRING
Returns the application title set by gwabuildtool --title.
FUNCTION getVersion() RETURNS STRING
Returns the application version set by gwabuildtool --app-version.
FUNCTION performUpdate() RETURNS STRING
Update the application.
FUNCTION set_href_to_new_index() RETURNS STRING
Set the href of the index page.
FUNCTION simulateBrowserUpdate() RETURNS STRING
Simulate a browser update (service worker update) and reload the page if the update was ok.
FUNCTION updateDialog(reportWhenUpToDate BOOLEAN)
   RETURNS gwa.app.TUpdateDialogResult
Checks the version of the loaded application against the server version and prompts the user to update if required.
FUNCTION versionsAndBuildsEqual(
     version1 STRING, 
     version2 STRING, 
     build1 gwa.app.TBuildDateTime,
     build2 gwa.app.TBuildDateTime) 
  RETURNS BOOLEAN
Checks if the versions and build date-time stamps are equal. If versions are NULL, only build date-time stamps are compared for equality.