Package java.util.concurrent

Examples of java.util.concurrent.RejectedExecutionException


       */
      final ForkJoinTask<?>[] growArray() {
         ForkJoinTask<?>[] oldA = array;
         int size = oldA != null ? oldA.length << 1 : INITIAL_QUEUE_CAPACITY;
         if (size > MAXIMUM_QUEUE_CAPACITY)
            throw new RejectedExecutionException("Queue capacity exceeded");
         int oldMask, t, b;
         ForkJoinTask<?>[] a = array = new ForkJoinTask<?>[size];
         if (oldA != null && (oldMask = oldA.length - 1) >= 0 &&
               (t = top) - (b = base) > 0) {
            int mask = size - 1;
View Full Code Here


        ExecutorService service = delegate.get();
        if (service != null) {
            service.execute(taskManager.trackTask(command));
            return;
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

        ExecutorService service = delegate.get();
        if (service != null) {
            return service.invokeAll(taskManager.trackTasks(tasks), timeout,
                    unit);
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

            throws InterruptedException {
        ExecutorService service = delegate.get();
        if (service != null) {
            return service.invokeAll(taskManager.trackTasks(tasks));
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

        if (service != null) {
            // since the tasks are either executed or cancelled, there is no
            // need to track them
            return service.invokeAny(tasks, timeout, unit);
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

        if (service != null) {
            // since the tasks are either executed or cancelled, there is no
            // need to track them
            return service.invokeAny(tasks);
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

    public <T> Future<T> submit(Callable<T> task) {
        ExecutorService service = delegate.get();
        if (service != null) {
            return service.submit(taskManager.trackTask(task));
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

    public <T> Future<T> submit(Runnable task, T result) {
        ExecutorService service = delegate.get();
        if (service != null) {
            return service.submit(taskManager.trackTask(task), result);
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

    public Future<?> submit(Runnable task) {
        ExecutorService service = delegate.get();
        if (service != null) {
            return service.submit(taskManager.trackTask(task));
        }
        throw new RejectedExecutionException(
                "Execution service is terminated. No more tasks can be executed.");
    }
View Full Code Here

         } else {
            throw new IllegalArgumentException("Runnable command is not Serializable  " + command);
         }        
         executeFuture(selectExecutionNode(), cmd);
      } else {
         throw new RejectedExecutionException();
      }
   }
View Full Code Here

TOP

Related Classes of java.util.concurrent.RejectedExecutionException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.