Selected new features in Java 6,7,8
Java 6:
- Rhino Scripting Engine
- Built-in Oracle Derby database
- Compiler API
- JAXB 2.0
- XML Digital Signature
- Semaphores
Java 7:
- Diamond operator
- String in switch statement
- Multiple Exceptions in catch statement
- Underscores in number literals
Java 8:
- Lambda expressions
- Streams
- Functional interfaces
- Default methods
- Optional
- Java Time
- Nashorn
- Base64
- Annotations on types
- Repeating annotations
Java 9:
- Try with resources
- Java modules
- Private methods in interfaces
Java 10:
- var
Java 11:
- String: isBlank, lines
- Predicate.not()
- Noop garbage collector
Java 12-17:
- text blocks
- Instanceof pattern matching
- Records
- Sealed classes
Java 21:
- Virtual threads?
- Record patterns
- Pattern matching for switch?