[WIP] WIP Try splitting off jdk9 sub-project.#425
Conversation
be3aa23 to
a86300f
Compare
|
My understanding for how to split this project into a JDK8 and JDK9 was to create a core module (which is most of what testfx-core is) that has an interface that can properly handle the internal issues (e.g. However, I'm not sure whether that's possible and thus whether it requires things to be done like how you've done here. |
|
Yes, I definitely want to consider other approaches. Just wanted to play around with this approach - will hopefully have time to experiment with others. This will stay [WIP] until we come to a consensus and make the most logical decision. |
|
Sounds good! |
|
Here's my idea: public interface JavaVersionAdapter {
public boolean isVisible(Node node);
public int convertKeyCodeToID(KeyCode keycode);
public Iterable<Window> getWindows();
public static JavaVersionAdapter getAdapter() {
return new JavaVersionAdapterImpl();
}
}Then, in two separate subprojects, we can have the implementation for each version that uses the correct method names. |
|
Would you have time to open a PR? I'd like to compare the two, but I am heavily favoring your approach. |
|
I believe I could, but perhaps next week, not this one. There are some other things I wish to do on a personal project. On another hand, I don't think we should use an interface. When accounting for modulation, it creates a cyclic dependency. If we put the Also, I think that following my approach will make the IDE complain. It may detect that there are two classes with the same fully-qualified name and, depending on which java version one is using, it may complain that the opposite version's implementation is using non-existent API. When it's built with Gradle, that shouldn't be an issue. However, trying to use the IDE to run various things may slow development because the IDE may stop at the compilation phase if it detects the non-existent API. |
|
Closed in favor of #429 |
Just seeing what the CI says about this.