Initiates an orderly shutdown in which previously submitted
tasks are executed, but no new tasks will be accepted.
Invocation has no additional effect if already shut down.
<p>This method does not wait for previously submitted tasks to
complete execution. Use {@link #awaitTermination awaitTermination}
to do that.
<p>If the {@code ExecuteExistingDelayedTasksAfterShutdownPolicy}
has been set {@code false}, existing delayed tasks whose delays
have not yet elapsed are cancelled. And unless the {@code
ContinueExistingPeriodicTasksAfterShutdownPolicy} has been set
{@code true}, future executions of existing periodic tasks will
be cancelled.
Initiates an orderly shutdown in which previously submitted tasks are executed, but no new tasks will be accepted. Invocation has no additional effect if already shut down.
<p>This method does not wait for previously submitted tasks to complete execution. Use {@link #awaitTermination awaitTermination} to do that.
<p>If the {@code ExecuteExistingDelayedTasksAfterShutdownPolicy} has been set {@code false}, existing delayed tasks whose delays have not yet elapsed are cancelled. And unless the {@code ContinueExistingPeriodicTasksAfterShutdownPolicy} has been set {@code true}, future executions of existing periodic tasks will be cancelled.
@throws SecurityException {@inheritDoc}