CngKey.Dispose 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
釋放目前類別實例 CngKey 所使用的所有資源。
public:
virtual void Dispose();
public void Dispose();
[System.Security.SecurityCritical]
public void Dispose();
abstract member Dispose : unit -> unit
override this.Dispose : unit -> unit
[<System.Security.SecurityCritical>]
abstract member Dispose : unit -> unit
override this.Dispose : unit -> unit
Public Sub Dispose ()
實作
- 屬性
備註
使用完Dispose後再打電話CngKey。 此 Dispose 方法會使 在 CngKey 無法使用的狀態下。 呼叫 Dispose後,您必須解除所有對 的 CngKey 引用,讓垃圾回收器能回收原本 CngKey 佔用的記憶體。 欲了解更多資訊,請參閱《 清理未管理資源 及 實施處置方法》。