/** {@inheritDoc} */ @Override public boolean cancel() throws IgniteCheckedException { if (onCancelled()) { for (IgniteInternalFuture<T> fut : futures()) fut.cancel(); return true; } return false; }
@Override public GridRestResponse applyx( GridCompoundFuture<GridCacheRestResponse, ?> cf) throws IgniteCheckedException { boolean success = true; for (IgniteInternalFuture<GridCacheRestResponse> f : cf.futures()) if ((Boolean)f.get().getResponse() != true) success = false; GridCacheRestResponse resp = new GridCacheRestResponse(); if (success) resp.setResponse(true); else resp.setResponse(false); return resp; } });
/** {@inheritDoc} */ @Override public String toString() { return S.toString(GridCompoundFuture.class, this, "done", isDone(), "cancelled", isCancelled(), "err", error(), "futs", F.viewReadOnly(futures(), new C1<IgniteInternalFuture<T>, String>() { @Override public String apply(IgniteInternalFuture<T> f) { return Boolean.toString(f.isDone()); } }) ); } }
/** {@inheritDoc} */ @Override public boolean cancel() throws IgniteCheckedException { if (onCancelled()) { for (IgniteInternalFuture<T> fut : futures()) fut.cancel(); return true; } return false; }
@Override public GridRestResponse applyx( GridCompoundFuture<GridCacheRestResponse, ?> cf) throws IgniteCheckedException { boolean success = true; for (IgniteInternalFuture<GridCacheRestResponse> f : cf.futures()) if ((Boolean)f.get().getResponse() != true) success = false; GridCacheRestResponse resp = new GridCacheRestResponse(); if (success) resp.setResponse(true); else resp.setResponse(false); return resp; } });
/** {@inheritDoc} */ @Override public String toString() { return S.toString(GridCompoundFuture.class, this, "done", isDone(), "cancelled", isCancelled(), "err", error(), "futs", F.viewReadOnly(futures(), new C1<IgniteInternalFuture<T>, String>() { @Override public String apply(IgniteInternalFuture<T> f) { return Boolean.toString(f.isDone()); } }) ); } }