4 * This file is part of the Symfony package.
6 * (c) Fabien Potencier <fabien@symfony.com>
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
12 namespace Symfony\Component\Console;
15 * Contains all events dispatched by an Application.
17 * @author Francesco Levorato <git@flevour.net>
19 final class ConsoleEvents
22 * The COMMAND event allows you to attach listeners before any command is
23 * executed by the console. It also allows you to modify the command, input and output
24 * before they are handled to the command.
26 * The event listener method receives a Symfony\Component\Console\Event\ConsoleCommandEvent
33 const COMMAND = 'console.command';
36 * The TERMINATE event allows you to attach listeners after a command is
37 * executed by the console.
39 * The event listener method receives a Symfony\Component\Console\Event\ConsoleTerminateEvent
46 const TERMINATE = 'console.terminate';
49 * The EXCEPTION event occurs when an uncaught exception appears.
51 * This event allows you to deal with the exception or
52 * to modify the thrown exception. The event listener method receives
53 * a Symfony\Component\Console\Event\ConsoleExceptionEvent
60 const EXCEPTION = 'console.exception';