Uri.EscapeString(String) Metodo

Definizione

Attenzione

The method has been deprecated. Please use GetComponents() or static EscapeUriString() to escape a Uri component or a string. http://go.microsoft.com/fwlink/?linkid=14202

Attenzione

The method has been deprecated. Please use GetComponents() or static EscapeUriString() to escape a Uri component or a string. https://go.microsoft.com/fwlink/?linkid=14202

Converte una stringa nella relativa rappresentazione di escape.

protected:
 static System::String ^ EscapeString(System::String ^ str);
protected static string EscapeString(string str);
[System.Obsolete("The method has been deprecated. Please use GetComponents() or static EscapeUriString() to escape a Uri component or a string. http://go.microsoft.com/fwlink/?linkid=14202")]
protected static string EscapeString(string str);
[System.Obsolete("The method has been deprecated. Please use GetComponents() or static EscapeUriString() to escape a Uri component or a string. https://go.microsoft.com/fwlink/?linkid=14202")]
protected static string EscapeString(string str);
static member EscapeString : string -> string
[<System.Obsolete("The method has been deprecated. Please use GetComponents() or static EscapeUriString() to escape a Uri component or a string. http://go.microsoft.com/fwlink/?linkid=14202")>]
static member EscapeString : string -> string
[<System.Obsolete("The method has been deprecated. Please use GetComponents() or static EscapeUriString() to escape a Uri component or a string. https://go.microsoft.com/fwlink/?linkid=14202")>]
static member EscapeString : string -> string
Protected Shared Function EscapeString (str As String) As String

Parametri

str
String

Stringa da trasformare nella relativa rappresentazione di escape.

Valori restituiti

Rappresentazione di escape della stringa.

Attributi

Commenti

Il EscapeString metodo converte i caratteri riservati RFC 2396 e tutti i caratteri con un valore di carattere maggiore di 127 in rappresentazione esadecimale. Tutti i caratteri Unicode vengono convertiti in formato UTF-8 prima di essere preceduti da un carattere di escape.

Per impostazione predefinita, la stringa viene preceduta da un escape in base a RFC 2396. Se è abilitata l'analisi IDN (International Resource Identifiers) o Internationalized Domain Name (IDN), la stringa viene preceduta da un carattere di escape in base a RFC 3986 e RFC 3987.

Per altre informazioni sul supporto IRI, vedere la sezione Osservazioni per la Uri classe .

Si applica a