5 * Contains \Drupal\Console\Core\Command\Command.
8 namespace Drupal\Console\Core\Command;
10 use Symfony\Component\Console\Command\Command as BaseCommand;
11 use Symfony\Component\Console\Input\InputInterface;
12 use Symfony\Component\Console\Output\OutputInterface;
13 use Drupal\Console\Core\Command\Shared\CommandTrait;
14 use Drupal\Console\Core\Style\DrupalStyle;
15 use Drupal\Console\Core\Utils\DrupalFinder;
20 * @package Drupal\Console\Core\Command
22 abstract class Command extends BaseCommand
29 protected $drupalFinder;
39 protected function initialize(InputInterface $input, OutputInterface $output)
41 $this->io = new DrupalStyle($input, $output);
45 * @return \Drupal\Console\Core\Style\DrupalStyle
47 public function getIo()
52 public function createException($message) {
53 $this->getIo()->error($message);
58 * @param \Drupal\Console\Core\Utils\DrupalFinder $drupalFinder
60 public function setDrupalFinder($drupalFinder) {
61 $this->drupalFinder = $drupalFinder;