Chapter 4. Generics and collections
Exam objectives covered in this chapter |
What you need to know |
---|---|
[4.1] Create a generic class | How to define generic classes, interfaces, and methods with single and multiple type parameters How to define generic methods with a generic or regular class |
[4.2] Use the diamond for type inference | How to drop the type from the angle brackets to instantiate generic classes How to use wildcards to create and instantiate generic classes |
[4.3] Analyze the interoperability of collections that use raw types and generic types | What happens when you lose type safety by using variables of raw types and objects of generic types How to determine and differentiate scenarios that would generate compilation errors ... |
Get OCP Java SE 7 Programmer II Certification Guide: Prepare for the 1ZO-804 exam now with O’Reilly online learning.
O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.