Method WaitNext
WaitNext()
Blocks the current thread and waits the next incoming message from this web socket instance.
public WebSocketMessage? WaitNext()
Returns
Remarks
Null is returned if a connection error is thrown.
WaitNext(TimeSpan)
Blocks the current thread and waits the next incoming message from this web socket instance within the maximum defined timeout.
public WebSocketMessage? WaitNext(TimeSpan timeout)
Parameters
timeout
TimeSpanThe maximum time to wait until the next message.
Returns
Remarks
Null is returned if a connection error is thrown.