Class CanonicalUnit
Package world.mappable.runtime.i18n
java.lang.Object
↳ world.mappable.runtime.i18n.CanonicalUnit
class CanonicalUnit implements Serializable
Represents a unit with the value and measurement separated.
Summary
Constructors
|
Signature and Description |
|
CanonicalUnit(@NonNull java.lang.String unit, |
|
CanonicalUnit() |
Methods
|
Type and modifiers |
Method and Description |
|
java.lang.String |
getUnit() |
|
double |
getValue() |
|
void |
serialize(world.mappable.runtime.bindings.Archive archive) |
Constuctors
CanonicalUnit
|
CanonicalUnit(@NonNull java.lang.String unit, |
CanonicalUnit
|
CanonicalUnit() |
Use constructor with parameters in your code.
This one is for bindings only!
Methods
getUnit
|
@NonNull |
The unit of measurement.
getValue
|
double getValue() |
The numerical value.
serialize
|
@Override |