New APIs in Java 21
Comparing Java 21 (21.0.5+11-LTS-tem) with Java 18 (18.0.2.1+1-tem).
Element | Modification |
---|---|
java.base |
|
java.io |
|
BufferedInputStream |
|
|
|
InvalidClassException |
|
InvalidObjectException |
|
|
|
ObjectStreamException |
|
PushbackInputStream |
|
SequenceInputStream |
|
java.lang.constant |
|
ConstantDescs |
|
ClassDesc |
|
MethodHandleDesc |
|
MethodTypeDesc |
|
|
|
java.lang.invoke |
|
|
|
ClassSpecializer.Factory |
|
ClassSpecializer.SpeciesData |
|
|
|
MethodHandles |
|
StringConcatFactory |
|
|
|
|
|
java.lang.module |
|
ModuleDescriptor.Exports |
|
ModuleDescriptor.Opens |
|
ModuleDescriptor.Requires |
|
ModuleDescriptor |
|
java.lang.ref |
|
ReferenceQueue |
|
|
|
|
|
java.lang.reflect |
|
Executable |
|
|
|
Field |
|
Parameter |
|
Member |
|
java.lang.runtime |
|
|
|
java.lang |
|
Character.UnicodeBlock |
|
Character |
|
Class |
|
Compiler |
|
Double |
|
FdLibm.Cbrt |
|
FdLibm.Hypot |
|
FdLibm.Pow |
|
Float |
|
Integer |
|
Long |
|
Math |
|
ModuleLayer.Controller |
|
Module |
|
StrictMath |
|
|
|
|
|
String |
|
|
|
ThreadGroup |
|
allowThreadSuspension(boolean) |
|
Thread |
|
|
|
Character.UnicodeScript |
|
java.math |
|
BigDecimal |
|
BigInteger |
|
java.net |
|
|
|
SocketException |
|
URL |
|
|
|
|
|
|
|
|
|
|
|
|
|
java.nio.channels |
|
FileChannel |
|
java.nio.file.spi |
|
FileSystemProvider |
|
java.nio |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
java.security.interfaces |
|
DSAKeyPairGenerator |
|
|
|
|
|
java.security.spec |
|
PSSParameterSpec |
|
|
|
|
|
java.security |
|
InvalidParameterException |
|
java.text |
|
DecimalFormatSymbols |
|
java.time.chrono |
|
IsoChronology |
|
JapaneseChronology |
|
MinguoChronology |
|
ThaiBuddhistChronology |
|
Chronology |
|
java.time.format |
|
DateTimeFormatterBuilder |
|
DateTimeFormatter |
|
java.time |
|
|
|
ZoneOffset |
|
java.util.concurrent |
|
CompletableFuture |
|
|
|
ConcurrentSkipListMap |
|
ConcurrentSkipListSet |
|
CopyOnWriteArrayList |
|
DelayQueue |
|
Executors |
|
ForkJoinPool |
|
ForkJoinTask |
|
ForkJoinWorkerThread |
|
FutureTask |
|
|
|
|
|
Future |
|
java.util.regex |
|
Matcher |
|
Pattern |
|
MatchResult |
|
java.util.spi |
|
ToolProvider |
|
java.util.zip |
|
ZipInputStream |
|
java.util |
|
ArrayList |
|
|
|
Collections |
|
|
|
HashMap |
|
HashSet |
|
IdentityHashMap |
|
|
|
|
|
|
|
LinkedList |
|
Locale |
|
|
|
|
|
|
|
Objects |
|
Random |
|
TreeMap |
|
TreeSet |
|
WeakHashMap |
|
|
|
|
|
NavigableMap |
|
NavigableSet |
|
|
|
|
|
javax.crypto.spec |
|
OAEPParameterSpec |
|
|
|
javax.crypto |
|
javax.net.ssl |
|
SSLHandshakeException |
|
SSLKeyException |
|
SSLParameters |
|
SSLPeerUnverifiedException |
|
SSLProtocolException |
|
SSLSessionContext |
|
|
|
|
|
java.compiler |
|
javax.lang.model.element |
|
ElementKind |
|
TypeElement |
|
VariableElement |
|
javax.lang.model.util |
|
Elements |
|
javax.lang.model |
|
SourceVersion |
|
java.desktop |
|
java.awt.color |
|
|
|
|
|
|
|
java.awt.desktop |
|
|
|
|
|
java.awt.dnd |
|
|
|
java.awt.event |
|
|
|
java.awt.geom |
|
CubicCurve2D.Double |
|
getBounds2D() |
|
CubicCurve2D.Float |
|
getBounds2D() |
|
CubicCurve2D |
|
|
|
QuadCurve2D.Double |
|
getBounds2D() |
|
QuadCurve2D.Float |
|
getBounds2D() |
|
QuadCurve2D |
|
java.awt |
|
|
|
|
|
|
|
|
|
|
|
javax.sound.midi |
|
|
|
javax.swing.plaf.basic |
|
BasicDirectoryModel |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
BasicToolBarUI |
|
|
|
javax.swing.plaf.synth |
|
SynthComboBoxUI |
|
SynthLookAndFeel |
|
|
|
SynthPasswordFieldUI |
|
javax.swing.text.html |
|
AccessibleHTML.HTMLAccessibleContext |
|
|
|
|
|
|
|
javax.swing.text |
|
DefaultEditorKit |
|
|
|
|
|
|
|
|
|
|
|
javax.swing |
|
|
|
|
|
|
|
|
|
java.management.rmi |
|
javax.management.remote.rmi |
|
RMIIIOPServerImpl |
|
java.management |
|
javax.management.loading |
|
|
|
|
|
|
|
|
|
javax.management.remote |
|
JMXConnector |
|
|
|
java.net.http |
|
java.net.http |
|
|
|
HttpClient.Builder |
|
java.xml.crypto |
|
javax.xml.crypto.dsig |
|
SignatureMethod |
|
This report is based on simple comparison of all public
and
protected
APIs of the java.*
and javax.*
packages of JDK builds 21.0.5+11-LTS-tem and
18.0.2.1+1-tem. It does not make statements about
compatibility.
For the latest Java versions the corresponding CSRs (Compatibility & Specification Review) are linked for a quick reference to find out about the reasoning of the change.