Java 18 Features
โ Wow, ๐๐ฎ๐๐ฎ ๐ญ๐ด has some ๐ฎ๐๐ฒ๐๐ผ๐บ๐ฒ ๐ณ๐ฒ๐ฎ๐๐๐ฟ๐ฒ๐ ๐, listed below are the important things.๐ฅ
โ Simple Web Server โ
Nowadays most modern languages have inbuilt web servers. Java 18 comes with that feature. We can start providing a web server with the jwebserver command. It starts the server on localhost:8000 and provides a file browser for the current directory.
โ UTF-8 By Default
In Java 18, the default charset is now UTF-8. Previously, Java charset worked based on the host operating system and locale.
โ Code Snippets
Now, we can implement and integrate multiline code snippets into Java. It helps a lot for the predefined example or getting started code.
โ Internet-Address Resolution SPI
Helps to resolve Internet address items and can use this to resolve hostnames from IP addresses or hostnames and ports from an HTTP URI
โ Pattern Matching for Switch
It was first introduced in Java 17. Pattern Matching for switch enables and transfers control to one of the several statements or expressions, depending on the value of its selector expression.
โ Vector API
A vector API makes simply an array of numbers that can be manipulated as a single entity and helps to perform numeric computations, especially complex ones that involve many different values.
Note : ๐ Some of the features are available in preview mode.
Tags:
#java #java18 #features #mode