Output.php 422 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. namespace addons\command\library;
  3. /**
  4. * Class Output
  5. */
  6. class Output extends \think\console\Output
  7. {
  8. protected $message = [];
  9. public function __construct($driver = 'console')
  10. {
  11. parent::__construct($driver);
  12. }
  13. protected function block($style, $message)
  14. {
  15. $this->message[] = $message;
  16. }
  17. public function getMessage()
  18. {
  19. return $this->message;
  20. }
  21. }