[#BloombergLP-bslfmt-TestSpecificationGenerator]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslfmt.adoc[bslfmt]::TestSpecificationGenerator
:relfileprefix: ../../
:mrdocs:

Generator of exhaustive standard formatting&hyphen;specification combinations&period;

== Synopsis

Declared in `&lt;bslfmt&lowbar;testspecificationgenerator&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class t&lowbar;CHAR&gt;
class TestSpecificationGenerator;
----

== Description

This class is a generator that provides a set of formatting specifications obtained by exhaustive search of all combinations of standard options&period; Its use allows easy and thorough testing of formatters for standard types&period; The generator is a state machine, each state of which corresponds to a separate specification&period;

== Enums

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/Alignment-06.adoc[`Alignment`] 
| Alignment option values corresponding to format alignment characters&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/FormatType.adoc[`FormatType`] 
| Format presentation types corresponding to standard format type chars&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/NestedVariant.adoc[`NestedVariant`] 
| Nested width or precision argument&hyphen;id variants&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/Sign-0c.adoc[`Sign`] 
| Sign option values corresponding to format sign characters&period;
|===


== Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/2constructor.adoc[`TestSpecificationGenerator`]         [.small]#[constructor]#
| Create a generator object&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/addFillCharacter.adoc[`addFillCharacter`] 
| Add a fill character to the set used when generating specifications&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/addPrecision.adoc[`addPrecision`] 
| Add a precision value to the set used when generating specifications&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/addWidth.adoc[`addWidth`] 
| Add a width value to the set used when generating specifications&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/alignment-0d.adoc[`alignment`] 
| Return the current alignment type&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/fillCharacter.adoc[`fillCharacter`] 
| Return the current fill character&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/formatSpec.adoc[`formatSpec`] 
| Return the current generated format specification string&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isAlignOptionPresent.adoc[`isAlignOptionPresent`] 
| Return `true` if the align option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isFillCharacterPresent.adoc[`isFillCharacterPresent`] 
| Return `true` if the fill character is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isHashOptionPresent.adoc[`isHashOptionPresent`] 
| Return `true` if the alternative form option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isLocaleOptionPresent.adoc[`isLocaleOptionPresent`] 
| Return `true` if the locale option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isNestedPrecisionPresent.adoc[`isNestedPrecisionPresent`] 
| Return `true` if the nested precision option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isNestedWidthPresent.adoc[`isNestedWidthPresent`] 
| Return `true` if the nested width option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isPrecisionOptionPresent.adoc[`isPrecisionOptionPresent`] 
| Return `true` if the precision option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isSignOptionPresent.adoc[`isSignOptionPresent`] 
| Return `true` if the sign option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isStateValidForFormat.adoc[`isStateValidForFormat`] 
| Return `true` if the generated specification based on the current state of this object is valid for the formatters `format` method, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isStateValidForParse.adoc[`isStateValidForParse`] 
| Return `true` if the generated specification based on the current state of this object is valid for the formatters `parse` method, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isTypeOptionPresent.adoc[`isTypeOptionPresent`] 
| Return `true` if the presentation type option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isValueIdOptionPresent.adoc[`isValueIdOptionPresent`] 
| Return `true` if the value id option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isWidthOptionPresent.adoc[`isWidthOptionPresent`] 
| Return `true` if the width option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/isZeroOptionPresent.adoc[`isZeroOptionPresent`] 
| Return `true` if the zero option is present in the current state of this object, and `false` otherwise&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/nestedPrecisionVariant.adoc[`nestedPrecisionVariant`] 
| Return the current nested precision variant&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/nestedWidthVariant.adoc[`nestedWidthVariant`] 
| Return the current nested width variant&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/next.adoc[`next`] 
| Switch this object to the next state and generate specification based on the new state&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/nextValidForFormat.adoc[`nextValidForFormat`] 
| Advance to the next state that yields a specification valid for `format`&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/nextValidForParse.adoc[`nextValidForParse`] 
| Advance to the next state that yields a specification valid for `parse`&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/precision.adoc[`precision`] 
| Return the current precision value&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/setup.adoc[`setup`] 
| Configure the generator state sequence from an option instruction&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/sign-0b.adoc[`sign`] 
| Return the current sign option value&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/spec.adoc[`spec`] 
| Return the specification for the formatters `parse` method based on the current state of this object&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/type.adoc[`type`] 
| Return the current presentation type value&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/width.adoc[`width`] 
| Return the current width value&period;
| xref:BloombergLP/bslfmt/TestSpecificationGenerator/2conversion.adoc[`operator BloombergLP::bslmf::NestedTraitDeclaration&lt;TestSpecificationGenerator, UsesBslmaAllocator&gt;`] 
| Declare `TestSpecificationGenerator` as using bslma allocator&period;
|===



[.small]#Created with https://www.mrdocs.com[MrDocs]#
