Package tigase.util.updater
Class UpdatesChecker
- java.lang.Object
-
- tigase.util.common.TimerTask
-
- tigase.component.ScheduledTask
-
- tigase.util.updater.UpdatesChecker
-
- All Implemented Interfaces:
java.lang.Runnable
,ConfigurationChangedAware
,Initializable
,UnregisterAware
@Bean(name="update-checker", parent=MessageRouter.class, active=true) public class UpdatesChecker extends ScheduledTask
Describe class UpdatesChecker here.
Created: Fri Apr 18 09:35:32 2008- Author:
- Artur Hefczyc
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
UpdatesChecker.ProductInfoIfc
static class
UpdatesChecker.UpdatedVersionDiscovered
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
PRODUCTS_REQUEST_KEY
static java.lang.String
VERSION_REQUEST_KEY
-
Fields inherited from class tigase.component.ScheduledTask
component
-
-
Constructor Summary
Constructors Constructor Description UpdatesChecker()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
initialize()
Method will be called, when bean will be created, configured and ready to use.protected void
onUpdatedVersionDiscovered(UpdatesChecker.UpdatedVersionDiscovered event)
static java.util.Optional<Version>
retrieveCurrentVersionFromServer(Version currentVersion, java.util.List<UpdatesChecker.ProductInfoIfc> products, java.lang.String url, int timeoutInSeconds)
void
run()
void
setProductInfos(java.util.ArrayList<UpdatesChecker.ProductInfoIfc> productInfos)
-
Methods inherited from class tigase.component.ScheduledTask
beanConfigurationChanged, beforeUnregister
-
Methods inherited from class tigase.util.common.TimerTask
cancel, cancel, isCancelled, isScheduled, reset, setScheduledFuture
-
-
-
-
Field Detail
-
VERSION_REQUEST_KEY
public static final java.lang.String VERSION_REQUEST_KEY
- See Also:
- Constant Field Values
-
PRODUCTS_REQUEST_KEY
public static final java.lang.String PRODUCTS_REQUEST_KEY
- See Also:
- Constant Field Values
-
-
Method Detail
-
retrieveCurrentVersionFromServer
public static java.util.Optional<Version> retrieveCurrentVersionFromServer(Version currentVersion, java.util.List<UpdatesChecker.ProductInfoIfc> products, java.lang.String url, int timeoutInSeconds)
-
initialize
public void initialize()
Description copied from interface:Initializable
Method will be called, when bean will be created, configured and ready to use.- Specified by:
initialize
in interfaceInitializable
- Overrides:
initialize
in classScheduledTask
-
run
public void run()
-
setProductInfos
public void setProductInfos(java.util.ArrayList<UpdatesChecker.ProductInfoIfc> productInfos)
-
onUpdatedVersionDiscovered
@HandleEvent protected void onUpdatedVersionDiscovered(UpdatesChecker.UpdatedVersionDiscovered event)
-
-