@@ -0,0 +1,1813 @@
+/*%0A * Copyright (C) 2010 TranceCode Software%0A *%0A * This library is free software; you can redistribute it and/or modify it under%0A * the terms of the GNU Lesser General Public License as published by the Free%0A * Software Foundation; either version 2.1 of the License, or (at your option)%0A * any later version.%0A * %0A * This library is distributed in the hope that it will be useful, but WITHOUT%0A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS%0A * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more%0A * details.%0A * %0A * You should have received a copy of the GNU Lesser General Public License%0A * along with this library; if not, write to the Free Software Foundation, Inc.,%0A * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA %0A */%0Apackage org.trancecode.parallel;%0A%0Aimport com.google.common.base.Predicate;%0A%0Aimport java.util.concurrent.Callable;%0Aimport java.util.concurrent.Future;%0A%0A/**%0A * %7B@link Predicate%7D implementations related to concurrent processing.%0A * %0A * @author Herve Quiroz%0A * @see Future%0A * @see Callable%0A */%0Apublic final class ParallelPredicates%0A%7B%0A    /**%0A     * @see Future#isCancelled()%0A     */%0A    public static %3CT%3E Predicate%3CFuture%3CT%3E%3E isCancelled()%0A    %7B%0A        @SuppressWarnings(%22unchecked%22)%0A        final IsCancelledPredicate%3CT%3E predicate = (IsCancelledPredicate%3CT%3E) IsCancelledPredicate.INSTANCE;%0A        return predicate;%0A    %7D%0A%0A    private static final class IsCancelledPredicate%3CT%3E implements Predicate%3CFuture%3CT%3E%3E%0A    %7B%0A        private static final IsCancelledPredicate%3C?%3E INSTANCE = new IsCancelledPredicate%3CObject%3E();%0A%0A        @Override%0A        public boolean apply(final Future%3CT%3E task)%0A        %7B%0A            return task.isCancelled();%0A        %7D%0A    %7D%0A%0A    private ParallelPredicates()%0A    %7B%0A        // No instantiation%0A    %7D%0A%7D%0A

Add ParallelPredicates.isCancelled()