Читать книгу OCP Oracle Certified Professional Java SE 17 Developer Study Guide - Jeanne Boyarsky - Страница 25
How This Book Is Organized
ОглавлениеThis book is divided into 15 chapters, plus supplementary online material: a glossary of important terms, 500+ flash cards, and three practice exams that simulate the real exam.
Unlike the exam objectives, we organize our chapters organically so that each chapter builds on the material of the previous chapters. We also want to make things easier to learn and remember. This means some chapters cover multiple objectives.
The chapters are organized as follows:
Chapter 1: Building Blocks describes the basics of Java, such as how to run a program. It covers variables such as primitives, object data types, and scoping variables. It also discusses garbage collection.
Chapter 2: Operators explains operations with variables. It also talks about casting and the precedence of operators.
Chapter 3: Making Decisions covers core logical constructs such as decision statements, pattern matching, and loops.
Chapter 4: Core APIs works with String, StringBuilder, arrays, and dates.
Chapter 5: Methods explains how to design and write methods. It also introduces access modifiers, which are used throughout the book.
Chapter 6: Class Design covers class structure, constructors, inheritance, and initialization. It also teaches you how to create abstract classes and overload methods.
Chapter 7: Beyond Classes introduces many top-level types (other than classes), including interfaces, enums, sealed classes, records, and nested classes. It also covers polymorphism.
Chapter 8: Lambdas and Functional Interfaces shows how to use lambdas, method references, and built-in functional interfaces.
Chapter 9: Collections and Generics demonstrates method references, generics with wildcards, and Collections. The Collections portion covers many common interfaces, classes, and methods that are useful for the exam and in everyday software development.
Chapter 10: Streams explains stream pipelines in detail. It also covers the Optional class. If you want to become skilled at creating streams, read this chapter more than once!
Chapter 11: Exceptions and Localization demonstrates the different types of exception classes and how to apply them to build more resilient programs. It concludes with localization and formatting, which allow your program to gracefully support multiple countries or languages.
Chapter 12: Modules details the benefits of the new module feature. It shows how to compile and run module programs from the command line. Additionally, it describes services and how to migrate an application to a modular infrastructure.
Chapter 13: Concurrency introduces the concept of thread life cycle and thread-safety. It teaches you how to build multithreaded programs using the Concurrency API and parallel streams.
Chapter 14: I/O introduces you to managing files and directories using the I/O and NIO.2 APIs. It covers a number of I/O stream classes, teaches you how to serialize data, and shows how to interact with a user. Additionally, it includes techniques for using streams to traverse and search the file system.
Chapter 15: JDBC provides the basics of working with databases in Java, including working with stored procedures and transactions.
At the end of each chapter, you'll find a few elements you can use to prepare for the exam:
Summary This section reviews the most important topics that were covered in the chapter and serves as a good review.
Exam Essentials This section summarizes highlights that were covered in the chapter. You should be able to convey the information described.
Review Questions Each chapter concludes with at least 20 review questions. You should answer these questions and check your answers against the ones provided in the Appendix. If you can't answer at least 80 percent of these questions correctly, go back and review the chapter, or at least those sections that seem to be giving you difficulty.
The review questions, assessment tests, practice exams, and other code samples included in this book are not derived from the real exam questions, so don't memorize them! Learning the underlying topic not only helps you pass the exam but also makes you a higher-quality programmer in the workplace—the ultimate goal of a certification.
To get the most out of this book, you should read each chapter from start to finish before going to the chapter-end elements. They are most useful for checking and reinforcing your understanding. Even if you're already familiar with a topic, you should skim the chapter. There are a number of subtleties to Java that you could easily not encounter even when working with Java for years. For instance, the following does compile:
var $num = (Integer)null;
Even an experienced Java developer might be taken aback by this one. The exam requires you to know these kinds of subtleties.