|
BDE 4.39.x Production Release
|
Provide bsl::formatter specialization for bdlb::Guid.
Provide bsl::formatter specialization for bdlb::Guid.
bdlb::GuidThis component provides a partial specialization of the bsl::formatter class template for bdlb::Guid, enabling bdlb::Guid values to be used with bsl::format and its variants.
The supported format specification is a subset of the standard std::format grammar:
No sign, alternate-form (#), zero-pad (0), precision, or type specifiers are supported. The default alignment is left, matching the convention for string-like types. The formatted representation is always the canonical 36-character lowercase hexadecimal form xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.
This section illustrates intended use of this component.
Suppose we have a bdlb::Guid object and want to render it as a string:
Width, alignment, and fill are supported as they would be for a string: