DerivedUnit

DerivedUnits are composed of a UnitExpression and a scale factor. The UnitExpression encapsulates the combination of other Units that composes this DerivedUnit, and the scale represents the scale factor.

Extends

Methods

dimensions() → {Dimensions}

Returns the Dimensions of the expression that defines this DerivedUnit.
Returns:
Dimensions
Overrides:
See:

expression() → {UnitExpression}

The UnitExpression that defines the DerivedUnit. For instance, the Joule is defined the Newton-meter per second squared.
Returns:
UnitExpression
Overrides:
Deprecated:
  • Yes
To Do:
  • remove this method from Unit

isBaseUnit() → {boolean}

Always return true.
Returns:
boolean
Overrides:

name() → {string}

The name of the Unit.
Returns:
string
Inherited From:

scale() → {number}

The scale of the Unit.
Returns:
number
Inherited From:

symbol() → {string}

The symbol of the Unit, used in toString() representations. For instance, the symbol for "meter" is "m".
Returns:
string
Inherited From:

toString() → {string}

Returns a string representation of this DerivedUnit, composed of its scale and the string representation of its expression().
Returns:
string
Overrides: