original_string: public function withProtocolVersion($version)
      {
          if (!is_string($version)) {
              throw new \InvalidArgumentException("Expected protocol version to be a string");
          }
          
          $this->protocolVersion = $version;
          
          $this->sendStatusHeader();
          
          return $this;
      }
code: public function withProtocolVersion($version)
      {
          if (!is_string($version)) {
              throw new \InvalidArgumentException("Expected protocol version to be a string");
          }
          
          $this->protocolVersion = $version;
          
          $this->sendStatusHeader();
          
          return $this;
      }
code_tokens: public function withProtocolVersion ( $ version ) { if ( ! is_string ( $ version ) ) { throw new \ InvalidArgumentException ( "Expected protocol version to be a string" ) ; } $ this -> protocolVersion = $ version ; $ this -> sendStatusHeader ( ) ; return $ this ; }
docstring: Set the protocol version
  
  @param string $version
  @return $this
docstring_tokens: Set the protocol version