* Sends data. * @param data data string */
($data)
| 213 | * @param data data string |
| 214 | */ |
| 215 | public function send($data) |
| 216 | { |
| 217 | $result = socket_write($this->socket, $data); |
| 218 | if ($result === false) { |
| 219 | throw $this->error("Write failed"); |
| 220 | } |
| 221 | } |
| 222 | |
| 223 | private function read() |
| 224 | { |