# LibTmux.IControlModeSession

- **Module:** LibTmux
- **Package:** LibTmux
- **Language:** .NET
- **Kind:** interface
- **Source:** https://github.com/libtmux/libtmux-dotnet/blob/320dc64f4b8b7815842471327a5e6b84a1499bf8/src/LibTmux/ControlMode/IControlModeSession.cs#L17
- **Page:** https://libtmux.org/en/dotnet/latest/reference/libtmux-icontrolmodesession/

A live tmux control client.

One-shot commands start a tmux client, run one thing, and exit. A control
session keeps one client for as long as it is held, which is what makes
tmux willing to report what happens while nobody asked: pane output, windows
appearing, sessions changing.

Disposing ends the client. Everything a caller reads comes through
<see cref="Events" />, which completes after a normal exit and faults after
buffered events when the control stream fails.

## Members

- `Events` (property): Reads what tmux reports for as long as the client runs.
- `IsRunning` (property): Gets whether the client is still running.
- `SendAsync` (method): Runs one command on this client and reads what it answered.
