public static synchronized boolean isGeneManiaDownloading() { boolean b = geneManiaDownloadTask != null && (!geneManiaDownloadTask.isDone()) && (!geneManiaDownloadTask.isCancelled()); return b; }
public static synchronized DownloadTask getGeneManiaDownloadTask() throws IOException { if (geneManiaDownloadTask == null || geneManiaDownloadTask.isCancelled()) { String dstPath = DirectorySettings.getCacheDirectory().getAbsolutePath(); geneManiaDownloadTask = new GeneManiaDownloadTask( WebResources.GENEMANIA_DATA_URL.toString(), dstPath, "Downloading GeneMANIA..."); } return geneManiaDownloadTask; }