changelog: update 1.4.0

This commit is contained in:
Leonid Stryzhevskyi 2024-05-14 06:44:43 +03:00
parent 19114d749f
commit e0d9266faa

View File

@ -12,6 +12,7 @@ Contents:
- [oatpp::Tree](#oatpptree)
- [Remapper](#remapper)
- [oatpp::web::mime::ContentMappers](#oatppwebmimecontentmappers)
- [New OATPP_LOGx format](#new-oatpp_logx-format)
- [Restructuring](#restructuring)
@ -149,6 +150,29 @@ on `Content-Type`/`Accept` headers.
}
```
## New OATPP_LOGx format
Now oatpp logs are type-safe. Also log formatting changed.
#### Macro
| old logs | new logs |
|--------------|--------------|
| `OATPP_LOGV` | `OATPP_LOGv` |
| `OATPP_LOGD` | `OATPP_LOGd` |
| `OATPP_LOGI` | `OATPP_LOGi` |
| `OATPP_LOGW` | `OATPP_LOGw` |
| `OATPP_LOGE` | `OATPP_LOGe` |
#### Formatting
Instead of old formatting "%s", "%d", "%f" use "{}" for any variable type:
```cpp
OATPP_LOGd("MyController", "User: name={}, age={}", user->name, user->age)
```
## Restructuring
### Files