Class: module:br/formatting/PercentFormatter

module:br/formatting/PercentFormatter

Converts the number to a percentage.

PercentFormatter is typically used with Presenter, but can be invoked programmatically as in the following example which evaluates to "61.8%":

br.formatting.PercentFormatter.format(0.618, {dp:1})

Constructor

new module:br/formatting/PercentFormatter()

Implements:
Source:

Methods

format(vValue, mAttributes)

Converts a decimal number to a percentage.
Parameters:
Name Type Description
vValue Variant the decimal number (String or Number type).
mAttributes Map a list of attributes, as specified in module:br/formatting/RoundingFormatter.
Implements:
Source:
Returns:
the number specified as a percentage.

Docs generated using BladeRunnerJS v1.5.8-0.g69b027a on Fri Dec 16 2016 11:11:53 GMT-0000 (GMT)