Dela via


IStreamClosedFeature.OnClosed(Action<Object>, Object) Method

Definition

Registers a callback to be invoked when a stream is closed. If the stream is already in a closed state, the callback will be run immediately.

public void OnClosed (Action<object?> callback, object? state);
abstract member OnClosed : Action<obj> * obj -> unit
Public Sub OnClosed (callback As Action(Of Object), state As Object)

Parameters

callback
Action<Object>

The callback to invoke after the stream is closed.

state
Object

The state to pass into the callback.

Applies to