Comments (5)
No problem for RI, demo or documentation. For the API itself, even if on my side I'm on Java 11, there is a lot of software that are still on Java 8. So I guess that the API needs to still Java 8 compatible for a few more years. But only the API, the rest can move on.
from unit-api.
I created this ticket for a few minor spec improvements, primarily how to use the record from Java 16 onward. @desruisseaux, @dautelle, @otaviojava or others, would you be able to check it out briefly?
from unit-api.
What records would be used for? Would it be adding examples in the documentation about how JSR 385 could be implemented with records, or is this issue about changes in JSR 385 API?
from unit-api.
Yes, for now examples like uom-console-demos-java17 most of which the spec example code is based on demonstrate how to use records.
In addition, while that was always a PoC applying what I demonstrated in uom-demos to a new uom-impl-enum version also sounds feasible. While enums are a good match for limited scope units with a less complex hierarchy, quantities or measurements (where "measurement record" is a rather common term) work well with records under similar conditions.
I also consider to replace the default Measurement
implementation and the QuantityRange
in the RI with record-based versions after upgrading the Multi-Release-JAR of Indriya to a Java 17 or 16 version. Plus maybe one for Java 21 once that is Final next month. And squash the Java 12 and 14 ones into the 16 or 17 one. Until a possible MR3 I guess Java 8 is still supported, but the next Multi-Release probably will be 11 and 17 because those are the other LTS versions, as well as 21 (because the final Switch Pattern Matching offers nice redesign of some classes ;-)
from unit-api.
For MR2 the RI should also stick to Java 8. It may also start using Java 11 in a future version, but only a few minor 2.x digits down the road. As the RI should be closer to the API than other implementations, And Multi-Release-JARs work fine for Indriya.
So until maybe true value types or a final Vector API became relevant for the API (in which case, the API would have to move drastically to Java 23, 25 or similar) I see no need to support the latest Java types there yet.
from unit-api.
Related Issues (20)
- Improve code coverage of ServiceProvider HOT 3
- Fix problem with maven-javadoc-plugin
- MR 1 Spec Review
- Could Quantity use a symbol, too? HOT 1
- Upgrade JDK to Java 11 or higher
- Replace Bintray/JCenter in API build settings
- Enable discovery of prefix classes via SPI HOT 1
- Improve the JavaDoc of UnitFormat
- Remove unnecessary OSGI imports
- Convert Quantity to most fitting Prefix HOT 7
- improve interoperability of Quantity with Hibernate JPA HOT 7
- Should not cache the ServiceProvider implementation HOT 8
- Incorporate the new SI Prefixes
- Upgrade CI JDK to Java 17 or higher
- Update module-info
- Replace tabulations by 4 spaces HOT 2
- Should we deprecate MetricPrefix.DEKA()? HOT 4
- enum missing in javax.measure.MetricPrefix HOT 2
- Units can have non-integer Dimension HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from unit-api.