Core LibraryAPI Reference

Choose documentation 3

latest

Current version

latest
English

Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

method libtmux-dotnet latest

TmuxWait.UntilAsync

Namespace LibTmux.TmuxWait.UntilAsync LibTmux

Waits until a probe reports the state was reached.

View as Markdown

Source and package
Module
LibTmux
Declared in
TmuxWait
Package
LibTmux
Source
src/LibTmux/Waiting/TmuxWait.cs
UntilAsync ( probe : Func<CancellationToken, Task<bool>> , timeout : TimeSpan , interval : TimeSpan , throwOnTimeout : bool , cancellationToken : CancellationToken ) → Task<bool> ( probe : Func<CancellationToken, Task<T>> , predicate : Func<T, bool> , timeout : TimeSpan , interval : TimeSpan , cancellationToken : CancellationToken ) → Task<T>
methodstaticasyncoverload2 overloads [source]
Parameters
  • probe ( Func<CancellationToken, Task<bool>> ) – Answers whether the state has been reached. (for UntilAsync(probe, timeout, interval, throwOnTimeout, cancellationToken))

  • timeout ( TimeSpan ) – How long to keep asking. (for UntilAsync(probe, timeout, interval, throwOnTimeout, cancellationToken))

  • interval ( TimeSpan ) – How long to wait between askings. (for UntilAsync(probe, timeout, interval, throwOnTimeout, cancellationToken))

  • throwOnTimeout ( bool ) – Whether running out is a failure. (for UntilAsync(probe, timeout, interval, throwOnTimeout, cancellationToken))

  • cancellationToken ( CancellationToken ) – Cancels the wait.

  • probe ( Func<CancellationToken, Task<T>> ) – Reads the current value. (for UntilAsync(probe, predicate, timeout, interval, cancellationToken))

  • predicate ( Func<T, bool> ) – Answers whether a reading is the wanted one. (for UntilAsync(probe, predicate, timeout, interval, cancellationToken))

  • timeout ( TimeSpan ) – How long to keep reading. (for UntilAsync(probe, predicate, timeout, interval, cancellationToken))

  • interval ( TimeSpan ) – How long to wait between readings. (for UntilAsync(probe, predicate, timeout, interval, cancellationToken))

Returns

True when the state was reached. (for UntilAsync(probe, timeout, interval, throwOnTimeout, cancellationToken))

The first reading the predicate accepted. (for UntilAsync(probe, predicate, timeout, interval, cancellationToken))

Raises
  • TmuxWaitTimeoutException – The state was not reached and running out was to be a failure. (for UntilAsync(probe, timeout, interval, throwOnTimeout, cancellationToken))

  • TmuxWaitTimeoutException – No reading was accepted in time. (for UntilAsync(probe, predicate, timeout, interval, cancellationToken))

Discussed in Waiting and retrying

Esc

Type to search.