code: public void submit(Task task,Integer index) {
          task.activate(false);
          taskQueues[index].accept(task);
      }
docs: Queues task for execution according to its priority.
  
  @param task the task to be executed.