code: protected void addTask(Runnable task) {
          if (task == null) {
              throw new NullPointerException("task");
          }
          if (!offerTask(task)) {
              reject(task);
          }
      }
docs: Add a task to the task queue, or throws a {@link RejectedExecutionException} if this instance was shutdown
  before.