public function sendPing($host, $cb) { $this->connect('raw://' . $host, function ($conn) use($cb) { $conn->sendEcho($cb); }); }