Java and JavaScript have as much in common as rocks and cheese. They
have similar names, and the name JavaScript was chosen to coat-tail on
the popularity of Java at the time that JavaScript was invented. But
never fear, you do not need anything in Java to be able to use
JavaScript. I doubt that Apple would remove this unless there were new
and onerous licensing terms coming from Oracle (Java’s new robot
overlords).
Java is also at the heart of WebObjects (that crazy little Web
framework that Apple uses to serve the Apple Store and every other
point of contact they have with the public) so I doubt very much that
they would take it away without a lot of kicking, screaming, and
replacement technologies.