Factory Methods for Collections - JEP Café #6

This #JEPCafe discusses ’Convenience Factory Methods for Collections’ (JEP 269), released with JDK 9. Factory methods allow to create pre-filled collections and maps, that are immutable, that do not accept null values or keys, and that are Serializable. Let us quickly visit them, along with `()`, `()` and the new `()` methods. ⎯⎯⎯⎯⎯⎯ Chapters ⎯⎯⎯⎯⎯⎯ 0:00 Intro 1:04 Creating pre-filled collections 2:00 Introducing `()` 3:27 Creating immutable sets with `()` 4:15 Using `()` and `()` 6:20 Using `()` to wrap arrays 7:40 Copying a list with `()` 8:58 Using `()` 11:09 Wrapping up the patterns 12:17 Outro ⎯⎯⎯⎯⎯⎯ Resources ⎯⎯⎯⎯⎯⎯ ◦ ➱ ◦ How to use Preview Features ➱ ◦ JEP 269: Convenience Factory Methods for Collections ➱ ◦ JDK 17 ➱ https:/
Back to Top