Motivation: |
JSR-108 has been replaced |
|
|---|---|---|
Contact: |
||
Tracker: |
||
Tagline: |
|
We make use of a Units library for keeping track of the difference between meters and feet etc... We have been making use of an offical JSR-108 jar.
There were two replacements available once we upgraded to Java 5
The JSR-275 jar is now officially available:
The work has been completed.
Voting results:
This section is used to make sure your proposal is complete (did you remember documentation?) and has enough paid or volunteer time lined up to be a success.
|
no progress |
|
done |
|
impeded |
|
lack mandate/funds/time |
|
volunteer needed |
|---|
Change the import; use Quantity package.
There is one additional change related to Converter. I will document it in this page when I will make this change in GeoTools. Since I don't think that many use Converter directly, it will probably impact few peoples.
import javax.units.SI; import javax.units.NonSI; import javax.units.Unit; import javax.units.UnitFormat; import javax.units.Converter; import javax.units.ConversionException; Unit PPM = Unit.ONE.multiply(1E-6); UnitFormat.label(PPM, "ppm"); |
import javax.measure.unit.SI; import javax.measure.unit.NonSI; import javax.measure.unit.Unit; import javax.measure.unit.UnitFormat; import javax.measure.converter.UnitConverter; import javax.measure.converter.ConversionException; Unit PPM = Unit.ONE.times(1E-6); UnitFormat.getInstance().label(PPM, "ppm"); |
Note the class name change from Converter to UnitConverter.
We will need to change the following: