CodeAccessPermission.GetHashCode 方法

定義

取得 CodeAccessPermission 物件的雜湊碼,其適合用於雜湊表這類的雜湊演算法和資料結構。Gets a hash code for the CodeAccessPermission object that is suitable for use in hashing algorithms and data structures such as a hash table.

public:
 override int GetHashCode();
public override int GetHashCode ();
[System.Runtime.InteropServices.ComVisible(false)]
public override int GetHashCode ();
override this.GetHashCode : unit -> int
[<System.Runtime.InteropServices.ComVisible(false)>]
override this.GetHashCode : unit -> int
Public Overrides Function GetHashCode () As Integer

傳回

Int32

目前 CodeAccessPermission 物件的雜湊碼。A hash code for the current CodeAccessPermission object.

屬性

備註

相同許可權的兩個實例的雜湊碼可能不同,因此不應該使用雜湊碼來比較兩個 CodeAccessPermission 物件。The hash code for two instances of the same permission might be different, hence a hash code should not be used to compare two CodeAccessPermission objects.

適用於