public function resume() { if ($this->paused) { $this->paused = false; $this->loop->addReadStream($this->resource, [$this, 'handleData']); } }