|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.denova.JExpress.Updater.CustomUpdater
public class CustomUpdater
Provides access to the updater from custom updater classes.
| Constructor Summary | |
|---|---|
CustomUpdater()
|
|
| Method Summary | |
|---|---|
static void |
abortUpdater()
Abort updater. |
static boolean |
autoUpdater()
Determines if this is an auto-updater or not. |
static void |
cleanUpManifestFiles()
Delete the local copy of the updated manifest. |
static void |
exitUpdater()
Exit updater. |
static java.lang.String |
extendUrl(java.lang.String baseUrl,
java.lang.String extension)
Create a url. |
static boolean |
extractFile(java.lang.String filename)
Extracts a file to the updater's temporary directory. |
static java.awt.Color |
getBackgroundColor()
Get the color used for the background of panels, buttons, and dialogs. |
static java.util.List |
getFilesToRemoveList()
Gets a list of filenames that are not included in the updated manifest. |
static java.util.List |
getFilesToUpdateList()
Gets a list of manifest entries for the files to be updated. |
static java.lang.String |
getLanguage()
Returns the language the updater is using. |
static java.lang.String |
getLocalizedString(java.lang.String key)
Returns a localized string from the updater's primary resources. |
static java.lang.String |
getLocalizedString(java.lang.String key,
java.lang.String variable)
Returns a localized string from the updater's primary resources. |
static java.lang.String |
getLocalizedString(java.lang.String key,
java.lang.String[] variables)
Returns a localized string from the updater's primary resources. |
static javax.swing.JPanel |
getLogoPanel()
Returns the panel for the updater's image. |
static java.util.List |
getNewJarFiles()
Gets a list of new jar files downloaded. |
static java.awt.Color |
getProgressBarColor()
Get the color used for progress bars. |
static PropertyList |
getPropertyList()
Returns the updater's property list. |
static boolean |
getResourceAsFile(java.lang.String filename)
Looks through the classpath for the filename and saves it to a file in the updater's temporary directory. |
static boolean |
getResourceAsFile(java.lang.String filename,
java.lang.String pathname)
Looks through the classpath for the filename and saves it to the pathname. |
static java.io.InputStream |
getResourceAsStream(java.lang.String name)
Opens an input stream to the resource. |
static java.lang.String |
getTempDirectory()
Returns the installer's temporary directory. |
static java.awt.Color |
getTextColor()
Get the color used for text items. |
static boolean |
isOpaque()
Determines if the background is opaque or not. |
static void |
log(java.lang.Exception t)
Log an error to updater.log, if it exists in the JExpress subdirectory. |
static void |
log(java.lang.String message)
Log a message to updater.log, if it exists in the JExpress subdirectory. |
static void |
logError(java.lang.Exception t)
Log an error to error.log, regardless if log exists. |
static void |
logError(java.lang.String message)
Log a message to error.log, regardless if log exists. |
static void |
logError(java.lang.String message,
java.lang.Exception t)
Log a message and the error to error.log, regardless if log exists. |
static void |
logError(java.lang.Throwable t)
Log an error to error.log, regardless if log exists. |
protected static boolean |
okToRunApp()
Check if it's ok to run the app with CopyCheq server. |
protected static boolean |
okToRunUpdater()
Check if it's ok to run updater with CopyCheq server. |
static void |
removeUpdateDir()
Remove the temporaray "updates" directory on the user's sytem. |
static void |
setUpdaterStatus(boolean ok)
Set the boolean for the updater's final status. |
static boolean |
startProgram()
Start the application, if this is an autoupdater. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CustomUpdater()
| Method Detail |
|---|
public static java.util.List getFilesToUpdateList()
If you change the files to update "AfterFilesCompared", then those changes will be used to download the updated files.
If you do not want any of your changes to impact the standard update, you should clone the return value.
public static java.util.List getFilesToRemoveList()
If you do not want any of your changes to impact the standard update, you should clone the return value. Only available if DeleteObsoleteFiles was set to true in the installer.
public static java.util.List getNewJarFiles()
If you change the new jar files "AfterFilesCompared", then those changes will be used to download the updated files.
If you do not want any of your changes to impact the standard update, you should clone the return value.
public static javax.swing.JPanel getLogoPanel()
You can use this method to replace the image and create billboards. Don't forget to empty the container before you add your own image. If your image is a different size, you'll want to revalidate, etc. We strongly recommend that you always use the same size image.
public static java.awt.Color getBackgroundColor()
public static java.awt.Color getProgressBarColor()
public static java.awt.Color getTextColor()
public static boolean isOpaque()
public static boolean autoUpdater()
public static boolean startProgram()
This can be most effectively used if you want to stop the update process, but want the application to launch any ways.
public static void setUpdaterStatus(boolean ok)
If you want the updater to skip certain standard procedures, but still have a particular final status, then call this routine and disable whichever panels you don't want activated during the update. ok: true, if you want the updater's final status to be ok, regardless if update actually completed all standard procedures or not.
ok - The new updaterStatus valuepublic static java.lang.String getTempDirectory()
If the installer is not using a temporary directory, then it returns a blank.
public static boolean extractFile(java.lang.String filename)
filename - the name of the file to extract
public static boolean getResourceAsFile(java.lang.String filename)
filename - name of file to get
public static boolean getResourceAsFile(java.lang.String filename,
java.lang.String pathname)
filename - name of file to getpathname - full pathname to save file, not just the directory
public static java.io.InputStream getResourceAsStream(java.lang.String name)
name - name of the resource
public static void log(java.lang.String message)
message - message to recordpublic static void log(java.lang.Exception t)
t - exceptionpublic static void logError(java.lang.String message)
message - message to recordpublic static void logError(java.lang.Exception t)
t - exception error.public static void logError(java.lang.Throwable t)
t - throwable error.
public static void logError(java.lang.String message,
java.lang.Exception t)
message - message to recordt - errorpublic static PropertyList getPropertyList()
public static java.lang.String getLanguage()
public static java.lang.String getLocalizedString(java.lang.String key)
key - the attribute for the value
public static java.lang.String getLocalizedString(java.lang.String key,
java.lang.String variable)
key - the attribute for the valuevariable - the variable's value
public static java.lang.String getLocalizedString(java.lang.String key,
java.lang.String[] variables)
key - the attribute for the valuevariables - the list of variables' value
public static java.lang.String extendUrl(java.lang.String baseUrl,
java.lang.String extension)
baseUrl - base urlextension - extension
public static void cleanUpManifestFiles()
public static void removeUpdateDir()
public static void exitUpdater()
public static void abortUpdater()
protected static boolean okToRunUpdater()
protected static boolean okToRunApp()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||