UdpAnySourceMulticastClient.Dispose メソッド

定義

注意事項

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

マルチキャスト グループへの参加を終了し、UdpAnySourceMulticastClient クラスの現在のインスタンスによって使用されたリソースと、基になる Socket によって使用されたリソースをすべて解放します。

public:
 virtual void Dispose();
[System.Obsolete("This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.", true)]
public void Dispose ();
[<System.Obsolete("This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.", true)>]
abstract member Dispose : unit -> unit
override this.Dispose : unit -> unit
Public Sub Dispose ()

実装

属性

注釈

Dispose を使い終わったら UdpAnySourceMulticastClient を呼び出します。 Dispose メソッドは、 UdpAnySourceMulticastClient を使用できない状態のままにします。 Dispose呼び出し後は、UdpAnySourceMulticastClientによって占有されていたメモリをガベージ コレクターがクリアできるよう、UdpAnySourceMulticastClient へのすべての参照を解放する必要があります。

Dispose への最後の参照を解放する前に、必ず UdpAnySourceMulticastClient を呼び出してください。 そうしないと、ガベージ コレクターが UdpAnySourceMulticastClient オブジェクトの Finalize メソッドを呼び出すまで、使用されているリソースは解放されません。

適用対象