ServicesConfiguratorUiCallback.Internal.UnitMeasureFormatter

configurator-core/src/services/configurator-ui-callback.internal.UnitMeasureFormatter

Table of contents

Constructors

Methods

Constructors

constructor

new UnitMeasureFormatter()

Methods

formatMMValueToUnitString

formatMMValueToUnitString(aValue, aUnit, aStringType): string

Parameters

Name
Type

aValue

number

aUnit

aStringType

Returns

string


formatMMValueWithReqMaxLength

formatMMValueWithReqMaxLength(aValue, aUnit, reqMaxSize): string

Parameters

Name
Type

aValue

number

aUnit

reqMaxSize

number

Returns

string


formatNumber

formatNumber(aValue, digit): string

Parameters

Name
Type

aValue

number

digit

number

Returns

string


formatSquareMMValueToUnitString

formatSquareMMValueToUnitString(aValue, aUnit): string

Parameters

Name
Type

aValue

number

aUnit

Returns

string


init

init(mmLabel, cmLabel, ftShortLabel, ftLongLabel, inchShortLabel, inchLongLabel, sqMLabel, sqftLabel, showExactValue, maxPrecision, showFractionalUnitString): void

Parameters

Name
Type

mmLabel

string

cmLabel

string

ftShortLabel

string

ftLongLabel

string

inchShortLabel

string

inchLongLabel

string

sqMLabel

string

sqftLabel

string

showExactValue

boolean

maxPrecision

number

showFractionalUnitString

boolean

Returns

void


isParseableNumber

isParseableNumber(aString): boolean

Parameters

Name
Type

aString

string

Returns

boolean


isParseableUnitString

isParseableUnitString(aString, aUnit): boolean

Parameters

Name
Type

aString

string

aUnit

Returns

boolean


parseMMValueFromUnitString

parseMMValueFromUnitString(aString, aUnit): number

Parameters

Name
Type

aString

string

aUnit

Returns

number


parseNumber

parseNumber(aString): number

Parameters

Name
Type

aString

string

Returns

number


parseSquareMMValueFromUnitString

parseSquareMMValueFromUnitString(aString, aUnit): number

Parameters

Name
Type

aString

string

aUnit

Returns

number


showExactValues

showExactValues(shouldeI): void

Parameters

Name
Type

shouldeI

boolean

Returns

void

Last updated