original_string: protected function waitFrame()
      {
          $frameType = $this->input->readOctet();
          $channel = $this->input->readShort();
          $size = $this->input->readLong();
          $payload = $this->input->read($size);
  
          $ch = $this->input->readOctet();
          if ($ch != 0xCE) {
              throw new \Exception(
                  sprintf(
                      'Framing error, unexpected byte: %x', $ch
                  )
              );
          }
  
          return array($frameType, $channel, $payload);
      }
code: protected function waitFrame()
      {
          $frameType = $this->input->readOctet();
          $channel = $this->input->readShort();
          $size = $this->input->readLong();
          $payload = $this->input->read($size);
  
          $ch = $this->input->readOctet();
          if ($ch != 0xCE) {
              throw new \Exception(
                  sprintf(
                      'Framing error, unexpected byte: %x', $ch
                  )
              );
          }
  
          return array($frameType, $channel, $payload);
      }
code_tokens: protected function waitFrame ( ) { $ frameType = $ this -> input -> readOctet ( ) ; $ channel = $ this -> input -> readShort ( ) ; $ size = $ this -> input -> readLong ( ) ; $ payload = $ this -> input -> read ( $ size ) ; $ ch = $ this -> input -> readOctet ( ) ; if ( $ ch != 0xCE ) { throw new \ Exception ( sprintf ( 'Framing error, unexpected byte: %x' , $ ch ) ) ; } return array ( $ frameType , $ channel , $ payload ) ; }
docstring: Wait for a frame from the server
  
  @return array
  @throws \Exception
docstring_tokens: Wait for a frame from the server