Explorar o código

Update TcpConnection.php

walkor %!s(int64=3) %!d(string=hai) anos
pai
achega
87e2d4e109
Modificáronse 1 ficheiros con 8 adicións e 0 borrados
  1. 8 0
      src/Connection/TcpConnection.php

+ 8 - 0
src/Connection/TcpConnection.php

@@ -157,6 +157,13 @@ class TcpConnection extends ConnectionInterface implements \JsonSerializable
      * @var int
      */
     public $maxSendBufferSize = 1048576;
+    
+    /**
+     * Context.
+     *
+     * @var array
+     */
+    public $context = null;
 
     /**
      * Default send buffer size.
@@ -293,6 +300,7 @@ class TcpConnection extends ConnectionInterface implements \JsonSerializable
         $this->maxPackageSize = self::$defaultMaxPackageSize;
         $this->_remoteAddress = $remote_address;
         static::$connections[$this->id] = $this;
+        $this->context = new \stdClass;
     }
 
     /**