Table of Contents

Method WaitUntilSettledAsync

Namespace
OBSStudioClient.Model
Assembly
OBSClient.dll

WaitUntilSettledAsync(TimeSpan?, CancellationToken)

Waits until the model has applied everything that has arrived and has nothing left to read.

public Task WaitUntilSettledAsync(TimeSpan? timeout = null, CancellationToken cancellationToken = default)

Parameters

timeout TimeSpan?

How long to wait, or null (or InfiniteTimeSpan) to wait for as long as it takes. It can be up to 24 days.

cancellationToken CancellationToken

A token that ends the wait.

Returns

Task

Remarks

OBS Studio announces a change with an event, which can arrive a few milliseconds after the response to the request that made the change. An event that OBS Studio has not sent yet cannot be waited for: this waits for what has arrived.

Exceptions

ArgumentOutOfRangeException

timeout is negative, or longer than 24 days.

ObsNotConnectedException

There is no connection (or it ended during the wait).

TimeoutException

The model was not up to date within the time.

OperationCanceledException

cancellationToken was cancelled.