Uri.UserEscaped Özellik

Tanım

Örnek oluşturulmadan önce Uri URI dizesinin tamamen kaçılıp kaçılmadığını gösteren bir değer alır.

public:
 property bool UserEscaped { bool get(); };
public bool UserEscaped { get; }
member this.UserEscaped : bool
Public ReadOnly Property UserEscaped As Boolean

Özellik Değeri

Boolean

truedontEscape parametresi örnek oluşturulduğunda olarak ayarlandıysa true Uri; aksi takdirde , false.

Örnekler

Aşağıdaki örnek bir Uri örnek oluşturur ve oluşturulduğunda tam olarak kaçılıp kaçılmadığını belirler.

Uri^ uriAddress = gcnew Uri( "http://user:password@www.contoso.com/index.htm " );
Console::WriteLine( uriAddress->UserInfo );
Console::WriteLine( "Fully Escaped {0}",
   uriAddress->UserEscaped ? (String^)"yes" : "no" );
Uri uriAddress = new Uri ("http://user:password@www.contoso.com/index.htm ");
Console.WriteLine(uriAddress.UserInfo);
Console.WriteLine("Fully Escaped {0}", uriAddress.UserEscaped ? "yes" : "no");
let uriAddress = Uri "http://user:password@www.contoso.com/index.htm "
printfn $"{uriAddress.UserInfo}"
printfn $"""Fully Escaped {if uriAddress.UserEscaped then "yes" else "no"}"""
Dim uriAddress As New Uri("http://user:password@www.contoso.com/index.htm ")
Console.WriteLine(uriAddress.UserInfo)
Console.WriteLine("Fully Escaped {0}", IIf(uriAddress.UserEscaped, "yes", "no")) 'TODO: For performance reasons this should be changed to nested IF statements

Açıklamalar

UserEscaped özelliği, örneği oluşturmak için kullanılan dizenin Uri oluşturucuya geçirilmeden önce tamamen kaçıldığını belirtmek için ayarlanırtrue; yani oluşturucu dontEscape çağrısının parametresi olarak trueayarlanmıştır.

Şunlara uygulanır