예제 #1
0
 public static void setHasBeenOpened(DownloadManager dm, boolean opened) {
   TOTorrent torrent = dm.getTorrent();
   if (torrent == null) {
     return;
   }
   if (opened == getHasBeenOpened(dm)) {
     return;
   }
   setContentMapLong(torrent, TOR_AZ_PROP_OPENED, opened ? 1 : 0);
   writeTorrentIfExists(torrent);
   Object[] array = hasBeenOpenedListeners.toArray();
   for (int i = 0; i < array.length; i++) {
     try {
       HasBeenOpenedListener l = (HasBeenOpenedListener) array[i];
       l.hasBeenOpenedChanged(dm, opened);
     } catch (Exception e) {
       Debug.out(e);
     }
   }
 }
예제 #2
0
 public static void setContentLastUpdated(TOTorrent torrent, long lastUpdate) {
   setContentMapLong(torrent, TOR_AZ_PROP_LASTUPDATED, lastUpdate);
 }
예제 #3
0
 public static void setUseEMP(TOTorrent torrent, boolean useEMP) {
   setContentMapLong(torrent, TOR_AZ_PROP_USE_EMP, useEMP ? 1 : 0);
 }
예제 #4
0
 public static void setQOSClass(TOTorrent torrent, long cla) {
   setContentMapLong(torrent, TOR_AZ_PROP_QOS_CLASS, cla);
 }