예제 #1
0
 @Override
 public boolean isPending() {
   if (delegate != null) {
     return delegate.isPending();
   } else {
     return !cancelled;
   }
 }
예제 #2
0
 @Override
 public void cancel() {
   if (delegate != null) {
     delegate.cancel();
   } else {
     cancelled = true;
   }
 }