Class CanonicalUnit

com.yandex.runtime.i18n

java.lang.Object ⇽ CanonicalUnit

public class CanonicalUnit implements Serializable

All Implemented Interfaces:
Serializable

Represents a unit with the value and measurement separated.

Constructors

CanonicalUnit(@NonNull String unit, double value)
CanonicalUnit()

Use constructor with parameters in your code.

Methods

String getUnit()

The unit of measurement.

double getValue()

The numerical value.

void serialize( Archive archive)

Constructor Detail

CanonicalUnit

public CanonicalUnit (@NonNull String unit, double value)

CanonicalUnit

public CanonicalUnit ()

Use constructor with parameters in your code.

This one is for bindings only!

Method Detail

getUnit

public String getUnit ()

The unit of measurement.

getValue

public double getValue ()

The numerical value.

serialize

public void serialize (Archive archive)