# io.github.libtmux.ServerEndpoint.ServerEndpoint

- **Module:** io.github.libtmux.ServerEndpoint
- **Package:** io.github.libtmux:libtmux
- **Language:** Java
- **Kind:** interface
- **Source:** https://github.com/libtmux/libtmux-java/blob/842228310449e879ebcaa3f910597757c9dbffd6/libtmux/src/main/java/io/github/libtmux/ServerEndpoint.java#L18
- **Page:** https://libtmux.org/en/java/latest/reference/io-github-libtmux-serverendpoint-serverendpoint/

Which tmux server to talk to.

A value, decided and comparable before any process runs. Two endpoints are equal when they name
the same server lexically; nothing here resolves symlinks, contacts the filesystem, or opens a
socket. That matters because an endpoint is routinely built, logged and compared while the socket
it names does not exist yet.

Validation that needs tmux — above all whether a socket path fits the platform's
{@code sun_path} — happens at dispatch, where the error can carry the command that hit it.

## Members

- `flags` (method): The flags that select this server, in argv order.
- `defaultSocket` (method): tmux's own default server, wherever tmux decides that is.
- `namedSocket` (method): A server named with {@code -L}, resolved by tmux under its own socket directory.
- `socketPath` (method): A server at an exact socket path, selected with {@code -S}.
- `Default` (struct): Adds no flags, so tmux applies its own default socket resolution.
- `NamedSocket` (struct): A server tmux locates by name under its own socket directory.
- `SocketPath` (struct): A server at an exact socket path.
