internal API usage: sun.awt.CausedFocusEvent

Mandy Chung mandy.chung at oracle.com
Wed May 13 18:08:12 UTC 2015


> On May 13, 2015, at 10:51 AM, Alan Snyder <javalists at cbfiddle.com> wrote:
> 
> I will do that, but a larger question remains:
> 
> Are any of the AWT classes currently reported by jdeps as “JDK internal API” going to be accessible in JDK 9?
> 

No - there is no known RFE that I know of may provide a replacement for sun.awt.* classes except  /JDK-8067470 (see [1] for client related internal APIs). The best is to bring up the discussion to awt-dev as Alan suggests.

https://wiki.openjdk.java.net/display/JDK8/Java+Dependency+Analysis+Tool <https://wiki.openjdk.java.net/display/JDK8/Java+Dependency+Analysis+Tool> tracks what internal APIs that have known replacement or will have supported APIs in a future release.   This is a living document that will be updated if there is any new RFE to provide a replacement to existing internal APIs.



> I ask because of this comment by Stuart Marks:
> 
> Unfortunately, com.sun is a mixture of internal and publicly supported ("exported") APIs. An annotation @jdk.Exported distinguishes the latter from internal APIs.
> 
> Who decides which APIs get this annotation? Are these annotations in place now?

@jdk.Exported was added in JDK 8.  

I suggest you look at the exported APIs listed under:
   http://hg.openjdk.java.net/jdk9/dev/file/tip/modules.xml

This is an interim solution to declare what APIs are exported until the module system moves further along and defines a proper module definition.

Mandy

[1] https://bugs.openjdk.java.net/browse/JDK-8065418



More information about the jigsaw-dev mailing list