- java.lang.Object
-
- tvbrowser.core.TvDataUpdater
-
public class TvDataUpdater extends java.lang.Object
Updates the TV data.- Author:
- Til Schneider, www.murfman.de
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addTvDataUpdateListener(TvDataUpdateListener listener)
void
downloadTvData(int daysToDownload, TvDataServiceProxy[] services, javax.swing.JProgressBar progressBar, javax.swing.JLabel label)
Download the new TV data(package private) void
fireTvDataUpdateFinished()
(package private) void
fireTvDataUpdateStarted(Date until)
static TvDataUpdater
getInstance()
boolean
isDownloading()
Gets whether the TV data updater is currently downloading data.boolean
isUpdating()
void
removeTvDataUpdateListener(TvDataUpdateListener listener)
void
stopDownload()
Stops the current download.boolean
tvDataWasChanged()
check whether the last TV data update changed some data in the TV database
-
-
-
Method Detail
-
getInstance
public static TvDataUpdater getInstance()
-
addTvDataUpdateListener
public void addTvDataUpdateListener(TvDataUpdateListener listener)
-
removeTvDataUpdateListener
public void removeTvDataUpdateListener(TvDataUpdateListener listener)
-
isDownloading
public boolean isDownloading()
Gets whether the TV data updater is currently downloading data.- Returns:
true
, if the TV data updater is currently downloading data.
-
downloadTvData
public void downloadTvData(int daysToDownload, TvDataServiceProxy[] services, javax.swing.JProgressBar progressBar, javax.swing.JLabel label)
Download the new TV data- Parameters:
daysToDownload
- The number of days until today to download the program for.services
- The services to use for data update.progressBar
- The progress bar to show the data update progress.label
- The label to print status message to.
-
isUpdating
public boolean isUpdating()
-
fireTvDataUpdateStarted
void fireTvDataUpdateStarted(Date until)
-
fireTvDataUpdateFinished
void fireTvDataUpdateFinished()
-
stopDownload
public void stopDownload()
Stops the current download.
-
tvDataWasChanged
public boolean tvDataWasChanged()
check whether the last TV data update changed some data in the TV database- Returns:
true
, if data was changed during last update- Since:
- 2.6
-
-