original_string: protected function assertPacketFlags($value, $fromPacket = true)
      {
          if ($this->packetFlags !== $value) {
              $this->throwException(
                  sprintf(
                      'Expected flags %02x but got %02x.',
                      $value,
                      $this->packetFlags
                  ),
                  $fromPacket
              );
          }
      }
code: protected function assertPacketFlags($value, $fromPacket = true)
      {
          if ($this->packetFlags !== $value) {
              $this->throwException(
                  sprintf(
                      'Expected flags %02x but got %02x.',
                      $value,
                      $this->packetFlags
                  ),
                  $fromPacket
              );
          }
      }
code_tokens: protected function assertPacketFlags ( $ value , $ fromPacket = true ) { if ( $ this -> packetFlags !== $ value ) { $ this -> throwException ( sprintf ( 'Expected flags %02x but got %02x.' , $ value , $ this -> packetFlags ) , $ fromPacket ) ; } }
docstring: Asserts that the packet flags have a specific value.
  
  @param int  $value
  @param bool $fromPacket
  
  @throws MalformedPacketException
  @throws \InvalidArgumentException
docstring_tokens: Asserts that the packet flags have a specific value .