UriFormat 枚举

定义

控制 URI 信息的转义方式。Controls how URI information is escaped.

public enum class UriFormat
public enum UriFormat
type UriFormat = 
Public Enum UriFormat
继承
UriFormat

字段

SafeUnescaped 3

在请求的 URI 组成部分中具有保留意义的字符将仍然进行转义。Characters that have a reserved meaning in the requested URI components remain escaped. 所有其他字符不进行转义。All others are not escaped.

Unescaped 2

未执行任何转义。No escaping is performed.

UriEscaped 1

根据 RFC 2396 中的规则执行转义。Escaping is performed according to the rules in RFC 2396.

注解

此枚举由 GetComponents 方法用来指定返回的 URI 中的字符转义级别。This enumeration is used by the GetComponents method to specify the level of character escaping in the returned URI.

RFC 2396 定义了 Uri 的标准转义,在https://rfc-editor.org可用。RFC 2396 defines the standard escaping for URIs, and is available at https://rfc-editor.org.

如果字符在请求的 UriComponents中具有保留含义,SafeUnescaped 将保留以下转义字符: "%"、"#"、"?"、"/"、"\" 和 "@"。</span><span class="sxs-lookup">SafeUnescaped leaves the following characters escaped if the character has a reserved meaning in the requested UriComponents: "%", "#", "?", "/", "\", and "@".

适用于