Share via


Url 類別

定義

警告

Code Access Security is not supported or honored by the runtime.

提供程式碼組件的來源 URL 做為原則評估的辨識項。 此類別無法獲得繼承。

public ref class Url sealed : System::Security::Policy::EvidenceBase, System::Security::Policy::IIdentityPermissionFactory
public ref class Url sealed : System::Security::Policy::IIdentityPermissionFactory
[System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public sealed class Url : System.Security.Policy.EvidenceBase, System.Security.Policy.IIdentityPermissionFactory
[System.Serializable]
public sealed class Url : System.Security.Policy.IIdentityPermissionFactory
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public sealed class Url : System.Security.Policy.IIdentityPermissionFactory
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public sealed class Url : System.Security.Policy.EvidenceBase, System.Security.Policy.IIdentityPermissionFactory
public sealed class Url : System.Security.Policy.EvidenceBase, System.Security.Policy.IIdentityPermissionFactory
[<System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type Url = class
    inherit EvidenceBase
    interface IIdentityPermissionFactory
[<System.Serializable>]
type Url = class
    interface IIdentityPermissionFactory
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type Url = class
    interface IIdentityPermissionFactory
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type Url = class
    inherit EvidenceBase
    interface IIdentityPermissionFactory
type Url = class
    inherit EvidenceBase
    interface IIdentityPermissionFactory
Public NotInheritable Class Url
Inherits EvidenceBase
Implements IIdentityPermissionFactory
Public NotInheritable Class Url
Implements IIdentityPermissionFactory
繼承
繼承
Url
屬性
實作

備註

警告

程式代碼存取安全性 (CAS) 在所有版本的 .NET Framework 和 .NET 中已被取代。 使用 CAS 相關 API 時,最新版本的 .NET 不會接受 CAS 批注,併產生錯誤。 開發人員應尋求替代方案來完成安全性工作。

辨識項 Url 是否存在會在授與集中產生 UrlIdentityPermissionDemand如果有的 UrlIdentityPermission,則UrlIdentityPermission對應至辨識項的 Url 會與要求的許可權進行比較。

系統會考慮完整的 URL,包括通訊協定 (HTTP、HTTPS、FTP) 和檔案。 例如, http://www.fourthcoffee.com/process/grind.htm 是完整的 URL。

URL 可以完全比對,或是由最後一個位置的通配符進行比對。 例如, http://www.fourthcoffee.com/process/* 是通配符 URL。

建構函式

Url(String)
已淘汰.

使用程式碼組件的來源 URL 初始化 Url 類別的新執行個體。

屬性

Value
已淘汰.

取得 URL,其為程式碼組件的來源。

方法

Clone()
已淘汰.

建立目前執行個體複本的新物件。

Clone()
已淘汰.

建立新物件,該物件是目前執行個體的完整複本。

(繼承來源 EvidenceBase)
Copy()
已淘汰.

建立辨識項物件的新複本。

CreateIdentityPermission(Evidence)
已淘汰.

建立對應於 Url 辨識項類別目前執行個體的識別 (Identity) 使用權限。

Equals(Object)
已淘汰.

比較目前的 Url 辨識項物件與指定物件是否相等。

GetHashCode()
已淘汰.

取得目前 URL 的雜湊程式碼。

GetType()
已淘汰.

取得目前執行個體的 Type

(繼承來源 Object)
MemberwiseClone()
已淘汰.

建立目前 Object 的淺層複製。

(繼承來源 Object)
ToString()
已淘汰.

傳回目前 Url 的字串表示。

適用於