Format a string in "val", obeying appropriate alignment, padding, width, and precision. Treats Align::DEFAULT as Align::LEFT, and Align::PAD_AFTER_SIGN as Align::RIGHT; use formatNumber for number-specific formatting.
Declared in <folly/Format.h>
template<class FormatCallback>
void
formatString(
StringPiece val,
FormatArg& arg,
FormatCallback& cb);
| Name | Description |
|---|---|
| val | The string value to format. |
| arg | The format argument describing alignment, padding, and width. |
| cb | The callback that receives the formatted output. |