/**
  * Constructs the writer, optionally starts the handler
  * @param boolean $autostart set to true to autostart the handler
  * @return  void
  */
 public function __construct($autostart = true)
 {
     $this->handler = \PhpConsole\Handler::getInstance();
     $this->connector = $this->handler->getConnector();
     if ($autostart && !$this->handler->isStarted()) {
         $this->handler->start();
     }
 }