original_string: protected function fetchError($err)
      {
          $cells = $err->section(Teamspeak::SEPARATOR_CELL, 1, 3);
  
          foreach ($cells->split(Teamspeak::SEPARATOR_CELL) as $pair) {
              list($ident, $value) = $pair->split(Teamspeak::SEPARATOR_PAIR);
  
              $this->err[$ident->toString()] = $value->isInt() ? $value->toInt() : $value->unescape();
          }
  
          Signal::getInstance()->emit("notifyError", $this);
  
          if ($this->getErrorProperty("id", 0x00) != 0x00 && $this->exp) {
              if ($permid = $this->getErrorProperty("failed_permid")) {
                  if ($permsid = key($this->con->request("permget permid=" . $permid, false)->toAssocArray("permsid"))) {
                      $suffix = " (failed on " . $permsid . ")";
                  } else {
                      $suffix = " (failed on " . $this->cmd->section(
                              Teamspeak::SEPARATOR_CELL
                          ) . " " . $permid . "/0x" . strtoupper(dechex($permid)) . ")";
                  }
              } elseif ($details = $this->getErrorProperty("extra_msg")) {
                  $suffix = " (" . trim($details) . ")";
              } else {
                  $suffix = "";
              }
  
              throw new Ts3Exception(
                  $this->getErrorProperty("msg") . $suffix,
                  $this->getErrorProperty("id")
              );
          }
      }
code: protected function fetchError($err)
      {
          $cells = $err->section(Teamspeak::SEPARATOR_CELL, 1, 3);
  
          foreach ($cells->split(Teamspeak::SEPARATOR_CELL) as $pair) {
              list($ident, $value) = $pair->split(Teamspeak::SEPARATOR_PAIR);
  
              $this->err[$ident->toString()] = $value->isInt() ? $value->toInt() : $value->unescape();
          }
  
          Signal::getInstance()->emit("notifyError", $this);
  
          if ($this->getErrorProperty("id", 0x00) != 0x00 && $this->exp) {
              if ($permid = $this->getErrorProperty("failed_permid")) {
                  if ($permsid = key($this->con->request("permget permid=" . $permid, false)->toAssocArray("permsid"))) {
                      $suffix = " (failed on " . $permsid . ")";
                  } else {
                      $suffix = " (failed on " . $this->cmd->section(
                              Teamspeak::SEPARATOR_CELL
                          ) . " " . $permid . "/0x" . strtoupper(dechex($permid)) . ")";
                  }
              } elseif ($details = $this->getErrorProperty("extra_msg")) {
                  $suffix = " (" . trim($details) . ")";
              } else {
                  $suffix = "";
              }
  
              throw new Ts3Exception(
                  $this->getErrorProperty("msg") . $suffix,
                  $this->getErrorProperty("id")
              );
          }
      }
code_tokens: protected function fetchError ( $ err ) { $ cells = $ err -> section ( Teamspeak :: SEPARATOR_CELL , 1 , 3 ) ; foreach ( $ cells -> split ( Teamspeak :: SEPARATOR_CELL ) as $ pair ) { list ( $ ident , $ value ) = $ pair -> split ( Teamspeak :: SEPARATOR_PAIR ) ; $ this -> err [ $ ident -> toString ( ) ] = $ value -> isInt ( ) ? $ value -> toInt ( ) : $ value -> unescape ( ) ; } Signal :: getInstance ( ) -> emit ( "notifyError" , $ this ) ; if ( $ this -> getErrorProperty ( "id" , 0x00 ) != 0x00 && $ this -> exp ) { if ( $ permid = $ this -> getErrorProperty ( "failed_permid" ) ) { if ( $ permsid = key ( $ this -> con -> request ( "permget permid=" . $ permid , false ) -> toAssocArray ( "permsid" ) ) ) { $ suffix = " (failed on " . $ permsid . ")" ; } else { $ suffix = " (failed on " . $ this -> cmd -> section ( Teamspeak :: SEPARATOR_CELL ) . " " . $ permid . "/0x" . strtoupper ( dechex ( $ permid ) ) . ")" ; } } elseif ( $ details = $ this -> getErrorProperty ( "extra_msg" ) ) { $ suffix = " (" . trim ( $ details ) . ")" ; } else { $ suffix = "" ; } throw new Ts3Exception ( $ this -> getErrorProperty ( "msg" ) . $ suffix , $ this -> getErrorProperty ( "id" ) ) ; } }
docstring: Parses a ServerQuery error and throws a Ts3Exception object if
  there's an error.
  
  @param  StringHelper|string $err
  @throws Ts3Exception
  @return void
docstring_tokens: Parses a ServerQuery error and throws a Ts3Exception object if there s an error .