# io.github.libtmux.kotlin.Hooks

- **Module:** io.github.libtmux.kotlin
- **Package:** io.github.libtmux:libtmux-kotlin
- **Language:** Kotlin
- **Kind:** class
- **Source:** https://github.com/libtmux/libtmux-java/blob/f56392b5d9bc7f1f9c1631842333fb90f3d82d40/libtmux-kotlin/src/main/kotlin/io/github/libtmux/kotlin/Hooks.kt#L11
- **Page:** https://libtmux.org/en/kotlin/latest/reference/io-github-libtmux-kotlin-hooks/

```
public class Hooks
```

Read and update hooks for the server, session, window, or pane that owns this handle.

Holds the Java handle privately, so a member here always wins over a same-named catalog-generated
extension in `HooksOperations.kt`.

## Members

### Other members

- `` `set` `` (method): Binds a tmux command to an event at this scope, replacing anything already bound to it.
- `all` (method): Every hook at this scope, keyed by event, each with its commands in the order tmux runs them.
- `append` (method): As [.append(String, String)], with the command as words.
- `asJava` (property): The Java hooks this wraps: the same object, for a Java API that takes one.
- `equals` (method)
- `hashCode` (method)
- `run` (method): Runs what is bound to an event now, without waiting for the event.
- `server` (property)
- `toString` (method)
- `unset` (method): Removes everything bound to an event at this scope.
