To run each example use: java --enable-preview --source 17 <FileName.java>
- 306 - Restore Always-Strict Floating-Point Semantics
- 356 - Enhanced Pseudo-Random Number Generators
- 382 - New macOS Rendering Pipeline
- 391 - macOS/AArch64 Port
- 398 - Deprecate the Applet API for Removal
- 403 - Strongly Encapsulate JDK Internals
- 406 - Pattern Matching for switch (Preview)
- 407 - Remove RMI Activation
- 409 - Sealed Classes
- 410 - Remove the Experimental AOT and JIT Compiler
- 411 - Deprecate the Security Manager for Removal
- 412 - Foreign Function & Memory API (Incubator)
- 414 - Vector API (Second Incubator)
- 415 - Context-Specific Deserialization Filters
- Sealed Classes (standard)
- promotion to standard without change
- Pattern Matching for
switch
(preview)- improved switch to support pattern matching for types (like
instanceof
) - support for
null
case - support for guards where we can use a boolean expression like
case String s && s.length > 10:
- improved switch to support pattern matching for types (like
- Pseudo-Random Number Generators (PRNG)
- created new classes to generate number
- two groups of PRNG algorithms:
- splittable (LXM family):
- allow spawn a new generator using existing one that produce statistically independent results
- implemented by LXM algorithms (like
L32X64MixRandom
,L32X64StarStarRandom
,L64X128MixRandom
,L64X128StarStarRandom
and others with different bitsizes)
- jumpable:
- allow the client to jump ahead a moderate number of draws
- implemented by
Xoroshiro128PlusPlus
andXoshiro256PlusPlus
- splittable (LXM family):
- we can use
RandomGeneratorFactory
to create the generators passing the algorithm name (likeL32X64MixRandom
orXoroshiro128PlusPlus
) - new types:
SplittableGenerator
JumpableGenerator
LeapableGenerator
: allow the client to jump head a large number of draws;ArbitrarilyJumpableGenerator
: extends LeapableRandomGenerator and allow to jump arbitrary numbero of draws.
- more detailed info in the docs
- Strongly encapsulate JDK internals
- make illegal access internal API flag obsolate (was
--illegal-access=deny
in Java 16) - only
sun.misc
andsun.reflect
will be allowed to be access throughjdk.unsupported
module
- make illegal access internal API flag obsolate (was
- Disable SHA-1 XML Signatures
- can be enable with
jdk.xml.dsig.secureValidationPolicy
- can be enable with