Explorar o código

TcpConnection add getSocket method

walkor %!s(int64=10) %!d(string=hai) anos
pai
achega
6fac9caa12
Modificáronse 1 ficheiros con 9 adicións e 0 borrados
  1. 9 0
      Workerman/Connection/TcpConnection.php

+ 9 - 0
Workerman/Connection/TcpConnection.php

@@ -397,6 +397,15 @@ class TcpConnection extends ConnectionInterface
            $this->destroy();
         }
     }
+    
+    /**
+     * get socket
+     * @return resource
+     */
+    public function getSocket()
+    {
+        return $this->_socket;
+    }
 
     /**
      * destroy the connection