⬆️ version bump to v4.5

- Update obioptions.Version from "Release 4.4.29" to "/v/ Release v5"
- Update version.txt from 4.29 → .30
(automated by Makefile)
This commit is contained in:
Eric Coissac
2026-04-07 08:36:50 +02:00
parent 670edc1958
commit 8c7017a99d
392 changed files with 18875 additions and 141 deletions
@@ -0,0 +1,35 @@
# Output Compression Control Module
This Go package (`obidefault`) provides a simple, global configuration mechanism for toggling output compression behavior across an application.
## Core Features
- **Global Compression Flag**: A package-level boolean variable `__compress__` (default: `false`) controls whether output should be compressed.
- **Read Access**:
- `CompressOutput()` returns the current compression setting as a boolean.
- **Write Access**:
- `SetCompressOutput(b bool)` updates the compression flag to a new value.
- **Pointer Access**:
- `CompressOutputPtr()` returns a pointer to the internal flag, enabling indirect modification (e.g., for UI bindings or reflection-based updates).
## Design Intent
- Minimal, side-effect-free API.
- Thread-safety *not* guaranteed — intended for use in single-threaded initialization or controlled environments.
- Encapsulation via unexported variable `__compress__`, enforced through accessor functions.
## Typical Usage
```go
// Enable compression globally:
obidefault.SetCompressOutput(true)
if obidefault.CompressOutput() {
// Apply compression logic (e.g., gzip, brotli)
}
```
## Notes
- The double underscore prefix (`__compress__`) signals internal/private status (convention, not enforced).
- Designed for runtime configurability without recompilation.