Returns a string representation of the returned error code.

@return int
549799
public function getErrorName()
    {
        if (isset(self::$returnCodes[$this->returnCode])) {
            return self::$returnCodes[$this->returnCode][0];
        }

        return 'Error '.$this->returnCode;
    }
902189
protected function getSeverityString()
    {
        static $error_types = array(
            E_WARNING => 'Warning',
            E_NOTICE => 'Notice',
            E_USER_ERROR => 'User Fatal Error',
            E_USER_WARNING => 'User Warning',
            E_USER_NOTICE => 'User Notice',
            E_STRICT => 'Forward Compatibility Notice'
        );

        $out = null;
        if (isset($error_types[$this->severity])) {
            $out = $error_types[$this->severity];
        }

        return $out;
    }
966178
public function getFirstError(): string
    {
        $result = '';
        $errors = $this->getErrors();
        $firstField = reset($errors);

        if ($firstField && isset($firstField[0])) {
            $result = $firstField[0];
        }

        return $result;
    }
461487
final public function error()	{
      if ($this->resultset) {
         $pdo_error        = $this->resultset->errorInfo();
         $error['code']    = @$pdo_error[1] ? $pdo_error[0].'/'.$pdo_error[1] : $pdo_error[0];
         $error['message'] =  $pdo_error[2];
      }
      else {
         $error['code']    = '00000';
         $error['message'] = 'ERROR: No hay conexión a la base de datos';
      }

      return $error;
   }
376485
public function getErrorMessage() {
        if($this->errorMessage) {
            return $this->errorMessage;
        }

        return sprintf(self::$defaultErrorMessagePattern, $this->getName());
    }
1014323
public String getErrorMessage ()
    {
        String msg = getMessage();
        return String.valueOf(_errorCode).equals(msg) ? null : msg;
    }
1229519
public function getErrorCodeFromHandle()
    {
        $errorNumber = null;

        if ($this->handle !== null) {
            $errorNumber = curl_errno($this->handle);
        }

        return $errorNumber === 0 ? null : $errorNumber;
    }
319711
public function errorInfo() {
		$error = $this->getError();
		if($error !== false) {
			return array('HY000', $error['code'], $error['message']);
		}
		return array(PDO::ERR_NONE, null, null);
	}
1282036
public function error()
    {
        if ($this->error) {
            $debug_tpl_vars = [
                '{LANGUAGE}' => $this->language,
                '{PATH}'     => self::LANG_ROOT,
            ];
            $msg = strtr($this->error_messages[$this->error], $debug_tpl_vars);

            return "<br /><strong>GenSynth Error:</strong> $msg (code {$this->error})<br />";
        }

        return false;
    }
870662
public function getError() {
		switch ($this->error_code) {
			case UPLOAD_ERR_OK:
				return false;
			case UPLOAD_ERR_NO_FILE:
				$error = 'upload:error:no_file';
			case UPLOAD_ERR_INI_SIZE:
			case UPLOAD_ERR_FORM_SIZE:
				$error = 'upload:error:file_size';
			default:
				$error = 'upload:error:unknown';
		}
		return elgg_echo($error);
	}
222166
public function errorMessage()
	{
		if ($this->decoded() === null) {
			throw new \RuntimeException('No result from server.');
		}

		$decoded = $this->decoded();
		if (isset($decoded->error))
			return sprintf('%s (%s)', $decoded->error->message, $decoded->error->code);

		$message = sprintf('%s (%s)', $decoded->message, $this->statusCode());

		if (isset($this->decoded()->errors)) {
			$errors = $this->decoded()->errors;

			$message .= $this->resolveAttributes($errors);
		}

		return $message;
	}
15368
public function getString()
    {
        $html = '';
        if ($this->error->has()) {
            $html .= '<ul class="ccm-error">';
            foreach ($this->error->getList() as $error) {
                $html .= '<li>';
                if ($error instanceof HtmlAwareErrorInterface && $error->messageContainsHtml()) {
                    $html .= (string) $error;
                } else {
                    $html .= nl2br(h((string) $error));
                }
                $html .= '</li>';
            }
            $html .= '</ul>';
        }

        return $html;
    }
201444
protected function createErrorString()
    {
        $str = '';
        if ( $this->errorType !== null )
        {
            $str .= ", error='{$this->errorType}'";
        }

        if ( $this->errorMessage !== null )
        {
            $str .= ", error_description='{$this->errorMessage}'";
        }
        return $str;
    }
1059009
public function errorInfo(): string
    {
        $errorInfo = $this->statement->errorInfo();
        return !isset($errorInfo[0]) || 0 == $errorInfo[0] ? '' : implode(' ', $errorInfo);
    }
504570
public function getErrorRegion()
    {
        $region = '';
        $extra = $this->getExtra();

        if (isset($extra['file']) && file_exists($extra['file'])) {
            $lines = file($extra['file']);

            if (isset($lines[$extra['line'] - 1])) {
                $line = $lines[$extra['line'] - 1];
                $region .= sprintf("\t%s", str_replace("\t", ' ', $line));

                if (($extra['char'] - 1) > 0) {
                    $region .= sprintf("\t%s^\n", str_repeat('-', $extra['char'] - 1));
                }
            }
        }

        return $region;
    }
201653
public function getError() {
        return (object) [
            "code"    => $this->getCode(),
            "message" => $this->getMessage(),
            "details" => $this->getDetails(),
            "key"     => $this->getKey()
        ];
    }
747098
public function getErrorMessage()
    {
        if ($this->returnLetter instanceof ReturnLetter
                && $this->returnLetter->errorID !== 0) {
            return $this->returnLetter->error;
        }
    }