SecurityManager.PolicyHierarchy 方法

定義

警告

此 API 現已淘汰。

警告

This method is obsolete and will be removed in a future release of the .NET Framework. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.

提供依層級存取安全性原則階層的列舉程式,例如電腦原則和使用者原則。

public:
 static System::Collections::IEnumerator ^ PolicyHierarchy();
[System.Obsolete]
public static System.Collections.IEnumerator PolicyHierarchy ();
public static System.Collections.IEnumerator PolicyHierarchy ();
[System.Obsolete("This method is obsolete and will be removed in a future release of the .NET Framework. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.")]
public static System.Collections.IEnumerator PolicyHierarchy ();
[<System.Obsolete>]
static member PolicyHierarchy : unit -> System.Collections.IEnumerator
static member PolicyHierarchy : unit -> System.Collections.IEnumerator
[<System.Obsolete("This method is obsolete and will be removed in a future release of the .NET Framework. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.")>]
static member PolicyHierarchy : unit -> System.Collections.IEnumerator
Public Shared Function PolicyHierarchy () As IEnumerator

傳回

構成安全性原則階層之 PolicyLevel 物件的列舉程式。

屬性

例外狀況

此方法使用程式碼存取安全性 (CAS) 原則,在 .NET Framework 4 中已過時。 若要啟用 CAS 原則對舊版 .NET Framework 的相容性,請使用 <legacyCasPolicy> 項目

呼叫此方法的程式碼沒有 ControlPolicy

備註

傳回的列舉值會提供後續 PolicyLevel 物件,這些物件代表位於階層之個別 (電腦、使用者、企業、應用程式域) 層級的原則。 這些物件是即時原則物件;改變這些物件可能會產生無法預期的結果。

最低原則階層是由電腦層級、企業層級和使用者層級所組成。 不過,階層可以包含其他層級。

適用於