Exemplo n.º 1
0
 @Override
 public SortedSet<Serie> getSeries() {
   LOG.trace("Reload series");
   SortedSet<Serie> loadedSeries = Services.getLoadingService().loadAllSeries();
   changes.firePropertyChange(ModelProperties.SERIES.getPropertyName(), series, loadedSeries);
   series = loadedSeries;
   return series;
 }
Exemplo n.º 2
0
 @Override
 public SortedSet<Website> getWebsites() {
   LOG.trace("Reload websites [Selected Serie : " + selectedSerie + "]");
   SortedSet<Website> loadedWebsites =
       Services.getLoadingService().loadSiteForSerie(selectedSerie);
   changes.firePropertyChange(
       ModelProperties.WEBSITES.getPropertyName(), websites, loadedWebsites);
   websites = loadedWebsites;
   return websites;
 }
Exemplo n.º 3
0
  @Override
  public void launchDownload() {
    LOG.trace("Launch download of chapters [ToDownloadChapters =" + toDownloadChapters + "]");
    List<Chapter> toDownload = new LinkedList<>(toDownloadChapters);
    Services.getDownloadServices().download(toDownload);

    toDownloadChapters.clear();
    changes.firePropertyChange(
        ModelProperties.CHAPTER_TO_DOWNLOAD.getPropertyName(), toDownload, toDownloadChapters);
  }
Exemplo n.º 4
0
 @Override
 public SortedSet<Chapter> getLoadedChapters() {
   LOG.trace(
       "Reload chapters [Selected Serie : "
           + selectedSerie
           + "; Selected Websites : "
           + selectedWebsite
           + "]");
   SortedSet<Chapter> newChapters =
       Services.getLoadingService().loadChapterList(selectedWebsite, selectedSerie);
   changes.firePropertyChange(
       ModelProperties.CHAPTER_LOADED.getPropertyName(), loadedChapters, newChapters);
   loadedChapters = newChapters;
   return loadedChapters;
 }
Exemplo n.º 5
0
 @Override
 public void refreshData() {
   LOG.trace("Refresh data");
   Services.getLoadingService().refreshListSerie();
   getSeries();
 }