Job Ready Java

Book description

Prepare yourself to take on new and exciting Java programming challenges with this one-stop resource 

Job Ready Java delivers a comprehensive and foundational approach to Java that is immediately applicable to real-world environments. Based on the highly regarded and effective Software Guild Java Bootcamp: Object Oriented Programming course, this book teaches you the basic and advanced Java concepts you will need at any entry-level Java position. 

With the “Pulling It Together” sections, you’ll combine and integrate the concepts and lessons taught by the book, while also benefiting from: 

  • A thorough introduction to getting set up with Java, including how to write, compile, and run Java programs with or without a Java IDE 
  • Practical discussions of the basics of the Java language, including syntax, program flow, and code organization 
  • A walk through the fundamentals of Object-Oriented Programming including Classes, Objects, Interfaces, and Inheritance, and how to leverage OOP in Java to create elegant code.  
  • Explorations of intermediate and advanced Java concepts, including Maven , unit testing, Lambdas, Streams, and the Spring Framework  

Perfect for Java novices seeking to make a career transition, Job Ready Java will also earn a place in the libraries of Java developers wanting to brush up on the fundamentals of their craft with an accessible and up-to-date resource. 

Table of contents

  1. Cover
  2. Title Page
  3. Introduction
    1. WHAT DOES THIS BOOK COVER?
    2. READER SUPPORT FOR THIS BOOK
  4. PART I: Getting Set Up
    1. Lesson 1: Installing Java
      1. THE JAVA UNIVERSE
      2. INSTALLING OpenJDK
      3. CREATING YOUR FIRST JAVA PROGRAM
      4. USING THE COMPILER AND JAVA VIRTUAL MACHINE
      5. SUMMARY
    2. Lesson 2: Installing a Development Environment: NetBeans
      1. GETTING STARTED
      2. UNDERSTANDING THE VALUE OF AN IDE
      3. INSTALLING NETBEANS
      4. RUNNING NETBEANS
      5. SUMMARY
    3. Lesson 3: Using an Integrated Development Environment
      1. USING AN IDE
      2. USING THE DEBUGGING TOOLS
      3. UNDERSTANDING SOURCE CONTROL
      4. SUMMARY
  5. PART II: Basics of Object Oriented Programming
    1. Lesson 4: Using Program Statements and Variables
      1. APPROACH
      2. CONCEPTS
      3. LANGUAGE BUILDING BLOCKS
      4. SUMMARY
      5. EXERCISES
    2. Lesson 5: Collecting and Parsing Input from the User
      1. CONSOLE INPUT AND OUTPUT
      2. PARSING DATA
      3. DEALING WITH BAD NUMBERS: NumberFormatException
      4. SCANNER PROBLEMS
      5. SUMMARY
      6. EXERCISES
    3. Lesson 6: Pulling It All Together: Building a Useful Program
      1. PLANNING THE PROGRAM
      2. CREATING THE CODE
      3. RUNNING THE PROGRAM
      4. SUMMARY
      5. EXERCISES
    4. Lesson 7: Controlling Program Flow
      1. WHAT CAN OUR CODE DO?
      2. DECISIONS AND BOOLEAN EXPRESSIONS
      3. TERNARY OR CONDITIONAL OPERATOR
      4. SWITCH STATEMENT
      5. COMPARING FOR EQUAL STRINGS
      6. SUMMARY
      7. EXERCISES
    5. Lesson 8: Looping Program Flow
      1. LOOPS
      2. USING WHILE LOOPS
      3. USING DO-WHILE LOOPS
      4. USING FOR LOOPS
      5. SUMMARY
      6. EXERCISES
    6. Lesson 9: Understanding Flowcharts and Algorithms
      1. FLOWCHART BASICS
      2. FLOWCHARTING
      3. FLOWCHART EXAMPLE
      4. SUMMARY
      5. EXERCISES
    7. Lesson 10: Adding Randomness to Your Programs
      1. INITIALIZING THE RANDOM OBJECT
      2. GENERATING RANDOM INTEGERS
      3. GENERATING RANDOM DOUBLES
      4. REVISITING THE NUMBER GUESSING GAME
      5. OTHER RANDOM OPTIONS
      6. SUMMARY
      7. EXERCISES
    8. Lesson 11: Debugging
      1. CREATING A FILE TO DEBUG
      2. SETTING BREAKPOINTS
      3. SUMMARY
      4. EXERCISES
    9. Lesson 12: Adding Methods
      1. WHY METHODS?
      2. DEFINING METHODS
      3. METHOD FORMS
      4. PULLING IT ALL TOGETHER
      5. SCOPE
      6. DEBUGGING AND STEP INTO
      7. SUMMARY
      8. EXERCISES
    10. Lesson 13: Organizing with Arrays
      1. WHAT IS AN ARRAY?
      2. DECLARING ARRAYS
      3. INITIALIZING ARRAYS
      4. ACCESSING ARRAY ELEMENTS
      5. ITERATING THROUGH ARRAYS
      6. CHANGING THE SIZE OF AN ARRAY
      7. DEALING WITH ERRORS
      8. SUMMARY
      9. EXERCISES
  6. PART III: Fundamentals of Classes and Objects
    1. Lesson 14: Object-Oriented Concepts
      1. ABSTRACTION
      2. OBJECT ORIENTATION
      3. TYPES
      4. PUBLIC INTERFACE/PRIVATE IMPLEMENTATION
      5. ENCAPSULATION AND DATA HIDING
      6. SINGLE RESPONSIBILITY PRINCIPLE AND COHESION
      7. DELEGATION
      8. SUMMARY
    2. Lesson 15: Creating Classes and Types
      1. CREATING NEW TYPES
      2. CLASSES VS. OBJECTS
      3. PROPERTIES, ACCESSORS, AND MUTATORS
      4. DOT OPERATOR
      5. this KEYWORD
      6. METHODS/BEHAVIORS
      7. CONSTRUCTORS
      8. OBJECT INSTANTIATION AND METHOD INVOCATION
      9. static KEYWORD
      10. PULLING IT ALL TOGETHER
      11. SUMMARY
      12. EXERCISES
    3. Lesson 16: Managing Storage and Memory
      1. PROGRAMS AND MEMORY
      2. GARBAGE COLLECTION
      3. REFERENCE AND NULL VALUES
      4. SUMMARY
    4. Lesson 17: Exploring Interfaces, Composition, and Inheritance
      1. HOW DO THESE TOOLS HELP?
      2. INTERFACES
      3. COMPOSITION AND INHERITANCE
      4. USING INTERFACES, COMPOSITION, AND INHERITANCE
      5. SUMMARY
    5. Lesson 18: Diving into Interfaces
      1. WHAT IS AN INTERFACE?
      2. DECLARING AN INTERFACE
      3. IMPLEMENTING AN INTERFACE
      4. INTERFACE RESTRICTIONS
      5. IMPLEMENTING MULTIPLE INTERFACES
      6. EXTENDING AN INTERFACE
      7. INTERFACES AND POLYMORPHISM
      8. SUMMARY
    6. Lesson 19: Diving into Composition
      1. WHAT IS COMPOSITION?
      2. SUMMARY
      3. EXERCISES
    7. Lesson 20: Diving into Inheritance
      1. EVERYTHING EXTENDS OBJECT
      2. TERMINOLOGY
      3. ACCESS CONTROL
      4. INHERITANCE
      5. CODE REUSE THROUGH INHERITANCE
      6. METHOD OVERLOADING
      7. METHOD OVERRIDING
      8. CONSTRUCTORS
      9. POLYMORPHISM
      10. CALLING METHODS POLYMORPHICALLY
      11. ABSTRACT BASE CLASSES
      12. SUMMARY
      13. EXERCISES
    8. Lesson 21: Understanding Collections
      1. COLLECTIONS IN JAVA
      2. JAVADOC
      3. COLLECTIONS FRAMEWORK STRUCTURE
      4. INTERFACE VS. IMPLEMENTATION
      5. ITERATOR
      6. COMMONLY USED INTERFACES IN THE COLLECTIONS FRAMEWORK
      7. SUMMARY
    9. Lesson 22: Introduction to Lists
      1. LIST
      2. TYPES OF LISTS
      3. UNDERSTANDING GENERICS
      4. USING LISTS
      5. ENHANCED APPROACHES TO ACCESS LIST ITEMS
      6. SUMMARY
      7. EXERCISES
    10. Lesson 23: Exploring Maps
      1. MAP INTERFACE
      2. HashMap
      3. CREATING AND ADDING ENTRIES TO A MAP
      4. MANIPULATING WITH ENTRIES IN A MAP
      5. GETTING KEYS AND LISTING MAPPED VALUES IN A MAP
      6. SUMMARY
      7. EXERCISES
    11. Lesson 24: Using Simple File Input and Output
      1. DATA STORAGE AND REPRESENTATION
      2. FILE FORMAT, MARSHALING, AND UNMARSHALING
      3. SIMPLE FILE I/O
      4. SUMMARY
      5. EXERCISES
    12. Lesson 25: Applying Application Design
      1. CRUD APPLICATIONS
      2. THE MODEL-VIEW-CONTROLLER PATTERN
      3. PACKAGES
      4. SOFTWARE DEVELOPMENT LIFECYCLEOVERVIEW
      5. AGILE DEVELOPMENT
      6. SUMMARY
    13. Lesson 26: Handling Exceptions
      1. EXCEPTION HANDLING
      2. CATCH OR SPECIFY REQUIREMENT
      3. EXCEPTION TYPES
      4. HANDLING (CATCHING) EXCEPTIONS
      5. SPECIFYING AND THROWING EXCEPTIONS
      6. EXCEPTION TRANSLATION AND ENCAPSULATION
      7. SUMMARY
      8. EXERCISES
      9. NOTE
    14. Lesson 27: Pulling It All Together: Building the Class Roster App
      1. APPLICATION REQUIREMENTS AND USE CASES
      2. UNDERSTANDING THE APPLICATION STRUCTURE
      3. SETTING UP THE CLASS ROSTER APPLICATION SHELL
      4. CREATING THE MENU SYSTEM
      5. ADDING A STUDENT USE CASE
      6. VIEWING ALL STUDENTS USE CASE
      7. GETTING A STUDENT USE CASE
      8. REMOVING A STUDENT USE CASE
      9. HANDLING UNKNOWN COMMAND AND EXITING
      10. WORKING WITH DEPENDENCY INJECTION
      11. HANDLING APPLICATION EXCEPTIONS
      12. ADDING FILE PERSISTENCE
      13. SUMMARY
      14. EXERCISES
  7. PART IV: Intermediate Java
    1. Lesson 28: Exploring the Service Layer
      1. THE ROLE OF THE SERVICE LAYER
      2. SERVICE LAYER EXCEPTIONS
      3. SERVICE LAYER API DESIGN
      4. NEW BUSINESS RULES
      5. CREATE A STUDENT
      6. SERVICE LAYER METHODS FOR GETTING STUDENTS
      7. SUMMARY
    2. Lesson 29: Pulling It All Together: Coding the Class Roster Service Layer
      1. CREATE A SERVICE LAYER INTERFACE
      2. CREATE NEW EXCEPTIONS
      3. CREATE THE SERVICE LAYER IMPLEMENTATION
      4. MODIFY THE CONTROLLER
      5. MODIFY THE APP
      6. ADD THE AUDIT LOG FEATURE
      7. SUMMARY
    3. Lesson 30: Doing Unit Testing
      1. UNIT TESTING
      2. TYPES OF UNIT TESTING
      3. JUnit
      4. GIVEN/WHEN/THEN
      5. STATELESS UNIT TESTING
      6. IMPLEMENTING UNIT TESTS
      7. SUMMARY
    4. Lesson 31: Testing Stateful Code
      1. UNIT TESTING STATEFUL CODE
      2. SEPARATING PRODUCTION AND TEST DATA
      3. CLASS ROSTER DAO TEST DESIGN
      4. UNIT TESTING THE SERVICE LAYER
      5. SUMMARY
      6. EXERCISES
    5. Lesson 32: Including Magic Numbers and Enums
      1. MAGIC NUMBERS
      2. ENUMS
      3. ENUM MEMBERS
      4. SUMMARY
      5. EXERCISES
    6. Lesson 33: Manipulating Dates and Times
      1. ISO CALENDAR
      2. HUMAN TIME AND MACHINE TIME
      3. LOCAL AND ZONED CLASSES
      4. PERIODS AND DURATION
      5. WORKING WITH LocalDate OBJECTS
      6. GETTING THE TIME WITH LocalDateTime
      7. WORKING WITH DATE CALCULATIONS
      8. WORKING WITH LEGACY DATES
      9. SUMMARY
      10. EXERCISES
    7. Lesson 34: Using the BigDecimal Class
      1. EXPLORING BIGDECIMAL
      2. WORKING WITH BIGDECIMAL
      3. DOING CALCULATIONS WITH BigDecimals
      4. SUMMARY
      5. EXERCISES
    8. Lesson 35: Working with Lambdas and Streams
      1. USING AGGREGATE OPERATIONS
      2. UNDERSTANDING PIPELINES AND STREAMS
      3. STREAMS VS. ITERATION
      4. EXPLORING LAMBDAS
      5. WORKING WITH STREAM AND LAMBDA SYNTAX
      6. SUMMARY
      7. EXERCISES
  8. PART V: Advanced Java
    1. Lesson 36: Working with the Spring Framework
      1. DEPENDENCY INJECTION AND PROGRAMMING TO INTERFACES
      2. WHY SPRING?
      3. UNDERSTANDING THE SPRING APPROACH
      4. PULLING IT ALL TOGETHER: SPRING DI IN ACTION
      5. SUMMARY
    2. Lesson 37: Introducing Maven
      1. WHAT IS MAVEN?
      2. PROJECT OBJECT MODEL
      3. DEPENDENCY MANAGEMENT
      4. MAVEN LIFECYCLE
      5. SUMMARY
    3. Lesson 38: Pulling It All Together: Building the Class Roster with Spring
      1. INCLUDE THE SPRING LIBRARIES
      2. ADD SPRING CONFIGURATION FILES
      3. CONVERT THE APP CLASS TO USE SPRING
      4. CONVERT THE UNIT TESTS TO USE SPRING
      5. EXCEPTION CONDITIONS
      6. SUMMARY
      7. EXERCISES
  9. PART VI: Appendices
    1. Appendix A: Code Checklist
      1. FUNCTIONALITY
      2. STYLE
    2. Appendix B: Java Concepts Study List
      1. VARIABLES
      2. METHODS
      3. ARRAYS
      4. MAKING DECISIONS
      5. LOOPS
      6. JAVA/JVM
      7. OBJECTS
      8. INTERFACES
      9. INHERITANCE
      10. N-TIER DESIGN
      11. COLLECTIONS
      12. EXCEPTIONS
      13. LAMBDAS/STREAMS
      14. SPRING CORE
    3. Appendix C: Agile Approach Checklist for Console CRUD Applications
      1. ASSUMPTIONS
      2. REQUIREMENT STEPS
      3. DESIGN STEPS
      4. CONSTRUCTION STEPS
  10. Index
  11. Copyright
  12. About the Authors
  13. About the Technical Writer
  14. About the Technical Editors
  15. Acknowledgments
  16. End User License Agreement

Product information

  • Title: Job Ready Java
  • Author(s): Haythem Balti, Alan Galloway
  • Release date: March 2021
  • Publisher(s): Wiley
  • ISBN: 9781119775645