Creates an instance that parses the format string when doParse is called.
A format string containing formatting specifications.
Parses the [[format]] string this instance was initialized with. The method uses the supplied resolvers map as a means for an outside class to access the intermediate state of the parser each time a specifier is visited.
A map between a specifier type and a resolver function that is called after the parser evaluates its intermediate state.
A standalone resolver function that is called for every visited character that is not considered a specifier.
Returns the current character visited by the parser.
Returns the number of CustomSpecifiersMap.zeroPlaceholder specifiers preceding the CustomSpecifiersMap.decimalPoint. If the [[format]] string contains a CustomSpecifiersMap.exponent specifier then CustomSpecifiersMap.digitPlaceholder are counted as well.
Returns the number of 0
characters following the CustomSpecifiersMap.exponent specifier.
Returns the sign character following the CustomSpecifiersMap.exponent specifier.
Returns the current index offset from the CustomSpecifiersMap.decimalPoint specifier, which is considered as the starting index.
May require a [[lookahead]] evaluation.
Returns the number of both CustomSpecifiersMap.zeroPlaceholder and CustomSpecifiersMap.digitPlaceholder specifiers after the CustomSpecifiersMap.decimalPoint.
Returns the number of CustomSpecifiersMap.zeroPlaceholder specifiers after the CustomSpecifiersMap.decimalPoint.
Returns true
if the parser has already encountered a CustomSpecifiersMap.decimalPoint specifier; otherwise, false
.
Returns true
if the parser can no longer encounter a CustomSpecifiersMap.zeroPlaceholder, CustomSpecifiersMap.digitPlaceholder or CustomSpecifiersMap.decimalPoint specifier;
otherwise, false
.
Always requires a [[lookahead]] evaluation.
Returns true
if the parser is yet to encounter a CustomSpecifiersMap.zeroPlaceholder, CustomSpecifiersMap.digitPlaceholder or CustomSpecifiersMap.decimalPoint specifier;
otherwise, false
.
Returns true
if the current parser position is exactly at the first CustomSpecifiersMap.exponent occurrence; otherwise, false
.
Returns true
if the matched CustomSpecifiersMap.exponent is an uppercase character; otherwise, false
.
Call only when isExponentMatched returned a true
value to guarantee correct behavior.
Returns true
if the current parser position is exactly after the last CustomSpecifiersMap.zeroPlaceholder, CustomSpecifiersMap.digitPlaceholder or
CustomSpecifiersMap.decimalPoint specifier; otherwise, false
.
Always requires a [[lookahead]] evaluation and internally shifts its state so that the next call to this method can also return true
if this one did.
Creates and executes a special detached parser instance that returns only the matched format sections that are separated by CustomSpecifiersMap.sectionSeparator.
A format string containing formatting specifications.
An array containing separate format sections.
Generated using TypeDoc
A Custom Numeric Format String parser implementation. It does not produce concrete formatting options but does lend its intermediate and final state to visiting instances.