Пример #1
0
 @Override
 public boolean isCancelled() {
   if (mRequest == null) {
     return false;
   }
   return mRequest.isCanceled();
 }
Пример #2
0
  @Override
  public synchronized boolean cancel(boolean mayInterruptIfRunning) {
    if (mRequest == null) {
      return false;
    }

    if (!isDone()) {
      mRequest.cancel();
      return true;
    } else {
      return false;
    }
  }