Kafka\Socket::close PHP Method

close() public method

close the socket
public close ( ) : void
return void
    public function close()
    {
        if (is_resource($this->stream)) {
            fclose($this->stream);
        }
    }

Usage Example

Beispiel #1
0
 /**
  * Close the connection
  *
  * @return void
  */
 public function close()
 {
     if (null !== $this->socket) {
         $this->socket->close();
     }
 }