Bagikan melalui


SecurityManager.IsGranted(IPermission) Metode

Definisi

Perhatian

API ini sudah tidak digunakan lagi.

Perhatian

IsGranted is obsolete and will be removed in a future release of the .NET Framework. Please use the PermissionSet property of either AppDomain or Assembly instead.

Menentukan apakah izin diberikan kepada pemanggil.

public:
 static bool IsGranted(System::Security::IPermission ^ perm);
[System.Obsolete]
public static bool IsGranted (System.Security.IPermission perm);
public static bool IsGranted (System.Security.IPermission perm);
[System.Obsolete("IsGranted is obsolete and will be removed in a future release of the .NET Framework.  Please use the PermissionSet property of either AppDomain or Assembly instead.")]
public static bool IsGranted (System.Security.IPermission perm);
[<System.Obsolete>]
static member IsGranted : System.Security.IPermission -> bool
static member IsGranted : System.Security.IPermission -> bool
[<System.Obsolete("IsGranted is obsolete and will be removed in a future release of the .NET Framework.  Please use the PermissionSet property of either AppDomain or Assembly instead.")>]
static member IsGranted : System.Security.IPermission -> bool
Public Shared Function IsGranted (perm As IPermission) As Boolean

Parameter

perm
IPermission

Izin untuk menguji terhadap pemberian pemanggil.

Mengembalikan

true jika izin yang diberikan kepada penelepon menyertakan izin perm; jika tidak, false.

Atribut

Keterangan

Pemberian izin ditentukan oleh kebijakan dan berbeda dari permintaan yang tunduk pada penimpaan, seperti pernyataan. Selain itu, IsGranted hanya menguji pemberian perakitan kode panggilan, terlepas dari pemanggil lain pada tumpukan.

Berlaku untuk