|
StormByte C++ Library: Logger module 1.2.0
StormByte-Logger is the logging module of the StormByte C++ suite.
|
Stateful redaction manipulator. More...
#include <StormByte/logger/manipulators.hxx>
Public Member Functions | |
| constexpr RedactManip | operator() (std::size_t n) const noexcept |
Build a manipulator that keeps the last n characters visible. | |
Public Attributes | |
| std::size_t | count = 0 |
| 0 = mask all; N = keep N characters | |
| bool | keep_first = false |
| true = keep first N, false = keep last N characters | |
Stateful redaction manipulator.
count characters stay readable.count characters stay readable.Applies to both text and numbers (numbers are converted to string first). Remains active until noredact.
Usage:
|
inlineconstexprnoexcept |
Build a manipulator that keeps the last n characters visible.
| n | Number of trailing characters to keep unmasked. |
| std::size_t StormByte::Logger::RedactManip::count = 0 |
0 = mask all; N = keep N characters
| bool StormByte::Logger::RedactManip::keep_first = false |
true = keep first N, false = keep last N characters