net.sourceforge.rssowl.controller.thread
Class UpdateManager

java.lang.Object
  extended byjava.lang.Thread
      extended bynet.sourceforge.rssowl.controller.thread.UpdateManager
All Implemented Interfaces:
Runnable

public class UpdateManager
extends Thread

The Update Manager checks the version-file on a server for new releases of RSSOwl and displays a message in a new tab if a new version is available. The message also contains a list of new features if available. The Manager is a thread to avoid freezing of RSSOwl while the update informations are re- trieved.

Version:
1.1.3
Author:
Benjamin Pasero

Field Summary
private  String changelog
          Changelog of newest version
private  boolean displayNoNewVersionInfo
          True if the user wants to be informed even if no updated is available
static String MAJOR_VERSION
          Set the current major version of RSSOwl
[Format: x.x]
static String MINOR_VERSION
          Set the current minor version of RSSOwl
[Format: YYYY-MM-DD]
[PR Format: Preview Release YYYY-MM-DD]
private  String onlineVersion
          RSSOwl Version as String
private  GUI rssOwlGui
          RSSOwl Maincontroller
private  boolean showErrorMessage
          If TRUE show an warning message when the connection fails
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
UpdateManager(GUI rssOwlGui)
          Instantiate a new UpdateManager
UpdateManager(GUI rssOwlGui, boolean showErrorMessage)
          Instantiate a new UpdateManager
 
Method Summary
(package private)  void createErrorConnectInfo()
          Display warning message in a dialog
(package private)  void createInfoTab()
          Display the message in the tab
(package private)  void createNoNewVersionInfo()
          Display the message in a dialog
private  void getChangelog()
          Get changelog from server
static String getPublicVersion()
          Get the correct formatted public version identifier
private  void getVersion()
          Get version number from server
 void run()
          Load versionnumber and changelog from server
 void setDisplayNoNewVersionInfo(boolean displayNoNewVersionInfo)
          Set TRUE if the user wants to be informed even if no upted is available
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MAJOR_VERSION

public static final String MAJOR_VERSION
Set the current major version of RSSOwl
[Format: x.x]

See Also:
Constant Field Values

MINOR_VERSION

public static final String MINOR_VERSION
Set the current minor version of RSSOwl
[Format: YYYY-MM-DD]
[PR Format: Preview Release YYYY-MM-DD]

See Also:
Constant Field Values

changelog

private String changelog
Changelog of newest version


displayNoNewVersionInfo

private boolean displayNoNewVersionInfo
True if the user wants to be informed even if no updated is available


onlineVersion

private String onlineVersion
RSSOwl Version as String


rssOwlGui

private GUI rssOwlGui
RSSOwl Maincontroller


showErrorMessage

private boolean showErrorMessage
If TRUE show an warning message when the connection fails

Constructor Detail

UpdateManager

public UpdateManager(GUI rssOwlGui)
Instantiate a new UpdateManager

Parameters:
rssOwlGui - The RSSOwl Maincontroller

UpdateManager

public UpdateManager(GUI rssOwlGui,
                     boolean showErrorMessage)
Instantiate a new UpdateManager

Parameters:
rssOwlGui - The RSSOwl Maincontroller
showErrorMessage - TRUE: Show warning message if con. fails
Method Detail

getPublicVersion

public static String getPublicVersion()
Get the correct formatted public version identifier

Returns:
String The public version

run

public void run()
Load versionnumber and changelog from server


setDisplayNoNewVersionInfo

public void setDisplayNoNewVersionInfo(boolean displayNoNewVersionInfo)
Set TRUE if the user wants to be informed even if no upted is available

Parameters:
displayNoNewVersionInfo - Set to TRUE if RSSOwl should give out information, even if no new version is available.

getChangelog

private void getChangelog()
                   throws IOException
Get changelog from server

Throws:
IOException - If an IO Error occurs

getVersion

private void getVersion()
                 throws IOException
Get version number from server

Throws:
IOException - If an IO Error occurs

createErrorConnectInfo

void createErrorConnectInfo()
Display warning message in a dialog


createInfoTab

void createInfoTab()
Display the message in the tab


createNoNewVersionInfo

void createNoNewVersionInfo()
Display the message in a dialog



RSSOwl - RSS / RDF / Atom Newsreader

SourceForge.net Logo