public function __construct($options) { $this->options = array_merge(array('cmd' => null, 'live_output' => true, 'stop_on_error' => true), $options); if ($this->options['cmd'] == null) { throw new \RuntimeException('Missing [cmd] option'); } }