# io.github.libtmux.Options.Options.setIfAbsent

- **Module:** io.github.libtmux.Options.Options
- **Package:** io.github.libtmux:libtmux
- **Language:** Java
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-java/blob/842228310449e879ebcaa3f910597757c9dbffd6/libtmux/src/main/java/io/github/libtmux/Options.java#L190
- **Page:** https://libtmux.org/en/java/latest/reference/io-github-libtmux-options-options-setifabsent/

```
io.github.libtmux.Options.Options.setIfAbsent(name: String, value: String) -> boolean
```

Sets one option only if this scope does not already set it.

tmux reports the already-set case as an error, which it is not: declining to overwrite is
the whole point of asking. The answer comes back as a value instead.

## Returns

whether the value was taken, false when this scope already set the option
