Update to Java 17 and Maven libraries #1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This example has been updated to Java 17 using the following approach:
To use JavaFX from Maven Central, the following was added to the target platform:
org.openjfx
javafx-controls
22-ea+16
jar
org.openjfx
javafx-fxml
22-ea+16
jar
Unfortunately the JavaFX SWT libraries is not available via Maven artifacts, you have to extract it from the the zip file. This is platform specific:
Windows: Contained in JAR file of Javafx controls
Linux: Contained in the JAR file of Javafx graphics jar The JAR files in which the JAR file is included is located in .m2/repository/org/openjfx/compoent/version for example: .m2/repository/org/openjfx/javafx-graphics/21
Unfortunately the target platform downloads the platform specific artifacts from Maven using the same bundle name. PDE resolves in some cases (this seems to be platform and library version specific) to the bundle which does not contain the implementation. Therefore, you might have to copy the JAR files into your project and add them to the MANIFEST.MF file.
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Inverter
Bundle-SymbolicName: org.fipro.eclipse.tutorial.inverter Bundle-Version: 1.0.0.qualifier
Bundle-RequiredExecutionEnvironment: JavaSE-17
Require-Bundle: org.eclipse.swt;bundle-version="3.103.1",
org.eclipse.jface;bundle-version="3.10.1",
javax.annotation;bundle-version="1.2.0",
javax.inject;bundle-version="1.0.0"
Automatic-Module-Name: org.fipro.eclipse.tutorial.inverter Bundle-ClassPath: .,
lib/javafx-base-17.0.9.jar,
lib/javafx-base-17.0.9-linux.jar,
lib/javafx-fxml-17.0.9.jar,
lib/javafx-fxml-17.0.9-linux.jar,
lib/javafx-graphics-17.0.9.jar,
lib/javafx-graphics-17.0.9-linux.jar,
lib/javafx-swt.jar,
lib/javafx-controls-17.0.9.jar,
lib/javafx-controls-17.0.9-linux.jar