Why can't I import sun packages?

I downloaded java 9 from https://jdk9.java.net and installed it on my Windows 10 machine.

Java 9 has jshell, which I can use to evaluate and learn Java programming.
Some examples import sun packages, for example sun.audio.*, etc. But in jshell every time I try to import any sun package, it says that the sun package does not exist.

Some applications do not work with java 9. Perhaps there are incompatibilities?

+4
source share
1 answer

, , Java 9 , , . , , API . Sun.

Java 9 :

  • JDK JRE
  • (, sun.misc)

http://paulbakker.io/java/java-9-modularity/

, .

, JShell .

" ", " " " ", . https://bugs.openjdk.java.net/browse/JDK-8166649

-, , . 4 .

+8

Source: https://habr.com/ru/post/1659230/


All Articles