Book description
Java—from first steps to first apps
Knowing Java is a must-have programming skill for any programmer. It’s used in a wide array of programming projects—from enterprise apps and mobile apps to big data, scientific, and financial uses. The language regularly ranks #1 in surveys of the most popular language based on number of developers, lines of code written, and real-world usage. It’s also the language of choice in AP Computer Science classes taught in the U.S.
This guide provides an easy-to-follow path from understanding the basics of writing Java code to applying those skills to real projects. Split into eight minibooks covering core aspects of Java, the book introduces the basics of the Java language and object-oriented programming before setting you on the path to building web apps and databases.
• Get up to speed on Java basics
• Explore object-oriented programming
• Learn about strings, arrays, and collections
• Find out about files and databases
Step-by-step instructions are provided to ensure that you don't get lost at any point along the way.
Table of contents
- Cover
- Introduction
- Book 1: Java Basics
-
Book 2: Programming Basics
- Chapter 1: Java Programming Basics
-
Chapter 2: Working with Variables and Data Types
- Declaring Variables
- Initializing Variables
- Using Final Variables (Constants)
- Working with Primitive Data Types
- Working with Strings
- Converting and Casting Numeric Data
- Thinking Inside the Box
- Understanding Scope
- Shadowing Variables
- Printing Data with System.out
- Getting Input with the Scanner Class
- Getting Input with the JOptionPane Class
- Using enum to Create Your Own Data Types
- Chapter 3: Working with Numbers and Expressions
- Chapter 4: Making Choices
- Chapter 5: Going Around in Circles (Or, Using Loops)
- Chapter 6: Pulling a Switcheroo
- Chapter 7: Adding Some Methods to Your Madness
- Chapter 8: Handling Exceptions
-
Book 3: Object-Oriented Programming
- Chapter 1: Understanding Object-Oriented Programming
- Chapter 2: Making Your Own Classes
- Chapter 3: Working with Statics
- Chapter 4: Using Subclasses and Inheritance
- Chapter 5: Using Abstract Classes and Interfaces
- Chapter 6: Using the Object and Class Classes
- Chapter 7: Using Inner Classes, Anonymous Classes, and Lambda Expressions
- Chapter 8: Working with Packages and the Java Module System
-
Book 4: Strings, Arrays, and Collections
- Chapter 1: Working with Strings
-
Chapter 2: Using Arrays
- Understanding Arrays
- Creating Arrays
- Initializing an Array
- Using for Loops with Arrays
- Solving Homework Problems with Arrays
- Using the Enhanced for Loop
- Using Arrays with Methods
- Using Varargs
- Using Two-Dimensional Arrays
- Working with a Fun but Complicated Example: A Chessboard
- Using the Arrays Class
- Chapter 3: Using the ArrayList Class
- Chapter 4: Using the LinkedList Class
- Chapter 5: Creating Generic Collection Classes
- Chapter 6: Using Bulk Data Operations with Collections
-
Book 5: Programming Techniques
- Chapter 1: Programming Threads
- Chapter 2: Using Regular Expressions
- Chapter 3: Using Recursion
-
Chapter 4: Working with Dates and Times
- Pondering How Time is Represented
- Picking the Right Date and Time Class for Your Application
- Using the now Method to Create a Date-Time Object
- Using the parse Method to Create a Date-Time Object
- Using the of Method to Create a Date-Time Object
- Looking Closer at the LocalDate Class
- Extracting Information About a Date
- Comparing Dates
- Calculating with Dates
- Formatting Dates
- Looking at a Fun Birthday Calculator
-
Chapter 5: IoT Programming with Raspberry Pi
- Introducing the Raspberry Pi
- Setting Up a Raspberry Pi
- Installing Java on a Raspberry Pi
- Installing the Pi4J Library
- Configuring the Geany Integrated Development Environment for Java Development
- Examining GPIO Ports
- Connecting an LED to a GPIO Port
- Building a Raspberry Pi LED Circuit
- Examining the Pi4J Library
- Importing GPIO Types
- Instantiating a GpioController
- Provisioning GPIO Pins
- Controlling the Pin State
- The Morse Code Program
- The Cylon Eyes Program
- Working with Input Pins
- Running the Button Switcher Program
- Finding a Better Way to Handle Input Events
-
Book 6: JavaFX
-
Chapter 1: Hello, JavaFX!
- Perusing the Possibilities of JavaFX
- Getting Ready to Run JavaFX
- Looking at a Simple JavaFX Program
- Importing JavaFX Packages
- Extending the Application Class
- Launching the Application
- Overriding the start Method
- Creating a Button
- Handling an Action Event
- Creating a Layout Pane
- Making a Scene
- Setting the Stage
- Examining the Click Counter Program
- Chapter 2: Handling Events
- Chapter 3: Setting the Stage and Scene Layout
- Chapter 4: Using Layout Panes to Arrange Your Scenes
- Chapter 5: Getting Input from the User
- Chapter 6: Choosing from a List
-
Chapter 1: Hello, JavaFX!
- Book 7: Web Programming
- Index
- About the Author
- Advertisement Page
- Connect with Dummies
- End User License Agreement
Product information
- Title: Java All-in-One For Dummies, 6th Edition
- Author(s):
- Release date: September 2020
- Publisher(s): For Dummies
- ISBN: 9781119680451
You might also like
book
Java For Dummies, 8th Edition
Learn to write practical, reusable code with the straightforward tutorials and tips in the newest edition …
book
Java for Absolute Beginners: Learn to Program the Fundamentals the Java 9+ Way
Write your first code in Java using simple, step-by-step examples that model real-word objects and events, …
book
Core Java, Volume I Fundamentals, 11th Edition
The #1 Java Guide for Serious Programmers: Fully Updated for Java SE 9, 10 & 11 …
book
Java Cookbook, 4th Edition
Java continues to grow and evolve, and this cookbook continues to evolve in tandem. With this …