src/Console/AbstractCommand.php
protected function error($message)
    {
        if ($this->output instanceof ConsoleOutputInterface) {
            $this->output->getErrorOutput()->writeln("<error>$message</error>");
        } else {
            $this->output->writeln("<error>$message</error>");
        }
    }
protected function error($message)
    {
        if ($this->output instanceof ConsoleOutputInterface) {
            $this->output->getErrorOutput()->writeln("<error>$message</error>");
        } else {
            $this->output->writeln("<error>$message</error>");
        }
    }
protected function error ( $ message ) { if ( $ this -> output instanceof ConsoleOutputInterface ) { $ this -> output -> getErrorOutput ( ) -> writeln ( "<error>$message</error>" ) ; } else { $ this -> output -> writeln ( "<error>$message</error>" ) ; } }
Send an error or warning message to the user.

If possible, this will send the message via STDERR.

@param string $message
Send an error or warning message to the user .