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

Session.HoldWaitClientAsync

Namespace LibTmux.Session.HoldWaitClientAsync LibTmux

Keeps the control client that waits on this session's panes use attached until the handle is disposed.

View as Markdown

Source and package
Module
LibTmux
Declared in
Session
Package
LibTmux
Source
src/LibTmux/Session.Scopes.cs
HoldWaitClientAsync ( cancellationToken : CancellationToken ) → Task<IAsyncDisposable>
method [source]

Description#

A wait on a pane attaches a control client to the pane's session and reads through it, and lets it go when the wait ends unless another wait still needs it. Attaching costs about as much as a tmux process start, so holding the client saves that for each wait in a series, which then costs little more than the keys it sends.

The client ignores its size, so it leaves window sizes alone, and is excluded wherever this library tells observers from people attached. tmux itself still lists it among the session's clients while it is held, so the session counts as attached for destroy-unattached, and the client keeps reading the session's output while no wait runs. The hold is for this server process: one started again needs a new one. When control mode is unavailable the waits poll, and the handle holds nothing.

Parameters
Returns

A handle; disposing it lets the client detach once no wait needs it.

Esc

Type to search.