java的1000+篇文章总结
本文收集和总结了有关java的1000+篇文章,由于篇幅有限只能总结近期的内容,想了解更多内容可以访问:http://www.ai2news.com/, 其分享了有关AI的论文、文章、图书。
- Other books in O’Reilly’s Head First series
- Table of Contents (the real thing)
- How to Use This Book: Intro
- Who is this book for?
- We know what you’re thinking & And we know what your brain is thinking
- Metacognition: thinking about thinking
- Here’s what WE did:
- Here’s what YOU can do to bend your brain into submission
- What you need for this book:
- Last-minute things you need to know:
- Technical Reviewers for the 3rd Edition
- Other people to acknowledge for the 3rd Edition
- Technical Editors for the 2nd Edition
- Other people to credit, for the 2nd Edition
- Just when you thought there wouldn’t be any more acknowledgments*
- 1. Breaking the Surface: Dive In: A Quick Dip
- The way Java works & What you’ll do in Java
- A very brief history of Java
- Code structure in Java
- Anatomy of a class
- Writing a class with a main()
- What can you say in the main method?
- Looping and looping and…
- Conditional branching
- Coding a serious business application
- Monday morning at Bob’s Java-enabled house
- Phrase-O-Matic
- Exercise
- Exercise Solutions
- 2. A Trip to Objectville: Classes and Objects
- Chair Wars
- What’s the difference between a class and an object?
- Making your first object
- Making and testing Movie objects
- Quick! Get out of main!
- Running the Guessing Game
- Exercise
- Exercise Solutions
- 3. Know Your Variables: Primitives and References
- Declaring a variable
- “I’d like a double mocha, no, make it an int.”
- You really don’t want to spill that…
- Back away from that keyword!
- This table reserved & Controlling your Dog object
- An object reference is just another variable value
- Java Exposed
- An array is like a tray of cups
- Arrays are objects too & Make an array of Dogs
- Control your Dog (with a reference variable)
- What happens if the Dog is in a Dog array?
- A Dog example
- Exercise
- Exercise Solutions
- 4. How Objects Behave: Methods Use Instance Variables
- Remember: a class describes what an object knows and what an object does
- The size affects the bark
- You can send things to a method
- You can get things back from a method
- You can send more than one thing to a method & Java is pass-by-value. That means pass-by-copy.
- Reminder: Java cares about type!
- Cool things you can do with parameters and return types
- Encapsulation
- Java Exposed
- Encapsulating the GoodDog class & How do objects in an array behave?
- Declaring and initializing instance variables
- The difference between instance and local variables
- Comparing variables (primitives or references)
- Exercise
- Exercise Solutions
- 5. Extra-Strength Methods: Writing A Program
- Let’s build a Battleship-style game: “Sink a Startup”
- First, a high-level design
- The “Simple Startup Game” a gentler introduction
- Developing a Class
- Writing the method implementations
- Writing test code for the SimpleStartup class
- Test code for the SimpleStartup class & The checkYourself() method
- Just the new stuff
- Final code for SimpleStartup and SimpleStartupTestDrive
- Prep code for the SimpleStartupGame class Everything happens in main()
- The game’s main() method
- random() and getUserInput()
- One last class: GameHelper
- Let’s play & What’s this? A bug ?
- More about for loops
- Trips through a loop
- The enhanced for loop
- Casting primitives
- Exercise
- Exercise Solutions
- 6. Using the Java Library: Get to Know the Java API
- In our last chapter, we left you with the cliff-hanger: a bug & So what happened? & How do we fix it?
- Option one is too clunky
- Option two is a little better, but still pretty clunky
- Wake up and smell the library & Some things you can do with ArrayList
- Java Exposed
- Solution
- Comparing ArrayList to a regular array
- Let’s fix the Startup code & New and improved Startup class & Let’s build the REAL game: “Sink a Startup”
- What needs to change?
- Who does what in the StartupBust game (and when) & Prep code for the real StartupBust class
- The final version of the Startup class & Super powerful Boolean expressions
- Ready-Bake Code & Using the Library (the Java API)
- You have to know the full name* of the class you want to use in your code.
- How to discover the API & Browse a book & Use the HTML API docs
- Using the class documentation
- Exercise
- Exercise Solutions
- 7. Better Living in Objectville: Inheritance and Polymorphism
- Chair Wars Revisited…
- What about the Amoeba rotate()?
- Understanding Inheritance
- An inheritance example:
- Let’s design the inheritance tree for an Animal simulation program
- Using inheritance to avoid duplicating code in subclasses
- Do all animals eat the same way?
- Looking for more inheritance opportunities
- Which method is called?
- Designing an Inheritance Tree
- Using IS-A and HAS-A
- But wait! There’s more!
- How do you know if you’ve got your inheritance right?
- When designing with inheritance, are you using or abusing?
- So what does all this inheritance really buy you?
- Inheritance lets you guarantee that all classes grouped under a certain supertype have all the methods that the supertype has*
- Keeping the contract: rules for overriding
- Overloading a method
- Exercise
- Exercise Solutions
- 8. Serious Polymorphism: Interfaces and Abstract Classes
- Did we forget about something when we designed this?
- The compiler won’t let you instantiate an abstract class
- Abstract vs. Concrete
- Abstract methods
- You MUST implement all abstract methods
- Polymorphism in action
- Uh-oh, now we need to keep Cats, too
- What about non-Animals? Why not make a class generic enough to take anything?
- So what’s in this ultra-super-megaclass Object?
- Using polymorphic references of type Object has a price…
- When a Dog won’t act like a Dog & Objects don’t bark
- Get in touch with your inner Object
- Polymorphism means “many forms.”
- What if you need to change the contract?
- Let’s explore some design options for reusing some of our existing classes in a PetShop program
- Interface to the rescue!
- Making and implementing the Pet interface
- Invoking the superclass version of a method
- Exercise
- Exercise Solutions
- 9. Life and Death of an Object: Constructors and Garbage Collection
- The Stack and the Heap: where things live
- Methods are stacked
- What about local variables that are objects?
- If local variables live on the stack, where do instance variables live?
- The miracle of object creation
- Construct a Duck
- Initializing the state of a new Duck
- Using the constructor to initialize important Duck state*
- Make it easy to make a Duck
- Doesn’t the compiler always make a no-arg constructor for you? No!
- Nanoreview: four things to remember about constructors
- Wait a minute…we never DID talk about superclasses and inheritance and how that all fits in with constructors
- The role of superclass constructors in an object’s life
- Making a Hippo means making the Animal and Object parts too…
- How do you invoke a superclass constructor?
- Can the child exist before the parents?
- Superclass constructors with arguments
- Invoking one overloaded constructor from another
- Now we know how an object is born, but how long does an object live?
- What about reference variables?
- Exercise
- Exercise Solutions
- . Numbers Matter: Numbers and Statics
- MATH methods: as close as you’ll ever get to a global method
- The difference between regular (non-static) and static methods & What it means to have a class with static methods
- Static methods can’t use non-static (instance) variables!
- Static methods can’t use non-static methods, either!
- Static variable: value is the same for ALL instances of the class
- static final variables are constants
- final isn’t just for static variables…
- Math methods
- Wrapping a primitive
- Java will Autobox primitives for you
- Autoboxing works almost everywhere
- But wait! There’s more! Wrappers have static utility methods too!
- And now in reverse…turning a primitive number into a String & Number formatting
- Formatting deconstructed…
- The percent (%) says, “insert argument here” (and format it using these instructions)
- The format String uses its own little language syntax
- The format specifier
- The only required specifier is for TYPE
- What happens if I have more than one argument?
- Just one more thing…static imports
- Fireside Chats
- Exercise
- Exercise Solution
- . Data Structures: Collections and Generics
- Tracking song popularity on your jukebox
- Your first job, sort the songs in alphabetical order & Great question! You spotted the diamond operator
- Exploring the java.util API, List and Collections
- In the “Real-World”™ there are lots of ways to sort
- “Natural Ordering,” what Java means by alphabetical
- But now you need Song objects, not just simple Strings
- Changing the Jukebox code to use Songs instead of Strings & It won’t compile!
- The sort() method declaration
- Generics means more type-safety
- Learning generics
- Using generic CLASSES
- Using type parameters with ArrayList
- Using generic METHODS
- Here’s where it gets weird…
- Revisiting the sort() method & In generics, “extends” means “extends or implements”
- Finally we know what’s wrong…
- The new, improved, comparable Song class
- We can sort the list, but…
- Using a custom Comparator
- Updating the Jukebox to use a Comparator & Fill-in-the-blanks
- But wait! We’re sorting in two different ways!
- Sorting using only Comparators & Just the code that matters
- What do we REALLY need in order to sort?
- Enter lambdas! Leveraging what the compiler can infer & Where did all that code go?
- Some interfaces have only ONE method to implement
- Updating the Jukebox code with lambdas & Reverse Engineer
- Uh-oh. The sorting all works, but now we have duplicates…
- We need a Set instead of a List
- The Collection API (part of it) & Using a HashSet instead of ArrayList
- What makes two objects equal?
- How a HashSet checks for duplicates: hashCode() and equals()
- The Song class with overridden hashCode() and equals()
- If we want the set to stay sorted, we’ve got TreeSet
- What you MUST know about TreeSet…
- TreeSet elements MUST be comparable
- We’ve seen Lists and Sets, now we’ll use a Map
- Creating and filling collections
- Convenience Factory Methods for Collections
- Finally, back to generics
- But will it work with List? & What could happen if it were allowed…?
- We can do this with wildcards
- Using the method’s generic type parameter
- Exercise
- Exercise Solution
- . Lambdas and Streams: What, Not How: Lambdas and Streams
- Tell the computer WHAT you want
- Fireside Chats
- When for loops go wrong
- Small errors in common code can be hard to spot
- Building blocks of common operations
- Introducing the Streams API
- Getting started with Streams
- Streams are like recipes: nothing’s going to happen until someone actually cooks them
- Getting a result from a Stream
- Stream operations are building blocks
- Building blocks can be stacked and combined
- Customizing the building blocks
- Create complex pipelines block by block & Yes, because Streams are lazy
- Terminal operations do all the work & Collecting to a List
- Guidelines for working with streams
- Exercise
- Hello Lambda, my (not so) old friend
- The shape of lambda expressions
- Anatomy of a lambda expression & Variety is the spice of life
- How can I tell if a method takes a lambda?
- Exercise
- Spotting Functional Interfaces
- Functional interfaces in the wild
- Lou’s back!
- Exercise & Ready-Bake Code
- Lou’s Challenge #1: Find all the “rock” songs
- Filter a stream to keep certain elements & Let’s Rock!
- Getting clever with filters
- Lou’s Challenge #2: List all the genres
- Mapping from one type to another
- Removing duplicates & Only one of every genre
- Just keep building!
- Sometimes you don’t even need a lambda expression
- Collecting results in different ways
- But wait, there’s more!
- Optional is a wrapper
- Don’t forget to talk to the Optional wrapper
- Exercise Solutions
- . Risky Behavior: Exception Handling
- Let’s make a Music Machine
- We’ll start with the basics
- First we need a Sequencer
- What happens when a method you want to call (probably in a class you didn’t write) is risky? & Methods in Java use exceptions to tell the calling code, “Something Bad Happened. I failed.”
- The compiler needs to know that YOU know you’re calling a risky method & An exception is an object… of type Exception
- If it’s your code that catches the exception, then whose code throws it?
- Flow control in try/catch blocks & Finally: for the things you want to do no matter what
- Flow Control & Did we mention that a method can throw more than one exception?
- Exceptions are polymorphic
- Multiple catch blocks must be ordered from smallest to biggest
- You can’t put bigger baskets above smaller baskets
- When you don’t want to handle an exception…
- Ducking (by declaring) only delays the inevitable
- Getting back to our music code…
- Code Kitchen & Making actual sound
- Version 1: Your very first sound player app & Making a MidiEvent (song data)
- MIDI message: the heart of a MidiEvent
- Change a message
- Version 2: Using command-line args to experiment with sounds
- Exercise
- Exercise Solution
- . A Very Graphic Story: Getting Gui
- It all starts with a window
- Your first GUI: a button on a frame & But nothing happens when I click it…
- Getting a user event
- Listeners, Sources, and Events
- Getting back to graphics…
- Make your own drawing widget
- Fun things to do in paintComponent() & Behind every good Graphics reference is a Graphics2D object
- Because life’s too short to paint the circle a solid color when there’s a gradient blend waiting for you
- We can get an event. We can paint graphics. But can we paint graphics when we get an event?
- GUI layouts: putting more than one widget on a frame
- Let’s try it with TWO buttons & So now we need FOUR widgets & And we need to get TWO events
- Inner class to the rescue!
- An inner class instance must be tied to an outer class instance*
- How to make an instance of an inner class
- Lambdas to the rescue! (again)
- ActionListener is a Functional Interface & Lambdas, clearer and more concise & Using an inner class for animation
- Code Kitchen & Listening for a non-GUI event
- An easier way to make messages/events
- Version One: using the new static makeEvent() method & Version Two: registering and getting ControllerEvents
- Version Three: drawing graphics in time with the music
- Exercise
- Exercise Solutions
- . Work on Your Swing: Using Swing
- . Saving Objects (and Text): Serialization and File I/O
- Capture the beat
- Saving state
- Writing a serialized object to a file & Data moves in streams from one place to another
- What really happens to an object when it’s serialized? & But what exactly IS an object’s state? What needs to be saved?
- If you want your class to be serializable, implement Serializable
- Deserialization: restoring an object & What happens during deserialization?
- Saving and restoring the game characters
- Version ID: A big serialization gotcha
- Using the serialVersionUID
- Object Serialization
- Writing a String to a Text File
- Text file example: e-Flashcards
- Quiz Card Builder (code outline)
- The java.io.File class
- Reading from a text file
- Quiz Card Player (code outline)
- Parsing with String split()
- NIO.2 and the java.nio.file package
- Path, Paths, and Files (messing with directories)
- Finally, a closer look at finally
- Remember, finally ALWAYS runs!! & Finally, a closer look at finally, cont. & There IS a better way!
- The try-with-resources (TWR), statement
- Autocloseable, the very small catch & Autocloseable, it’s everywhere you do I/O
- Code Kitchen & Saving a BeatBox pattern
- Restoring a BeatBox pattern
- Can they be saved?
- Exercise
- Exercise Solutions
- . Make a Connection: Networking and Threads
- Real-time BeatBox chat
- Connecting, sending, and receiving
- 1. Connect
- 2. Receive
- 3. Send & There’s more than one way to make a connection
- The DailyAdviceClient
- DailyAdviceClient code
- Writing a simple server application
- DailyAdviceServer code
- Writing a Chat Client
- The really, really simple Chat Server
- Java has multiple threads but only one Thread class
- What does it mean to have more than one call stack?
- To create a new call stack you need a job to run
- To make a job for your thread, implement the Runnable interface & How NOT to run the Runnable
- How we used to launch a new thread & A better alternative: don’t manage the Threads at all
- Running one job
- The thread scheduler
- Putting a thread to sleep
- Using sleep to make our program more predictable
- There are downsides to forcing the thread to sleep
- Counting down until ready
- Making and starting two threads (or more!)
- Pooling Threads
- Running multiple threads & What will happen?
- Closing time at the thread pool
- Um, yes. There IS a dark side. Multithreading can lead to concurrency “issues.”
- Exercise
- New and improved SimpleChatClient
- Exercise & Exercise Solutions
- . Dealing with Concurrency Issues: Race Conditions and Immutable Data
- What could possibly go wrong?
- The Ryan and Monica problem, in code
- The Ryan and Monica example
- We need to check the balance and spend the money as one atomic thing
- Using an object’s lock
- Using synchronized methods
- It’s important to lock the correct object
- The dreaded “Lost Update” problem
- Let’s run this code… & Make the increment() method atomic. Synchronize it!
- Deadlock, a deadly side of synchronization
- You don’t always have to use synchronized
- Compare-and-swap with atomic variables
- Ryan and Monica, going atomic
- Writing a class for immutable data & Using immutable objects
- Changing immutable data
- More problems with shared data & Reading from a changing data structure causes an Exception
- Use a thread-safe data structure
- CopyOnWriteArrayList
- Exercise
- Exercise Solution
- A. Final Code Kitchen
- B. The top ten-ish topics that didn’t make it into the rest of the book…
- # JShell (Java REPL)
- # Packages
- #9 Immutability in Strings and Wrappers
- #8 Access levels and access modifiers (who sees what)
- #7 Varargs
- #6 Annotations
- #5 Lambdas and Maps
- #4 Parallel Streams
- #3 Enumerations (also called enumerated types or enums)
- #2 Local Variable Type Inference (var)
- #1 Records
- Index
- Preface
- 1. Introduction
- The Grain of a Programming Language
- An Opinionated History of Java Programming Style
- The Grain of Kotlin
- Refactoring to Kotlin
- What Are We Working On?
- Let’s Get Started!
- 2. Java to Kotlin Projects
- 3. Java to Kotlin Classes
- 4. Optional to Nullable
- Representing Absence
- Refactoring from Optional to Nullable
- Refactoring to Idiomatic Kotlin
- Moving On
- 5. Beans to Values
- 6. Java to Kotlin Collections
- Java Collections
- Kotlin Collections
- Refactoring from Java to Kotlin Collections
- Moving On
- 7. Actions to Calculations
- Functions
- Calculations
- Actions
- Why Should We Care?
- Why Prefer Calculations?
- Refactoring Actions to Calculations
- Moving On
- 8. Static Methods to Top-Level Functions
- 9. Multi- to Single-Expression Functions
- . Functions to Extension Functions
- Functions and Methods
- Extension Functions
- Extensions and Function Types
- Extension Properties
- Conversions
- Nullable Parameters
- Nullable Receivers
- Generics
- Extension Functions as Methods
- Refactoring to Extension Functions
- Moving On
- . Methods to Properties
- . Functions to Operators
- . Streams to Iterables to Sequences
- Java Streams
- Kotlin Iterables
- Kotlin Sequences
- Multiple Iterations
- Choosing Between Streams, Iterables, and Sequences
- Algebraic Transformation
- Refactoring from Streams to Iterables and Sequences
- Moving On
- . Accumulating Objects to Transformations
- Calculating with Accumulator Parameters
- Refactoring to Functions over Immutable Data
- Let’s Do That Again
- Enriching the Abstraction We Discovered
- Moving On
- . Encapsulated Collections to Type Aliases
- Composing Domain Collections
- Collections with Other Properties
- Refactoring Encapsulated Collections
- Moving On
- . Interfaces to Functions
- Object-Oriented Encapsulation
- Functional Encapsulation
- Function Types in Java
- Mix and Match
- Comparing the Approaches
- Coupling
- Object-Oriented or Functional?
- The Legacy of Java
- Traceability
- Refactoring from Interfaces to Functions
- Moving On
- . Mocks to Maps
- . Open to Sealed Classes
- . Throwing to Returning
- Error Handling Before Exceptions
- Error Handling with Exceptions & Java and Checked Exceptions
- Kotlin and Exceptions
- Beyond Exceptions: Functional Error Handling
- Error Handling in Kotlin
- Refactoring Exceptions to Errors
- More Fixup
- Layers
- Moving On
- . Performing I/O to Passing Data
- Listening to Tests
- I/O to Data
- Efficient Writing
- Efficient Reading
- Moving On
- . Exceptions to Values
- Identifying What Can Go Wrong
- Representing Errors
- What About I/O?
- Moving On
- . Classes to Functions
- An Acceptance Test
- Unit Testing
- Headers
- Different Field Separators
- Sequences
- Reading from a File
- Comparison with Commons CSV
- Moving On
- . Continuing the Journey
- Bibliography
- Index
- Cover
- Title Page & Copyright Page
- Contents
- INTRODUCTION
- 1 Java Fundamentals
- The History and Philosophy of Java
- Object-Oriented Programming
- The Java Development Kit
- A First Simple Program
- Handling Syntax Errors
- A Second Simple Program
- Another Data Type
- Try This : Converting Gallons to Liters
- Two Control Statements
- Create Blocks of Code
- Semicolons and Positioning
- Indentation Practices
- Try This : Improving the Gallons-to-Liters Converter
- The Java Keywords
- Identifiers in Java
- The Java Class Libraries
- Chapter 1 Self Test
- 2 Introducing Data Types and Operators
- Why Data Types Are Important
- Java’s Primitive Types
- The Boolean Type
- Try This : How Far Away Is the Lightning?
- Literals
- A Closer Look at Variables
- The Scope and Lifetime of Variables
- Operators
- Arithmetic Operators
- Relational and Logical Operators
- Short-Circuit Logical Operators
- The Assignment Operator
- Shorthand Assignments
- Type Conversion in Assignments
- Casting Incompatible Types
- Operator Precedence & Try This : Display a Truth Table for the Logical Operators
- Expressions
- 3 Program Control Statements
- Input Characters from the Keyboard
- The if Statement
- Nested ifs
- The if-else-if Ladder
- The Traditional switch Statement
- Nested switch Statements & Try This : Start Building a Java Help System
- The for Loop
- Some Variations on the for Loop
- Missing Pieces
- Loops with No Body
- Declaring Loop Control Variables Inside the for Loop
- The Enhanced for Loop & The while Loop
- The do-while Loop
- Try This : Improve the Java Help System
- Use break to Exit a Loop
- Use break as a Form of goto
- Use continue
- Try This : Finish the Java Help System
- Nested Loops
- Chapter 3 Self Test
- 4 Introducing Classes, Objects, and Methods
- Class Fundamentals
- How Objects Are Created
- Reference Variables and Assignment
- Methods
- Returning from a Method
- Returning a Value
- Using Parameters
- Try This : Creating a Help Class
- Constructors
- Parameterized Constructors
- Adding a Constructor to the Vehicle Class
- The new Operator Revisited
- Garbage Collection
- The this Keyword
- Chapter 4 Self Test
- 5 More Data Types and Operators
- Arrays
- Try This : Sorting an Array
- Multidimensional Arrays
- Alternative Array Declaration Syntax
- Assigning Array References & Using the length Member
- Try This : A Queue Class
- The For-Each Style for Loop
- Strings
- Using a String to Control a switch Statement
- Using Command-Line Arguments
- The Bitwise Operators
- Try This : A ShowBits Class
- The ? Operator
- Chapter 5 Self Test
- 6 A Closer Look at Methods and Classes
- Controlling Access to Class Members
- Try This : Improving the Queue Class
- Pass Objects to Methods
- Returning Objects
- Method Overloading
- Overloading Constructors
- Try This : Overloading the Queue Constructor
- Recursion
- Understanding static
- Try This : The Quicksort
- Introducing Nested and Inner Classes
- Varargs: Variable-Length Arguments
- Chapter 6 Self Test
- 7 Inheritance
- Inheritance Basics
- Member Access and Inheritance
- Constructors and Inheritance
- Using super to Call Superclass Constructors
- Using super to Access Superclass Members
- Try This : Extending the Vehicle Class
- Creating a Multilevel Hierarchy
- When Are Constructors Executed?
- Superclass References and Subclass Objects
- Method Overriding
- Overridden Methods Support Polymorphism
- Why Overridden Methods?
- Using Abstract Classes
- Using final
- The Object Class
- Chapter 7 Self Test
- 8 Packages and Interfaces
- Packages
- Packages and Member Access
- Understanding Protected Members
- Importing Packages
- Java’s Class Library Is Contained in Packages
- Interfaces
- Implementing Interfaces
- Using Interface References
- Try This : Creating a Queue Interface
- Variables in Interfaces
- Interfaces Can Be Extended
- Default Interface Methods
- Use static Methods in an Interface
- Private Interface Methods
- Final Thoughts on Packages and Interfaces
- Chapter 8 Self Test
- 9 Exception Handling
- The Exception Hierarchy
- Exception Handling Fundamentals
- The Consequences of an Uncaught Exception
- Using Multiple catch Statements
- Catching Subclass Exceptions
- Try Blocks Can Be Nested
- Throwing an Exception
- A Closer Look at Throwable
- Using finally
- Using throws
- Three Additional Exception Features
- Java’s Built-in Exceptions
- Creating Exception Subclasses
- Try This : Adding Exceptions to the Queue Class
- Chapter 9 Self Test
- Using I/O
- Java’s I/O Is Built upon Streams
- Byte Streams and Character Streams
- The Byte Stream Classes
- The Character Stream Classes
- The Predefined Streams
- Using the Byte Streams
- Reading and Writing Files Using Byte Streams
- Automatically Closing a File
- Reading and Writing Binary Data
- Try This : A File Comparison Utility
- Random-Access Files
- Using Java’s Character-Based Streams
- File I/O Using Character Streams
- Using Java’s Type Wrappers to Convert Numeric Strings
- Try This : Creating a Disk-Based Help System
- Chapter Self Test
- Multithreaded Programming
- Multithreading Fundamentals
- The Thread Class and Runnable Interface
- Creating a Thread
- Try This : Extending Thread
- Creating Multiple Threads
- Determining When a Thread Ends
- Thread Priorities
- Synchronization
- Using Synchronized Methods
- The synchronized Statement
- Thread Communication Using notify( ), wait( ), and notifyAll( )
- Suspending, Resuming, and Stopping Threads
- Try This : Using the Main Thread
- Chapter Self Test
- Enumerations, Autoboxing, Annotations, and More
- Enumerations
- Java Enumerations Are Class Types
- The values( ) and valueOf( ) Methods
- Constructors, Methods, Instance Variables, and Enumerations
- Enumerations Inherit Enum
- Try This : A Computer-Controlled Traffic Light
- Autoboxing
- Type Wrappers
- Autoboxing Fundamentals
- Autoboxing and Methods
- Autoboxing/Unboxing Occurs in Expressions
- Static Import
- Annotations (Metadata)
- Introducing instanceof
- Chapter Self Test
- Generics
- Generics Fundamentals
- A Simple Generics Example
- Bounded Types
- Using Wildcard Arguments
- Bounded Wildcards
- Generic Methods
- Generic Constructors
- Generic Interfaces
- Try This : Create a Generic Queue
- Raw Types and Legacy Code
- Type Inference with the Diamond Operator
- Local Variable Type Inference and Generics
- Erasure
- Ambiguity Errors
- Some Generic Restrictions
- Lambda Expressions and Method References
- Introducing Lambda Expressions
- Block Lambda Expressions
- Generic Functional Interfaces
- Try This : Pass a Lambda Expression as an Argument
- Lambda Expressions and Variable Capture
- Throw an Exception from Within a Lambda Expression
- Method References
- Constructor References
- Predefined Functional Interfaces
- Chapter Self Test
- Modules
- Module Basics
- java.base and the Platform Modules
- Legacy Code and the Unnamed Module
- Exporting to a Specific Module
- Using requires transitive
- Try This : Experiment with requires transitive
- Use Services
- Additional Module Features
- Continuing Your Study of Modules
- Chapter Self Test
- Switch Expressions, Records, and Other Recently Added Features
- Enhancements to switch
- Try This : Use a switch Expression to Obtain a City’s Time Zone
- Records
- Pattern Matching with instanceof
- Sealed Classes and Interfaces
- Future Directions
- Chapter Self Test
- Introducing Swing
- The Origins and Design Philosophy of Swing
- Components and Containers
- Layout Managers
- A First Simple Swing Program
- Swing Event Handling
- Use JButton
- Work with JTextField
- Create a JCheckBox
- Work with JList
- Try This : A Swing-Based File Comparison Utility
- Use Anonymous Inner Classes or Lambda Expressions to Handle Events
- A Answers to Self Tests
- Chapter 1: Java Fundamentals
- Chapter 2: Introducing Data Types and Operators
- Chapter 3: Program Control Statements
- Chapter 4: Introducing Classes, Objects, and Methods
- Chapter 5: More Data Types and Operators
- Chapter 6: A Closer Look at Methods and Classes
- Chapter 7: Inheritance
- Chapter 8: Packages and Interfaces
- Chapter 9: Exception Handling
- Chapter : Using I/O
- Chapter : Multithreaded Programming
- Chapter : Enumerations, Autoboxing, Annotations, and More
- Chapter : Generics
- Chapter : Lambda Expressions and Method References
- Chapter : Modules
- Chapter : Switch Expressions, Records, and Other Recently Added Features
- Chapter : Introducing Swing
- B Using Java’s Documentation Comments
- C Compile and Run Simple Single-File Programs in One Step
- D Introducing JShell
- E More Java Keywords
- Index
- Preface: JAVA as Artificial Intelligence
- Introduction
- Chapter 1: Algorithms: The Essentials
- Chapter 2: How to Create a Problem-Solving AI
- JAVA a: Fundamental Frontier Search Algorithm
- JAVA b: Using Frontier Search
- Chapter 3: Search Strategies
- Chapter : Depth-First Search
- Chapter : Breadth-First Search
- JAVA : Frontier Search as DFS and BFS
- Chapter : Lowest-Cost First Search
- Chapter : Heuristic Search
- JAVA a: using AI to Solve Complex Time Scheduling
- JAVA b: The Generate-And-Test General Algorithm
- JAVA c: The Procedure: Schedule Solvers
- JAVA d: Schedule Solvers, Faster Version
- Chapter 5: Logic & Reasoning
- JAVA a: Using Logic-Based AI
- Chapter 6: Environment Representation for AI
- JAVA a: Environment Models with Java
- JAVA b: Creating a Model Environment
- Chapter 7: Your AI Knowledge & Abilities
- EASIEST WAY TO LEARN Java, Part 1
- EASIEST WAY TO LEARN Java, Part 2
- EASIEST WAY TO LEARN OBJECT-ORIENTED
- ARCHIVE A: Frontier Search Algorithm
- ARCHIVE A: Bigger Search Graph
- ARCHIVE JAVA-A3a: Solving Schedule Problems
- ARCHIVE JAVA-A3b: Solving Schedule Problems
- ARCHIVE JAVA-A4a: Top Down Diagnosis
- ARCHIVE JAVA-A4b: Bottom Up Diagnosis
- From Platform to Ecosystem
- Preface
- 1. Revisiting Enterprise Development
- 2. The Path to Cloud Native Java
- Cloud Native Workshop
- Architecture
- Create an Inventory Microservice with Quarkus
- Create a Catalog Microservice with Spring Boot
- Create a Gateway Service with Vert.x
- Create a Frontend with Node.js and AngularJS
- Summary
- 3. Travel Light on Your Pathway
- Three-Tier or Distributed System
- Divide and Containerize
- Mandatory Migration Steps and Tools
- Prepare for Big Things
- Summary
- 4. A Kubernetes-Based Software Development Platform
- Developers and Kubernetes
- Container Images
- Deploying to Kubernetes
- Kubernetes and Java
- Summary
- 5. Beyond Lift and Shift: Working with Legacy
- Managing Legacy
- Migration Approaches
- Challenges
- Integration Aspects
- Summary
- 6. Building Kubernetes-Native Applications
- Find the Right Balance Between Scalability and Complexity
- Functional Requirements for Modern Architectures
- Debugging Microservices
- Summary
- 7. Tomorrow’s Solutions: Serverless
- What Is Serverless?
- Use Cases: Data, AI, and Machine Learning
- Use Cases: Edge Computing and IoT
- Knative: Serverless for Kubernetes
- Event-Driven Serverless Architectures
- Function as a Service for Java Applications
- Summary
- Index
- 本书服务网址 & 源代码 & 我们的联系方式
- 开篇综述 & Java语言历史
- Java语言特点
- Java平台 & 1.3.1 Java SE
- Java EE & 1.3.3 Java ME & 1.4 Java虚拟机
- 本章小结
- 开发环境搭建 & JDK工具包 & 2.1.1 JDK下载和安装
- 设置环境变量
- Eclipse开发工具 & 2.2.1 Eclipse下载和安装
- 安装中文语言包
- Eclipse界面 & 2.2.4 Windows系统中常用快捷键
- 其他开发工具 & 2.3.1 IntelliJ IDEA
- NetBeans IDE & 2.3.3 文本编辑工具
- 本章小结
- 文本编辑工具+JDK实现 & 3.2.1 编写源代码文件
- 本章小结
- Java语法基础 & 标识符、关键字和保留字 & 4.1.1 标识符
- 关键字 & 4.1.3 保留字 & 4.2 Java分隔符
- 本章小结
- 数据类型 & 基本数据类型 & 5.2 整型类型
- 浮点类型
- 数字表示方式 & 5.4.1 进制数字表示 & 5.4.2 指数表示
- 字符类型
- 布尔类型 & 5.7 数值类型相互转换
- 自动类型转换
- 强制类型转换
- 引用数据类型
- 本章小结
- 运算符 & 算术运算符 & 6.1.1 一元运算符
- 二元运算符
- 算术赋值运算符 & 6.2 关系运算符
- 逻辑运算符
- 位运算符
- 其他运算符
- 运算符优先级 & 本章小结
- 控制语句 & 分支语句 & 7.1.1 if语句
- switch语句
- 循环语句 & 7.2.1 while语句
- do-while语句 & 7.2.3 for语句
- for-each语句
- 跳转语句 & 7.3.1 break语句
- continue语句
- 本章小结
- 数组 & 一维数组 & 8.1.1 数组声明
- 数组初始化
- 案例:数组合并
- 多维数组 & 8.2.1 二维数组声明 & 8.2.2 二维数组的初始化
- 不规则数组
- 本章小结
- 字符串 & Java中的字符串
- 使用API文档
- 不可变字符串 & 9.3.1 String
- 字符串池
- 字符串拼接
- 字符串查找
- 字符串比较
- 字符串截取
- 可变字符串 & 9.4.1 StringBuffer和StringBuilder
- 字符串追加
- 字符串插入、删除和替换
- 本章小结
- 面向对象基础 & 面向对象概述 & 10.2 面向对象三个基本特性 & 10.2.1 封装性
- 继承性 & 10.2.3 多态性 & 10.3 类 & 10.3.1 类声明
- 成员变量
- 成员方法
- 包 & 10.4.1 包作用
- 方法重载(Overload)
- 封装性与访问控制 & 10.6.1 私有级别
- 默认级别
- 公有级别
- 保护级别
- 静态变量和静态方法
- 静态代码块
- 本章小结
- 对象 & 创建对象 & 11.2 空对象
- 构造方法
- 默认构造方法 & 11.3.2 构造方法重载
- 构造方法封装
- this关键字
- 对象销毁 & 本章小结
- 继承与多态 & Java中的继承
- 调用父类构造方法
- 成员变量隐藏和方法覆盖 & 12.3.1 成员变量隐藏
- 方法的覆盖(Override)
- 多态 & 12.4.1 多态概念
- 引用类型检查
- 引用类型转换
- 再谈final关键字 & 12.5.1 final修饰变量
- final修饰类 & 12.5.3 final修饰方法
- 本章小结
- 抽象类与接口 & 抽象类 & 13.1.1 抽象类概念
- 抽象类声明和实现
- 使用接口 & 13.2.1 接口概念 & 13.2.2 接口声明和实现
- 接口与多继承
- 接口继承
- Java 8新特性默认方法和静态方法
- 抽象类与接口区别 & 本章小结
- 异常处理 & 从一个问题开始
- 异常类继承层次 & 14.2.1 Throwable类
- Error和Exception & 14.2.3 受检查异常和运行时异常
- 捕获异常 & 14.3.1 try-catch语句
- 多catch代码块
- try-catch语句嵌套
- 多重捕获
- 释放资源 & 14.4.1 finally代码块
- 自动资源管理
- throws与声明方法抛出异常
- 自定义异常类
- throw与显式抛出异常
- 本章小结
- 对象容器——集合 & 集合概述
- List集合
- 常用方法
- 遍历集合
- Set集合 & 15.3.1 常用方法
- 遍历集合
- Map集合 & 15.4.1 常用方法
- 遍历集合
- 本章小结
- 文件管理与I/O流 & 文件管理 & 16.1.1 File类
- 案例:文件过滤
- I/O流概述 & 16.2.1 Java流设计理念 & 16.2.2 流类继承层次
- 字节流 & 16.3.1 InputStream抽象类
- OutputStream抽象类
- 案例:文件复制
- 使用字节缓冲流
- 字符流 & 16.4.1 Reader抽象类
- Writer抽象类
- 案例:文件复制
- 使用字符缓冲流
- 字节流转换字符流
- 本章小结
- 网络编程 & 网络基础 & 17.1.1 网络结构
- TCP/IP协议 & 17.1.3 IP地址
- 端口 & 17.2 数据交换格式
- JSON文档结构
- 使用第三方JSON库
- JSON数据编码和解码
- 访问互联网资源 & 17.3.1 URL概念 & 17.3.2 HTTP/HTTPS协议
- 使用URL类
- 使用HttpURLConnection发送GET请求
- 使用HttpURLConnection发送POST请求
- 实例:Downloader
- 本章小结
- 作者简介
- 一种现代语言
- 进入Java世界
- Java的起源
- Java与其他语言的比较
- 设计安全 & 1.4.1 语法简单性
- 类型安全和方法绑定
- 递增开发 & 1.4.4 动态内存管理
- 错误处理 & 1.4.6 线程
- 可伸缩性 & 1.5 实现安全
- 类加载器 & 1.5.3 安全管理器
- 应用和用户级安全性
- Java路线图 & 1.7.1 过去:Java 1.0到Java 1.6
- 如今:Java 7
- 将来 & 1.7.4 可用性
- 第一个应用
- Java工具和环境
- 配置Eclipse并且创建项目
- 导入本书示例
- HelloJava
- main()方法
- 类和对象
- 变量与类类型
- HelloComponent
- JComponent类
- 关系与指向
- 包与导入
- paintComponent() 方法
- HelloJava2:余波未平
- 实例变量
- 构造函数
- repaint()方法
- HelloJava3:按钮的震撼
- 方法重载 & 2.5.2 组件
- 容器 & 2.5.4 布局
- 派生子类与子类型 & 2.5.6 更多事件和接口
- 颜色的说明 & 2.5.8 静态成员
- 数组 & 2.5.10 颜色的相关方法
- HelloJava4:Netscape的反戈一击 & 2.6.1 线程
- Thread类
- Runnable接口 & 2.6.4 启动线程
- 在线程中运行代码
- 使用工具 & JDK环境
- Java编译器
- JAR Files & 3.6.1 文件压缩
- jar工具
- Pack200工具
- 策略文件
- 默认的安全性管理器 & 3.7.2 policytool工具
- 通过默认的安全管理器使用策略文件
- Java语言
- 文本编码
- 基本类型
- 引用类型
- 字符串的有关问题 & 4.4 语句和表达式
- 异常和错误类
- 异常处理
- 逐级上浮
- 受查和非受查异常
- 抛出异常
- try的“潜伏”功用 & 4.5.8 finally子句
- 带有资源的Try
- 性能问题 & 4.6 断言
- 启用和禁用断言 & 4.6.2 使用断言
- 数组类型 & 4.7.2 数组的创建和初始化
- 使用数组
- 匿名数组 & 4.7.5 多维数组
- 深入数组
- Java中的对象
- 访问字段和方法
- 静态成员
- 方法 & 5.2.1 局部变量
- 静态方法
- 初始化局部变量
- 参数传递与引用
- 基本类型的包装器
- 基本类型的自动装箱和拆箱
- 可变长度的参数列表
- 方法重载
- 对象创建 & 5.3.1 构造函数
- 使用重载构造函数
- 静态和非静态初始化块
- 对象销毁 & 5.4.1 垃圾回收
- 弱引用和软引用
- 枚举值 & 5.5.2 定制化枚举
- 类之间的关系 & 派生子类和继承
- 被遮蔽变量
- 覆盖方法
- 特殊引用:this和super & 6.1.4 类型强制转换
- 使用超类构造函数
- 完全揭密:构造函数和初始化 & 6.1.7 抽象方法和类
- 作为回调的接口
- 接口变量
- 包与编译单元 & 6.3.1 编译单元
- 包名 & 6.3.3 类可见性
- 变量和方法的可见性 & 6.4.1 基本访问修饰符
- 子类和可见性
- 接口和可见性 & 6.5 数组和类的层次体系结构
- 内部类作为适配器
- 方法中的内部类
- 使用对象和类 & Object类
- 相等性与等价
- 复制对象
- Class类
- 访问字段
- 访问方法
- 访问构造函数
- 关于数组 & 7.3.6 访问泛型类型信息
- 访问注解数据 & 7.3.8 动态接口适配器
- 反射适用之处
- 使用注解
- 标准注解 & 7.4.3 Apt工具
- 容器:构建一个更好的捕鼠器
- 走进泛型
- 根本就没有勺子
- 原始类型
- 参数化类型关系
- 为何List不是List呢
- 类型转换
- 编写泛型类 & 8.6.1 类型变量
- 子类化泛型 & 8.6.3 异常和泛型
- 参数类型限制
- 通配符 & 8.8.1 所有实例化的超类型
- 有界限通配符 & 8.8.3 思考容器
- 读、写和算术
- <?>、和原始类型
- 通配符类型关系
- 泛型方法
- 泛型方法的引入
- 根据参数进行类型推断
- 根据赋值环境做类型推断
- 显示类型调用 & 8.9.5 通配符捕获
- 通配符类型和泛型方法 & 8.10 参数化类型的数组
- 使用数组类型 & 8.10.2 泛型类型的数组有何优点
- 数组类型中的通配符
- 案例学习:Enum类
- 案例学习:sort()方法
- 线程简介
- Thread类和Runnable接口
- 控制线程
- 线程的消亡
- applet中线程的实现
- 对方法的串行化访问
- 访问多线程中的类和实例变量
- wait()和notify()方法
- 传递消息
- ThreadLocal对象
- 调度和优先级
- 线程状态 & 9.4.2 时间片划分
- 优先级 & 9.4.4 让步
- 使用ThreadGroup类
- 未捕获的异常 & 9.6 线程性能
- 同步的开销
- 线程资源消费
- 并发工具
- 同步构造
- 原子操作
- 文本处理
- 其他与文本相关的API & 10.2 String
- String构造函数
- 事物的字符串表示
- 字符串比较
- 查找 & 10.2.5 编辑
- String方法小结
- StringBuilder和StringBuffer
- 国际化 & 10.3.1 java.util.Locale类
- 解析与格式化文本
- 解析基本数字
- 文本分词
- Printf式格式化 & 10.5.1 Formatter
- 格式字符串
- 字符串转换
- 基本类型和数字转换
- 标志 & 10.5.6 其他
- 用java.text包格式化
- 正则表达式
- regex记法
- java.util.regex API
- 核心实用工具 & 数学实用工具
- java.lang.Math类
- Big/Precise Numbers & 11.1.3 浮点数组成部分
- 日期和时间
- 使用日历
- Time Zones
- 解析和格式化日期
- Printf式的日期和时间格式化
- Collection接口
- Collection类型
- Map接口
- 集合实现
- 哈希码和键值
- 同步和只读集合
- 同步和只读集合 & 11.4.9 WeakHashMap
- 一个令人激动的例子 & 11.5 特性
- 加载和存储
- 系统特性
- 首选项API
- 类的首选项 & 11.6.2 首选项存储
- 修改通知 & 11.7 日志API
- 日志级别
- 一个简单的例子 & 11.7.4 日志建立特性
- 性能 & 11.8 Observers和Observables
- 输入/输出功能 & 流
- 终端I/O
- 流包装器
- 流与String的转换
- Implementing a Filter Stream
- java.io.File类
- RandomAccessFile
- Resource Paths
- NIO File API
- FileSystem和Path
- NIO文件操作
- 监控路径
- 使用readObject()初始化
- SerialVersionUID
- 数据压缩 & 12.5.1 压缩数据
- 解压缩数据
- 作为文件系统的Zip归档文件
- NIO包 & 12.6.1 异步I/O
- 性能 & 12.6.3 映射和加锁文件 & 12.6.4 通道
- 字符编码器和解码器
- FileChannel
- 利用NIO实现可伸缩I/O
- 网络编程
- 客户端和服务器
- DateAtHost客户端
- TinyHttpd服务器
- 套接字选项
- 代理和防火墙
- 数据报套接字
- The HeartBeat Applet
- InetAddress
- 简单串行化对象协议
- 远程方法调用
- 现实的用法 & 13.4.2 远程和非远程对象
- 一个RMI示例
- RMI and CORBA & 13.5 使用NIO的可伸缩I/O
- 可选择通道
- 使用select
- LargerHttpd
- 非阻塞客户端端操作
- Web编程
- 统一资源定位器(URL)
- URL类
- 流数据 & 14.2.2 将内容获取为对象
- Managing Connections
- 实用的处理器
- 其他处理器框架
- 与Web应用通信
- 使用GET方法
- 使用POST方法
- The HttpURLConnection & 14.3.4 SSL和安全Web通信
- URLs、URNs和URIs
- Web Services & 14.4.1 XML-RPC
- WSDL & 14.4.3 工具
- Weather Service客户端
- Web应用与Web服务
- Web应用技术 & 15.1.1 面向页面的应用和单页应用
- JSP & 15.1.3 XML和XSL
- Web应用框架
- Google Web Toolkit & 15.1.6 HTML5、AJAX以及更多
- Java Web应用
- servlet生命期
- Servlets
- The HelloClient Servlet
- servlet响应
- servlet参数
- The ShowParameters Servlet
- 用户会话管理
- ShowSession Servlet
- ShoppingCart Servlet
- Cookies
- ServletContext API
- 异步Servlets
- WAR文件和部署
- 使用web.xml和注解配置
- URL模式映射
- 部署HelloClient
- 错误和索引页面
- 安全性和鉴别 & 15.3.6 为用户指定角色
- 安全数据传输
- 用户鉴别
- 过程性安全
- servlet过滤器
- 一个简单的过滤器
- 一个测试servlet & 15.4.3 声明和映射过滤器
- 过滤servlet请求
- 过滤servlet响应
- 使用Ant部署和重新部署WAR & 15.6 实现Web Services
- 定义服务 & 15.6.2 回显服务
- 使用服务
- 数据类型
- Swing
- 对等对象
- 模型-视图-控制器框架
- 启用和禁用组件 & 16.1.5 焦点
- 其他组件方法
- 布局管理器
- 管理组件 & 16.1.12 监听组件 & 16.1.13 窗口和框架
- 控制框架的其他方法 & 16.1.15 使用内容格
- 桌面集成
- 事件接收者和监听者接口
- 事件发送 & 16.2.4 事件类型
- java.awt.event.InputEvent类 & 16.2.6 InputEvent中的鼠标和按键修饰符
- 焦点事件
- 事件总结
- 适配器类
- 哑适配器
- AWT Robot
- Swing中的多线程
- 使用Swing组件 & 按钮和标签
- 按钮和标签中的HTML文本 & 17.2 复选框和单选钮
- 列表框和组合框
- PopupMenu类
- JScrollPane类
- JSplitPane类 & 17.10 JTabbedPane类
- 滚动条和滑块
- 文件选择对话框
- 颜色选择器
- 再谈Swing组件 & 文本组件
- TextEntryBox应用
- 格式化文本
- 过滤输入
- 验证数据
- 有关密码的问题
- 共享数据模型
- 自由地使用HTML和RTF
- 自行管理文本
- 焦点导航
- 树 & 18.2.2 节点和模型
- 保存树 & 18.2.4 树事件 & 18.2.5 一个完整的例子
- 表 & 18.3.1 第一步:不劳而获
- 第二步:创建一个表模型
- 第三步:一个简单的电子表格应用
- 可插拔观感
- 创建定制组件 & 18.6.1 生成事件
- Dial组件
- 模型和视图分离
- 布局管理器
- FlowLayout & 19.2 GridLayout
- BorderLayout
- BoxLayout
- CardLayout
- GridBagLayout
- GridBagConstraints类
- 表格坐标
- 填充约束 & 19.6.4 行跨度和列跨度
- 锚定 & 19.6.7 间距和边距
- 相对定位
- 组合布局
- 非标准布局管理器 & 19.8 绝对定位
- 使用2D API 绘图 & 整体结构
- 表现通道
- D API快速浏览 & 20.3.1 填充形状
- 绘制形状轮廓 & 20.3.3 便利方法
- 绘制文本 & 20.3.5 绘制图像
- 完整的Iguana
- 填充形状 & 20.4.1 纯色
- 颜色渐变 & 20.4.3 纹理
- 桌面颜色
- 描画形状轮廓 & 20.6 使用字体
- 显示图像
- Image类
- 图像观察者
- 缩放和大小
- 绘制技术
- 使用剪裁的有限绘制
- 屏幕外绘制
- 使用图像及其他媒体 & Loading Images
- ImageObserver
- MediaTracker
- ImageIcon & 21.1.4 ImageIO
- 生成图像数据 & 21.2.1 绘制动画
- BufferedImage剖析
- 颜色模型
- 创建图像
- 更新BufferedImage
- 过滤图像数据
- ImageProcessor如何工作 & 21.3.2 将Image转换为BufferedImage
- 使用RescaleOp类 & 21.3.4 使用Affine TransformOp类
- 保存图像数据 & 21.5 简单音频
- Java媒体框架
- JavaBeans
- 什么是Bean
- The NetBeans IDE
- 特性和定制器
- 事件关联和适配器 & 22.4.1 控制Juggler
- 分子运动
- 绑定特性
- 构建Bean & 22.6.1 The Dial Bean
- 特性的设计模式
- 可视化设计的限制 & 22.8 串行化与代码生成
- 使用BeanInfo进行定制
- 用手写代码使用Bean & 22.10.1 Bean实例化和类型管理
- 使用串行化Bean
- 使用反射完成运行时事件关联
- BeanContext和BeanContextService & 22.12 Java激活框架
- Enterprise JavaBeans和POJO-Based Enterprise Frameworks
- Applets
- 基于浏览器的应用的政治
- Applet支持和Java插件 & 23.3 JApplet类
- Applet生命期
- Applet安全沙箱
- 获得Applet资源
- 标签 & 23.3.5 属性
- 参数 & 23.3.7 Applet的替代品
- 完整的标签
- 加载类文件 & 23.3.10 包
- 查看applet & 23.4 Java Web Start
- XML & 本章主题
- 背景知识点拨 & 24.2.1 文本与二进制
- 通用解析器 & 24.2.3 XML的状态
- The XML APIs & 24.2.5 XML和Web浏览器
- XML基础 & 24.3.1 属性
- XML文档 & 24.3.3 编码
- 命名空间
- 验证 & 24.3.6 HTML向XHTML的转换
- The SAX API
- 使用SAX构建模型
- XML编码器/ 解码器
- DOM API
- 试验DOM
- 用DOM生成XML
- JDOM & 24.6 XPath
- XPath API
- XMLGrep & 24.7 XInclude
- 验证文档
- 使用文档验证 & 24.8.2 DTDs
- XML Schema
- 验证API
- JAXB和代码生成
- 注解我们的模型
- 从一个XML架构生成一个Java模型 & 24.9.3 从Java模型生成一个XML架构
- 用XSL/XSLT转换文档
- XSL基础知识
- 转换动物园名册
- XSLTransform
- 浏览器中的XSL & 24.11 Web服务
- 本书的结尾 & 附录A Eclipse IDE
- 附录B BeanShell:简单Java脚本
- 封面介绍 & 欢迎来到异步社区!
- Preface
- Introduction to Docker
- Networking and Persistent Storage
- Working with Microservices
- Creating Java Microservices
- Introduction to REST
- REST in Java
- Coding the Spring Boot microservice
- Running the application
- Making calls
- Spring Initializr
- Summary
- Creating Images with Java Applications
- Dockerfile
- Dockerfile instructions
- Summary
- Running Containers with Java Applications
- Starting and stopping containers
- Container running modes
- Monitoring containers
- Restart policies
- Runtime constraints on resources
- Running with Maven
- Summary
- Introduction to Kubernetes
- Using Kubernetes with Java
- Working with the Kubernetes API
- Deploying Java on Kubernetes in the Cloud
- More Resources
- Preface
- I. Reactive and Quarkus Introduction & 1. Reactive in a Nutshell
- 2. Introduction to Quarkus
- Java on the Cloud
- The Quarkus Way
- Create Your First Quarkus Application
- Kubernetes with Quarkus in Minutes
- Going Native
- Summary
- II. Reactive and Event-Driven Applications & 3. The Dark Side of Distributed Systems
- 4. Design Principles of Reactive Systems
- Reactive Systems
- Commands and Events
- Destinations and Space Decoupling
- Time Decoupling
- The Role of Nonblocking Input/Output
- Anatomy of Reactive Applications
- Summary
- 5. Reactive Programming: Taming the Asynchronicity
- Asynchronous Code and Patterns
- Using Futures
- Project Loom: Virtual Threads and Carrier Threads
- Reactive Programming
- Reactive Streams and the Need for Flow Control
- Summary
- III. Building Reactive Applications and Systems with Quarkus & 6. Quarkus: Reactive Engine
- 7. Mutiny: An Event-Driven Reactive Programming API
- Why Another Reactive Programming Library?
- What Makes Mutiny Unique?
- Mutiny Usage in Quarkus
- Uni and Multi
- Mutiny and Flow Control
- Observing Events
- Transforming Events
- Chaining Asynchronous Actions
- Recovering from Failure
- Combining and Joining Items
- Selecting Items
- Collecting Items
- Summary
- 8. HTTP with Reactive in Mind
- The Journey of an HTTP Request
- Say Hello to RESTEasy Reactive!
- What’s the Benefit?
- Asynchronous Endpoints Returning Uni
- Dealing with Failure and Customizing the Response
- Streaming Data
- Reactive Score
- Summary
- 9. Accessing Data Reactively
- The Problem with Data Access
- Nonblocking Interactions with Relational Databases
- Using a Reactive ORM: Hibernate Reactive
- What About NoSQL?
- Interacting with Redis
- Data-Related Events and Change Data Capture
- Using Debezium to Capture Change
- Summary
- IV. Connecting the Dots & . Reactive Messaging: The Connective Tissue
- . The Event Bus: The Backbone
- Kafka or AMQP: Picking the Right Tool
- Building Reactive Systems with Kafka
- Building Reactive Systems with AMQP
- Summary
- . Reactive REST Client: Connecting with HTTP Endpoints
- Interacting with an HTTP Endpoint
- The REST Client Reactive
- Blocking and Nonblocking
- Handling Failures
- Building API Gateways with the RESTEasy Reactive Client
- Using the REST Client in Messaging Applications
- Summary
- . Observing Reactive and Event-Driven Architectures
- Why Is Observability Important?
- Health with Messaging
- Metrics with Messaging
- Distributed Tracing with Messaging
- Summary
- Conclusion
- Index
- Cover & About the Author
- Title Page & Copyright Page
- Contents at a Glance
- Contents
- Preface
- For Further Study & Part I The Java Language
- Part II The Java Library
- Chapter String Handling
- Chapter Exploring java.lang
- Chapter java.util Part 1: The Collections Framework
- Chapter java.util Part 2: More Utility Classes
- Chapter Input/Output: Exploring java.io
- Chapter Exploring NIO
- Chapter Networking
- Chapter Event Handling
- Chapter Introducing the AWT: Working with Windows, Graphics, and Text
- Chapter Using AWT Controls, Layout Managers, and Menus
- Chapter Images
- Chapter The Concurrency Utilities
- Chapter The Stream API
- Chapter Regular Expressions and Other Packages
- Part III Introducing GUI Programming with Swing & Chapter Introducing Swing
- Chapter Exploring Swing
- Chapter Introducing Swing Menus
- Part IV Applying Java
- Part V Appendixes
- Index
- Java体系结构
- 认识Java
- Java重要概念
- 安装与配置Java运行环境
- Java技术的新特性
- 实战:玩转OpenJDK
- 本章小结
- 字节码的编译原理
- javac编译器简介
- 词法解析步骤
- 语法解析步骤
- 语义解析步骤
- 生成字节码 & 2.6 实战:使用javap工具分析字节码
- 实战:使用GCJ编译器将Java源码直接编译为本地机器指令
- 本章小结
- 字节码文件
- 字节码文件的内部组成结构
- 符号引用
- 本章小结
- 剖析HotSpot的Launcher
- Launcher简介
- 跟踪Launcher的执行过程
- 实战:在Launcher中添加自定义函数模块
- 本章小结
- 剖析HotSpot的初始化过程
- HotSpot的构成模块
- Prims模块
- Runtime模块
- 跟踪HotSpot的初始化过程
- 本章小结
- 内存分配与垃圾回收
- JVM的运行时内存区结构
- 线程共享内存区
- 线程私有内存区
- 性能监控区 & 6.5 自动内存管理
- 垃圾收集器
- 实战:GC日志分析
- 实战:分析dump文件
- 本章小结
- 类加载机制
- 类加载器
- 类的加载过程
- 实战:字节码文件的加密与解密
- 本章小结
- 剖析HotSpot的架构模型与执行引擎
- 栈帧的组成结构
- HotSpot中执行引擎的架构模型
- 解释器与JIT编译器
- 本章小结
- 附录A Java7新增语法特性
- 附录B 指令助记符
- Credits & About the Author
- About the Reviewers
- www.PacktPub.com
- Preface
- 1 Introduction to NLP
- What is NLP?
- Why use NLP?
- Why is NLP so hard?
- Survey of NLP tools
- Overview of text processing tasks
- Understanding NLP models
- Preparing data
- Summary
- 2 Finding Parts of Text
- Understanding the parts of text
- What is tokenization?
- Simple Java tokenizers
- NLP tokenizer APIs
- Understanding normalization
- Summary
- 3 Finding Sentences
- The SBD process
- What makes SBD difficult?
- Understanding SBD rules of LingPipe’s HeuristicSentenceModel class
- Simple Java SBDs
- Using NLP APIs
- Training a Sentence Detector model
- Summary
- 4 Finding People and Things
- Why NER is difficult?
- Techniques for name recognition
- Using regular expressions for NER
- Using NLP APIs
- Training a model
- Summary
- 5 Detecting Part of Speech
- The tagging process
- Using the NLP APIs
- Summary
- 6 Classifying Texts and Documents
- How classification is used
- Understanding sentiment analysis
- Text classifying techniques
- Using APIs to classify text
- Summary
- 7 Using Parser to Extract Relationships
- Relationship types
- Understanding parse trees
- Using extracted relationships
- Extracting relationships
- Using NLP APIs
- Extracting relationships for a question-answer system
- Summary
- 8 Combined Approaches
- Preparing data
- Pipelines
- Creating a pipeline to search text
- Summary
- Index
- 关于本书
- 本书结构
- 代码惯例和下载 & 作者在线
- 关于封面图
- 基础知识
- 为什么要关心Java 8
- Java怎么还在变
- Java在编程语言生态系统中的位置
- 用行为参数化把代码传递给方法
- 并行与共享的可变数据
- Java需要演变
- Java中的函数
- 方法和Lambda作为一等公民
- 传递代码:一个例子
- 从传递方法到Lambda
- 多线程并非易事
- 默认方法
- 来自函数式编程的其他好思想
- 通过行为参数化传递代码
- 应对不断变化的需求 & 2.1.1 初试牛刀:筛选绿苹果
- 再展身手:把颜色作为参数
- 第三次尝试:对你能想到的每个属性做筛选
- 行为参数化
- 第四次尝试:根据抽象条件筛选
- 对付啰嗦
- 匿名类 & 2.3.2 第五次尝试:使用匿名类
- 第六次尝试:使用Lambda表达式 & 2.3.4 第七次尝试:将List类型抽象化
- 用Runnable执行代码块 & 2.4.3 GUI事件处理
- Lambda表达式
- Lambda管中窥豹
- 在哪里以及如何使用Lambda & 3.2.1 函数式接口
- 函数描述符
- 把Lambda付诸实践:环绕执行模式
- 第1步:记得行为参数化 & 3.3.2 第2步:使用函数式接口来传递行为
- 第3步:执行一个行为
- 第4步:传递Lambda & 3.4 使用函数式接口
- Predicate
- Consumer
- Function
- 类型检查、类型推断以及限制 & 3.5.1 类型检查
- 同样的Lambda,不同的函数式接口
- 类型推断
- 使用局部变量
- 方法引用 & 3.6.1 管中窥豹
- 构造函数引用
- Lambda和方法引用实战 & 3.7.1 第1步:传递代码
- 第2步:使用匿名类 & 3.7.3 第3步:使用Lambda表达式
- 第4步:使用方法引用 & 3.8 复合Lambda表达式的有用方法
- 比较器复合
- 谓词复合
- 函数复合
- 数学中的类似思想 & 3.9.1 积分
- 与Java 8的Lambda联系起来
- 函数式数据处理
- 流是什么
- 流与集合
- 只能遍历一次
- 外部迭代与内部迭代
- 流操作 & 4.4.1 中间操作
- 终端操作
- 筛选和切片 & 5.1.1 用谓词筛选 & 5.1.2 筛选各异的元素
- 截短流 & 5.1.4 跳过元素
- 映射 & 5.2.1 对流中每一个元素应用函数
- 流的扁平化
- 查找和匹配 & 5.3.1 检查谓词是否至少匹配一个元素 & 5.3.2 检查谓词是否匹配所有元素
- 查找元素
- 查找第一个元素
- 归约 & 5.4.1 元素求和
- 最大值和最小值
- 付诸实践 & 5.5.1 领域:交易员和交易
- 原始类型流特化
- 数值范围
- 数值流应用:勾股数
- 构建流 & 5.7.1 由值创建流 & 5.7.2 由数组创建流
- 由文件生成流
- 由函数生成流:创建无限流
- 用流收集数据
- 收集器简介 & 6.1.1 收集器用作高级归约
- 预定义收集器 & 6.2 归约和汇总
- 查找流中的最大值和最小值
- 连接字符串
- 广义的归约汇总
- 多级分组
- 按子组收集数据
- 分区的优势
- 将数字按质数和非质数分区
- 收集器接口
- 理解Collector接口声明的方法
- 全部融合到一起
- 开发你自己的收集器以获得更好的性能
- 仅用质数做除数
- 比较收集器的性能
- 并行数据处理与性能
- 测量流性能
- 正确使用并行流
- 高效使用并行流
- 分支/合并框架 & 7.2.1 使用RecursiveTask
- 使用分支/合并框架的最佳做法
- 工作窃取
- Spliterator
- 拆分过程
- 实现你自己的Spliterator
- 高效Java 8编程
- 重构、测试和调试 & 为改善可读性和灵活性重构代码
- 改善代码的可读性 & 8.1.2 从匿名类到Lambda表达式的转换
- 从Lambda表达式到方法引用的转换
- 从命令式的数据处理切换到Stream
- 增加代码的灵活性
- 使用Lambda重构面向对象的设计模式
- 策略模式
- 模板方法
- 观察者模式
- 责任链模式
- 工厂模式
- 测试Lambda表达式
- 测试可见Lambda函数的行为
- 测试使用Lambda的方法的行为
- 将复杂的Lambda表达式分到不同的方法 & 8.3.4 高阶函数的测试
- 调试 & 8.4.1 查看栈跟踪
- 使用日志调试
- 默认方法
- 不断演进的API
- 初始版本的API
- 第二版API
- 概述默认方法
- 默认方法的使用模式 & 9.3.1 可选方法
- 行为的多继承
- 解决冲突的规则
- 解决问题的三条规则 & 9.4.2 选择提供了最具体实现的默认方法的接口
- 冲突及如何显式地消除歧义
- 菱形继承问题
- 用Optional取代null
- 如何为缺失的值建模
- 采用防御式检查减少NullPointerException
- null带来的种种问题 & 10.1.3 其他语言中null的替代品
- Optional类入门
- 应用Optional的几种模式 & 10.3.1 创建Optional对象
- 使用map从Optional对象中提取和转换值
- 使用flatMap链接Optional对象
- 默认行为及解引用Optional对象
- 两个Optional对象的组合
- 使用filter剔除特定的值
- 使用Optional的实战示例 & 10.4.1 用Optional封装可能为null的值
- 异常与Optional的对比
- 把所有内容整合起来
- CompletableFuture:组合式异步编程
- Future接口
- Future接口的局限性
- 使用CompletableFuture构建异步应用
- 实现异步API
- 将同步方法转换为异步方法
- 错误处理
- 让你的代码免受阻塞之苦
- 使用并行流对请求进行并行操作
- 使用CompletableFuture发起异步请求
- 寻找更好的方案
- 使用定制的执行器
- 对多个异步任务进行流水线操作
- 实现折扣服务
- 使用Discount服务
- 构造同步和异步操作
- 将两个CompletableFuture对象整合起来,无论它们是否存在依赖
- 对Future和CompletableFuture的回顾
- 响应CompletableFuture的completion事件
- 对最佳价格查询器应用的优化
- 付诸实践
- 新的日期和时间API
- LocalDate、LocalTime、Instant、Duration以及Period & 12.1.1 使用LocalDate和LocalTime
- 合并日期和时间
- 机器的日期和时间格式
- 定义Duration或Period
- 操纵、解析和格式化日期
- 使用TemporalAdjuster
- 打印输出及解析日期-时间对象
- 处理不同的时区和历法
- 利用和UTC/格林尼治时间的固定偏差计算时区
- 使用别的日历系统
- 超越Java 8
- 函数式的思考 & 实现和维护系统
- 共享的可变数据
- 声明式编程
- 为什么要采用函数式编程 & 13.2 什么是函数式编程
- 函数式Java编程
- 引用透明性
- 面向对象的编程和函数式编程的对比
- 函数式编程实战
- 递归和迭代
- 函数式编程的技巧 & 无处不在的函数
- 高阶函数
- 持久化数据结构 & 14.2.1 破坏式更新和函数式更新的比较
- 另一个使用Tree的例子
- 采用函数式的方法
- Stream的延迟计算 & 14.3.1 自定义的Stream
- 创建你自己的延迟列表
- 模式匹配
- 访问者设计模式
- 用模式匹配力挽狂澜
- 杂项 & 14.5.1 缓存或记忆表
- “返回同样的对象”意味着什么
- 面向对象和函数式编程的混合:Java 8和Scala的比较
- Scala简介 & 15.1.1 你好,啤酒
- 基础数据结构:List、Set、Map、Tuple、Stream以及Option
- 函数 & 15.2.1 Scala中的一等函数
- 匿名函数和闭包
- 类和trait & 15.3.1 更加简洁的Scala类
- Scala的trait与Java 8的接口对比
- 结论以及Java的未来 & 回顾Java 8的语言特性
- 行为参数化(Lambda以及方法引用)
- CompletableFuture
- Optional
- 默认方法 & 16.2 Java的未来
- 类型系统的改进
- 模式匹配
- 更加丰富的泛型形式
- 对不变性的更深层支持
- 写在最后的话 & 附录 A 其他语言特性的更新
- A.1 注解
- A. 重复注解
- A. 类型注解
- A.2 通用目标类型推断
- 附录 B 类库的更新 & B.1 集合 & B. 其他新增的方法
- B. Collections类 & B.1.3 Comparator
- B.2 并发 & B. 原子操作
- B. ConcurrentHashMap
- B.3 Arrays & B. 使用parallelSort & B.3.2 使用setAll和parallelSetAll & B.3.3 使用parallelPrefix
- B.4 Number和Math & B. Number
- B. Math & B.5 Files
- B.6 Reflection & B.7 String & 附录 C 如何以并发方式在同一个流上执行多种操作
- C.1 复制流
- C. 使用ForkingStreamConsumer实现Results接口
- C. 开发ForkingStreamConsumer和BlockingQueueSpliterator
- C. 将StreamForker运用于实战
- C.2 性能的考量 & 附录 D Lambda表达式和JVM字节码 & D.1 匿名类
- D.2 生成字节码
- D.3 用InvokeDynamic力挽狂澜
- D.4 代码生成策略
- Java与Java Web
- 分析Java堆
- Java编程基础
- Java异常处理
- Java数据库连接
- Java 8 Nashorn 教程
- Java 8 简明教程
- Java 8 数据流教程
- 在 Java 8 中避免 Null 检查
- Java 8 并发教程:同步和锁
- 结合Scala和Java
- Java 8 并发教程:线程和执行器
- Java 8 并发教程:原子变量和 ConcurrentMap
- 对象数组
- 数组对象
- NLP简介
- 文本分词
- 文本断句
- 人物识别
- 词性判断
- 文本分类
- 关系提取
- 方法组合
- Java + SQL Server实现企业进销存管理系统
- 使用 Intellij IDEA 解决 Java 8 的数据流问题
- Java 8 API 示例:字符串、数值、算术和文件
- Struts2基础
- Hibernate技术
- Struts2高级技术
- Hibernate高级应用
- 网络通信
- Spring核心之IoC
- Spring核心之AOP
- SpringCloudConfig
- SpringCloudStream
- SpringCloudSleuth
- 输入输出流
- 抽象和封装
- 继承和多态
- Eureka注册服务
- SpringCloud服务组件
- OAuth认证管理
- RabbitMQ消息组件
- 锁与并发
- Class文件结构
- Class装载系统
- 字节码执行
- Docker虚拟化容器
- 包含其他对象的对象
- Spring Boot启动源码解析
- 微服务注册与发现
- 微服务配置管理
- 微服务进程间通信
- 微服务降级容错
- 微服务日志系统
- 微服务全链路追踪系统
- 微服务持续集成与持续部署系统
- SSM框架整合开发
- 九宫格记忆网
- Java编程基础
- Java中的运算符和表达式
- 常用算法
- 抽象和封装
- 继承和多态
- 常用类介绍
- 应用实例
- AWT与Swing
- 布局管理器
- Swing GUI常用组件
- 事件处理
- GUI项目实践
- Java数据库连接
- JDBC概述
- JDBC应用实例
- Java异常处理
- 输入输出流
- 网络通信
- Java与Java Web
- 参考文献
- Java入门
- MyEclipse的基本使用
- Java基础语法
- 数组的应用
- 面向对象的Java编程
- 接口与内部类
- 集合的应用
- 异常和反射
- 初识AWT和Swing
- Swing中的常用组件
- 登录案例(文本框和密码框)
- 记事本的多行文本区(文本区和滚动条)
- 记事本菜单栏测试(菜单)
- 记事本工具栏(工具栏)
- 点菜对话框(对话框)
- 文件和颜色选择器
- 滑块和进度条
- 下拉列表框
- 微调控制器
- 编辑器面板
- I/O流
- Swing中的表格
- 网络编程
- JDBC数据库开发
- JDBC简介及使用MyEclipse连接数据库
- JDBC查询数据库
- 预编译语句
- 事务(Transaction)
- 可滚动结果集
- 银行访问系统
- MyEclipse开发MyQQ项目
- Java脚本开发
- 光盘内容
- 相关书籍
- Safari® Books Online
- Java 介绍
- Java 环境介绍 & Java语言、JVM和生态系统
- Java语言是什么
- JVM是什么
- Java生态系统是什么 & 1.2 Java和JVM简史
- Java的安全性
- Java和其他语言比较 & 1.5.1 Java和C语言比较 & 1.5.2 Java和C++比较 & 1.5.3 Java和PHP比较 & 1.5.4 Java和JavaScript比较
- 回应对Java的一些批评 & 1.6.1 过度复杂
- 太注重企业
- Java 基本句法
- 整数类型
- 浮点数类型
- 运算符概述
- 算术运算符
- 比较运算符
- 逻辑运算符
- 赋值运算符
- 条件运算符
- instanceof操作符
- 特殊运算符
- if/else语句
- switch语句
- while语句
- do语句 & 2.5.10 for语句
- 遍历语句
- break语句
- continue语句
- return语句
- synchronized语句
- throw语句
- try/catch/finally语句
- assert语句
- 方法修饰符
- 创建对象
- lambda表达式
- 使用数组
- 多维数组
- 比较对象
- 包和Java命名空间
- 导入类型
- Java文件的结构
- Java 面向对象编程 & 类简介 & 3.1.1 面向对象的基本概念
- 字段和方法
- 实例字段
- 实例方法
- 访问控制
- 修饰符总结
- Java 类型系统 & 接口
- 定义接口
- 扩展接口
- 实现接口
- 标记接口
- Java泛型 & 4.2.1 介绍泛型
- 自定义注解
- lambda表达式
- 转换lambda表达式
- Java 的面向对象设计 & Java的值
- toString()方法 & 5.2.2 equals()方法
- hashCode()方法
- Comparable::compareTo()方法
- clone()方法
- Java编程的安全性
- Java 实现内存管理和并发编程的方式 & Java内存管理的基本概念
- Java中的内存泄露
- 筛选回收
- 终结机制
- 终结机制的细节 & Java对并发编程的支持
- volatile关键字
- 使用线程
- 使用 Java 平台
- Java文档注释
- 使用Java集合 & 介绍集合API
- Collection接口
- Set接口
- List接口
- Map接口
- Queue接口和BlockingQueue接口
- 实用方法
- 在Java集合框架中使用lambda表达式
- 函数式方式
- 流API
- 正则表达式
- 数字和数学运算 & 9.2.1 Java表示整数类型的方式
- Java中的浮点数
- Java的数学函数标准库
- 在Java 8中处理日期和时间 & 9.3.1 介绍Java 8的日期和时间API
- 处理文件和 I/O & Java处理I/O的经典方式
- Reader和Writer类
- 再次介绍TWR
- I/O经典处理方式的问题 & 10.2 Java处理I/O的现代方式
- HTTP
- 动态代理
- 方法查找
- Nashorn & 介绍Nashorn
- 在JVM中运行Java之外的语言
- Nashorn的高级用法 & 12.4.1 在Nashorn中调用Java代码
- 实现细节
- 小结 & Avatar项目
- javac
- java
- javadoc & 13.1.5 jdeps
- jps & 13.1.7 jstat
- jstatd
- jinfo & 13.1.10 jstack & 13.1.11 jmap
- javap & 13.2 VisualVM
- Java 8配置 & 13.3.1 目的
- 紧凑配置
- 封面介绍
- 开始Java之旅 & 无处不在的Java
- Java为何受大家喜爱
- Java的目标 & 1.4 Java开发环境的搭建 & 1.4.1 JDK的下载与安装
- Java开发环境配置
- 要点总结 & 1.8 练习题
- Java语言的数据类型 & 2.2.1 整数类型
- 浮点类型 & 2.2.3 字符类型 & 2.2.4 布尔类型 & 2.2.5 基本数据类型的默认值 & 2.2.6 类型转换
- 运算符和表达式 & 2.3.1 赋值运算符 & 2.3.2 算术运算符
- 位运算符 & 2.3.4 关系运算符
- 三元运算符 & 2.3.6 运算符优先级 & 2.4 流程控制语句 & 2.4.1 选择语句
- 循环语句
- 数组与方法 & 2.5.1 一维数组
- 二维数组
- 要点总结 & 2.7 编程练习
- Java面向对象编程 & 理解面向对象 & 3.1.1 基本概念 & 3.1.2 基本特性
- 类与对象 & 3.2.1 类定义
- 对象的创建及使用
- this和static关键字
- 继承 & 3.3.1 继承的语法和规则
- 重载和覆盖
- super关键字
- final关键字 & 3.4.1 final变量 & 3.4.2 final方法
- final类 & 3.5 抽象类
- 接口 & 3.6.1 接口定义 & 3.6.2 实现接口
- 匿名内部类 & 3.7 包及访问控制权限 & 3.7.1 包的操作
- 访问权限修饰符 & 3.8 对象的多态性
- Object类
- 包装类 & 3.10.1 基本数据类型转换为包装类 & 3.10.2 字符串转换为包装类
- 包装类转换为基本数据类型 & 3.10.4 字符串转换为基本数据类型
- 自动装箱和自动拆箱 & 3.10.6 覆盖父类的方法 & 3.11 String类
- String对象的实例化和内容比较
- String类中的常用方法
- 要点总结 & 3.13 编程练习
- Java异常 & Java中的异常类及分类
- Java异常处理机制
- 捕获处理异常
- 声明抛出异常
- 自定义异常
- 自定义异常的综合应用
- 实例练习:异常的综合应用
- 要点总结 & 4.7 编程练习
- Java线程 & 多线程及线程简介
- 线程的创建
- 线程的状态
- 线程的调度 & 5.5 线程的优先级
- 守护线程
- 线程同步
- 实例练习:线程综合应用
- 要点总结 & 5.10 练习题
- 编程练习
- Java集合框架 & 常用集合接口 & 6.1.1 Collection接口
- List接口
- Set接口 & 6.1.4 Map接口
- Map.Entry接口 & 6.1.6 Iterator接口
- ListIterator接口
- 常用集合类 & 6.2.1 ArrayList类
- LinkedList类
- HashSet类
- HashMap
- 实例练习:集合类的综合运用
- 要点总结 & 6.5 练习题
- 编程练习
- Java IO & File类
- RandomAccessFile类
- 字节流与字符流 & 7.3.1 字节流
- 字节流与字符流的区别
- BufferedReader类和BufferedWriter类
- 数据操作流
- Scanner类 & 7.11 要点总结 & 7.12 编程练习
- Java数据库编程 & JDBC技术 & 8.1.1 JDBC技术简介
- JDBC和ODBC与其他API的比较
- 结构化查询语言 & 8.2.1 SQL简介 & 8.2.2 SELECT语句
- 更新记录
- 聚集函数 & 8.3 JDBC基本操作
- JDBC操作步骤 & 8.3.2 JDBC-ODBC连接数据库
- JDBC直接连接数据库
- JDBC对数据库的更新操作
- JDBC高级操作 & 8.4.1 PreparedStatemen接口
- CallableStatement接口
- 事务处理 & 8.5 要点总结
- 编程练习
- Java网络编程 & 网络基础 & 9.1.1 TCP/IP网络模型
- IP地址与InetAddress类 & 9.1.3 套接字
- DatagramSocket类
- ServerSocket类
- URLConnection类
- 综合实例:实现简单的Web服务器
- 要点总结 & 9.7 练习题
- 编程练习
- Java图形用户界面 & AWT与Swing简介 & 10.1.1 AWT简介
- Swing简介
- 容器简介 & 10.2 创建窗体
- 标签组件:JLabel
- 按钮组件:JButton
- JPanel容器
- 布局管理器 & 10.6.1 FlowLayout
- BorderLayout
- GridLayout
- CardLayout
- 文本组件:JTextComponent & 10.7.1 单行文本框:JTextField
- 密码文本框:JPasswordField
- 多行文本框:JTextArea
- 事件处理 & 10.8.1 事件和监听器
- 窗体事件
- 动作事件及监听处理
- 键盘事件及监听处理
- 鼠标事件及监听处理
- 焦点事件及监听处理
- 单选按钮组件:JRadioButton
- 复选框组件:JCheckBox
- 列表框组件:JList
- 下拉列表框:JComboBox
- 菜单组件:JMenu与JMenuBar
- 文件选择框组件:JFileChooser
- 要点总结 & 10.16 练习题
- Java常用类库 & StringBuffer类
- Runtime类
- System类 & 11.4 Math类
- Random类 & 11.6 要点总结 & 11.7 练习题
- Java项目开发 & 软件开发过程 & 12.1.1 需求
- 分析设计 & 12.1.3 实现和测试
- 项目实例:记事本工具的开发 & 12.2.2 实现和测试
- 项目实例:网络通信工具的开发 & 12.3.1 需求分析设计 & 12.3.2 实现和测试
- 项目实例:在线相册的开发 & 12.4.1 需求分析设计
- 数据库设计
- 开发数据库JavaBean
- 实现和测试
- 要点总结 & 12.6 编程练习
- Java入门
- 数据类型和运算符
- 控制语句
- Java面向对象编程基础
- Java面向对象编程进阶
- 异常机制
- 输入与输出技术
- 多线程技术
- 网络编程
- J飞机游戏项目
- GUI编程——Swing基础
- 事件模型
- Swing中的其他控件
- 反射机制
- 核心设计模式
- 封面 & 扉页 & 内容提要
- 作者简介 & 致谢
- 第1周课程 Java语言
- Java基础
- Java编程基础
- 数组、逻辑和循环
- 创建类和方法
- 包、接口和其他类特性
- 异常、断言和线程
- 第2周课程 Java类库
- 数据结构
- 使用Swing
- 创建Swing界面
- 在用户界面上排列组件
- 响应用户输入
- 使用颜色、字体和图形
- 第3周课程 Java编程
- 输入和输出
- 通过Internet进行通信
- 使用JDBC访问数据库
- 读写RSS Feed
- XML Web服务
- 编写Java servlet和Java Server Page
- Java从入门到精通
- 基础知识
- 核心技术
- 高级应用
- 项目实战
- 附录A JDK7改进的功能
- DVD资源下载链接
- Java经典编程例
- Java语言概述
- Eclipse开发工具
- Java语言基础
- 流程控制
- 数组及其常用操作
- 面向对象入门
- 面向对象进阶
- 字符串与包装类
- Java集合类框架
- 常用数学工具类
- 错误处理
- 输入/输出
- 枚举类型与泛型
- Swing入门
- 网络通信
- 数据库操作
- O’Reilly Media, Inc. 介绍 & 业界评论
- 读者对象
- 排版约定 & 使用代码示例
- Safari® Books Online
- 联系我们
- 概述 & 1.2 平台版本约定
- JVM调优标志
- 全面的性能调优 & 1.3.1 编写更好的算法 & 1.3.2 编写更少的代码
- 老调重弹的过早优化
- 其他:数据库很可能就是瓶颈
- 常见的优化
- 性能测试方法 & :测试真实应用 & 2.1.1 微基准测试
- 宏基准测试
- 介基准测试
- 代码示例
- :理解批处理流逝时间、吞吐量和响应时间 & 2.2.1 批处理流逝时间
- 吞吐量测试
- 响应时间测试
- :用统计方法应对性能的变化
- :尽早频繁测试
- Java 性能调优工具箱 & 操作系统的工具和分析 & 3.1.1 CPU使用率
- CPU运行队列
- 磁盘使用率
- 网络使用率
- Java监控工具
- 基本的VM信息
- 线程信息 & 3.2.3 类信息 & 3.2.4 实时GC分析 & 3.2.5 事后堆转储
- 性能分析工具 & 3.3.1 采样分析器
- 探查分析器
- 阻塞方法和线程时间线
- 本地分析器
- Java任务控制
- Java飞行记录器
- 开启JFR
- 选择JFR事件
- JIT 编译器 & JIT编译器:概览
- 热点编译
- 调优入门:选择编译器类型(Client、Server或二者同用) & 4.2.1 优化启动
- 优化批处理
- 优化长时间运行的应用
- Java和JIT编译器版本
- 编译器中级调优 & 4.4.1 调优代码缓存
- 编译阈值
- 检测编译过程
- 高级编译器调优 & 4.5.1 编译线程
- 逃逸分析
- 逆优化 & 4.6.1 代码被丢弃
- 逆优化僵尸代码
- 分层编译级别
- 垃圾收集入门 & 垃圾收集概述
- 分代垃圾收集器
- GC算法
- 选择GC算法
- GC调优基础 & 5.2.1 调整堆的大小
- 代空间的调整
- 永久代和元空间的调整
- 控制并发
- 自适应调整
- 垃圾回收工具
- 垃圾收集算法 & 理解Throughput收集器
- 堆大小的自适应调整和静态调整
- 理解CMS收集器
- 针对并发模式失效的调优
- CMS收集器的永久代调优
- 增量式CMS垃圾收集
- 理解G1垃圾收集器 & G1垃圾收集器调优
- 高级调优 & 6.4.1 晋升及Survivor空间
- 分配大对象
- AggressiveHeap标志
- 全盘掌控堆空间的大小
- 堆内存最佳实践 & 堆分析
- 堆直方图
- 内存溢出错误
- 减少内存使用 & 7.2.1 减少对象大小
- 延迟初始化
- 不可变对象和标准化对象
- 字符串的保留
- 对象生命周期管理 & 7.3.1 对象重用
- 弱引用、软引用与其他引用
- 原生内存最佳实践 & 内存占用
- 测量内存占用
- 内存占用最小化 & 8.1.3 原生NIO缓冲区
- 原生内存跟踪
- 针对不同操作系统优化JVM & 8.2.1 大页
- 压缩的oop
- 线程与同步的性能 & 线程池与ThreadPoolExecutor
- 设置最大线程数
- 设置最小线程数
- 线程池任务大小
- 设置ThreadPoolExecutor的大小
- ForkJoinPool
- 自动并行化
- 线程同步
- 同步的代价
- 避免同步
- JVM线程调优 & 9.4.1 调节线程栈大小
- 偏向锁 & 9.4.3 自旋锁
- 线程优先级
- 监控线程与锁 & 9.5.1 查看线程 & 9.5.2 查看阻塞线程
- Java EE 性能调优 & Web容器的基本性能
- HTTP会话状态
- EJB会话Bean & 10.3.1 调优EJB对象池
- 调优EJB缓存
- 本地和远程实例
- XML和JSON处理
- 数据大小
- 解析和编组概述
- 选择解析器
- XML验证
- 文档模型
- Java对象模型
- 追踪对象复制
- Java EE网络API & 调整传输数据的大小
- 数据库性能的最佳实践
- 预处理语句和语句池
- JDBC连接池
- 结果集的处理
- 事务处理
- 对JPA的写性能进行优化
- 对JPA的读性能进行优化
- JPA缓存
- JPA的只读实体 & 11.3 小结
- Java SE API 技巧 & 缓冲式I/O
- Java原生接口
- 字符串的性能
- Java集合类API & 12.8.1 同步还是非同步
- 设定集合的大小
- 集合与内存使用效率
- AggressiveOpts标志 & 12.9.1 替代实现
- 其他标志
- Lambda表达式和匿名类
- Lambda表达式与匿名类加载
- 流和过滤器的性能 & 延迟遍历(Lazy Traversal)
- 小结 & 附录 A 性能调优标志摘要 & 作者简介
- 关于封面
- O’Reilly Media, Inc. 介绍
- 编程之道
- 变量和运算符
- 输入和输出
- void 方法
- 条件和逻辑
- 对象数组
- 数组对象
- 包含其他对象的对象
- 附录 A 开发工具
- 附录 B Java 2D 图形
- 附录 C 调试
- 作者简介 & 封面简介
- 入门介绍
- Java虚拟机
- 构建工具
- Spring
- 使用数据库
- 有用的第三方库
- 附录 A Docker
- Java开发入门
- Java编程基础
- 面向对象
- 输入/输出
- 网页开发基础
- Java Web概述
- Servlet基础
- 请求和响应
- JSP技术
- Cookie和Session
- EL表达式和JSTL
- Servlet高级
- jQuery框架
- MySQL和JDBC
- Struts2框架入门
- Struts2的核心配置
- Struts2的拦截器
- Struts2的标签库
- Struts2的OGNL和值栈
- Struts2的文件上传和下载
- Hibernate框架入门
- Hibernate的持久化对象状态和一级缓存
- Hibernate的关联关系映射
- Hibernate的检索方式
- Hibernate的事物处理和二级缓存
- Spring框架入门
- Spring中的Bean
- 面向切面编程(Spring AOP)
- Spring事务管理
- SSH框架整合
- 学生信息管理系统
- 学生信息管理系统
- 作者简介 & 内容简介
- Java语言概述
- Java语言的诞生与发展
- Java语言的特点
- Java语言规范
- Java虚拟机
- 本章小结
- Java语言开发环境
- Java开发工具
- JDK帮助文档下载与安装 & 2.3 JDK的使用
- 本章小结
- Java语言基础
- 数据类型
- 关键字与标识符
- 数据类型转换
- 由键盘输入数据
- 运算符与表达式
- 本章小结
- 流程控制
- 语句与复合语句
- 循环结构
- 循环中的跳转语句
- 本章小结
- 数组与字符串
- 数组的基本概念
- 一维数组
- foreach语句与数组 & 5.4 多维数组
- 本章小结
- 类与对象
- 类的基本概念
- 对象的创建与使用
- 参数的传递
- 匿名对象
- 本章小结
- Java语言类的特性
- 类的私有成员与公共成员
- 方法的重载
- 构造方法
- 静态成员
- 对象的应用
- Java语言的垃圾回收
- 本章小结
- 继承、抽象类、接口和枚举
- 类的继承
- 本章小结
- 异常处理
- 异常处理的基本概念
- 异常处理类
- 异常的处理
- 抛出异常
- 自动关闭资源的try语句
- 自定义异常类
- 本章小结
- Java语言的输入输出与文件处理
- Java语言的输入输出
- 使用InputStream和OutputStream流类
- 使用Reader和Writer流类
- 文件的处理与随机访问
- 本章小结
- 线程的概念
- Java的Thread线程类与Runnable接口
- 多线程的同步控制
- 线程之间的通信
- 本章小结
- 泛型与容器类
- 本章小结
- 注解、反射、内部类、匿名内部类与Lambda表达式
- 反射机制
- 内部类与匿名内部类
- 函数式接口和Lambda表达式
- 方法引用
- 本章小结
- 图形界面设计
- 图形用户界面概述
- 图形用户界面工具包JavaFX
- JavaFX的布局面板
- JavaFX的辅助类
- JavaFX属性绑定
- JavaFX常用控件
- 本章小结
- 事件处理
- Java语言的事件处理机制——委托事件模型
- Java语言的事件类
- 复选框和单选按钮及相应的事件处理
- 文本编辑控件及相应的事件处理 & 15.5 组合框及相应的事件处理
- 为绑定属性添加监听者
- 列表视图控件及相应的事件处理
- 滑动条及相应的事件处理
- 进度条及相应的事件处理
- 菜单设计
- 工具栏设计
- 文件选择对话框
- 颜色选择器
- 本章小结
- 图形坐标系与形状类
- 本章小结
- 关系数据库系统
- JDBC
- 本章小结
- Java网络编程
- 网络基础
- 用Java语言实现底层网络通信
- 本章小结
- 参考文献
- 附录CD
- O’Reilly Media, Inc. 介绍
- 基础知识
- java.util.function 包
- 流式操作
- 比较器与收集器
- 流式操作、lambda表达式与方法引用的相关问题
- Optional类
- 文件I/O
- java.time包
- 并行与并发
- Java 9 新特性
- 附录 A 泛型与Java 8
- 作者简介
- 封面介绍
- Deep Learning: Practical Neural Networks with Java & Table of Contents
- Deep Learning: Practical Neural Networks with Java
- Deep Learning: Practical Neural Networks with Java
- Credits
- Preface
- 1. Java Deep Learning Essentials
- 2. Machine Learning in Java
- 3. Neural Network Programming with Java, Second Edition
- Index
- Java功底篇
- 扎马:看看功底如何
- Java通信,交互就需要通信
- Java并发,你会遇到吗
- 源码基础
- 部分JDBC源码讲解
- 部分Spring源码讲解
- 看源码的一些总结
- 上篇 面试笔试经验技巧篇
- 上篇 面试笔试经验技巧篇
- 面试官箴言
- 面试官箴言
- 面试心得交流
- 面试心得交流
- 企业面试笔试攻略
- 企业面试笔试攻略
- 下篇 面试笔试技术攻克篇
- 下篇 面试笔试技术攻克篇
- Java基础知识
- Java Web
- 数据库原理
- 设计模式
- 数据结构与算法
- 海量数据处理
- Chapter 1. Introduction
- Part I: Fundamentals & Chapter 2. Thread Safety
- Chapter 3. Sharing Objects
- Chapter 4. Composing Objects
- Chapter 5. Building Blocks
- Part II: Structuring Concurrent Applications & Chapter 6. Task Execution
- Chapter 7. Cancellation and Shutdown
- Chapter 8. Applying Thread Pools
- Chapter 9. GUI Applications
- Part III: Liveness, Performance, and Testing & Chapter . Avoiding Liveness Hazards
- Chapter . Performance and Scalability
- Chapter . Testing Concurrent Programs
- Part IV: Advanced Topics & Chapter . Explicit Locks
- Chapter . Building Custom Synchronizers
- Chapter . Atomic Variables and Nonblocking Synchronization
- Chapter . The Java Memory Model
- 封面 & 扉页 & 内容提要 & 关于作者
- Java之旅
- 使用字符串来交流
- 使用条件测试进行判断
- 使用循环重复执行操作
- 使用数组存储信息
- 创建第一个对象
- 描述对象
- 充分利用现有对象
- 创建简单的用户界面
- 用户界面的布局
- 响应用户输入
- 创建复杂的用户界面
- 读写文件
- 读写XML数据
- 利用JAX-WS开发Web服务
- 创建Java2D图形
- 编写Android app
- 附录A 使用NetBeans IDE
- 附录B Java资源
- 附录C 本书站点
- 附录D 设置Android开发环境
- 读写文件
- 读写XML数据
- 利用JAX-WS开发Web服务
- 创建Java2D图形
- 编写Android app
- Android简介
- 创建 Android app
- 运行app
- 设计真实的app
- 附录A 使用NetBeans IDE
- 附录B Java资源
- 附录C 本书站点
- 附录D 设置Android开发环境
- 面向对象开发方法概述
- 结构化的软件开发方法简介
- 面向对象的软件开发方法简介 & 1.2.1 对象模型
- UML:可视化建模语言 & 1.2.3 Rational Rose:可视化建模工具
- 面向对象开发中的核心思想和概念 & 1.3.1 问题领域、对象、属性、状态、行为、方法、实现
- 类、类型
- 消息、服务
- 封装、透明
- 继承、扩展、覆盖
- 多态、动态绑定
- UML语言简介
- 协作图 & 1.4.5 状态转换图
- 部署图 & 1.5 类之间的关系 & 1.5.1 关联(Association)
- 依赖(Dependency) & 1.5.3 聚集(Aggregation)
- 泛化(Generalization) & 1.5.5 实现(Realization) & 1.5.6 区分依赖、关联和聚集关系
- 实现Panel系统
- 扩展Panel系统
- 用配置文件进一步提高Panel系统的可维护性
- 运行Panel系统 & 1.7 小结
- 第一个Java应用
- 创建Java源文件
- Java源文件结构 & 2.1.2 包声明语句
- 包引入语句
- 方法的声明
- 给main()方法传递参数 & 2.1.7 注释语句
- 标识符 & 2.1.10 编程规范
- 用JDK管理Java应用
- JDK简介以及安装方法
- 编译Java源文件
- 给Java应用打包
- 使用和创建JavaDoc文档
- JavaDoc标记
- javadoc命令的用法
- 数据类型和变量
- 基本数据类型 & 3.1.1 boolean类型
- byte、short、int和long类型
- char类型与字符编码
- float和double类型
- 引用类型
- 基本类型与引用类型的区别
- 用new关键字创建对象
- 变量的作用域
- 实例变量和静态变量的生命周期
- 局部变量的生命周期
- 成员变量和局部变量同名
- 将局部变量的作用域最小化
- 对象的默认引用:this
- 参数传递
- 变量的初始化以及默认值 & 3.6.1 成员变量的初始化
- 局部变量的初始化
- 直接数 & 3.7.1 直接数的类型
- 直接数的赋值
- 操作符简介
- 整型操作符 & 4.2.1 一元整型操作符
- 二元整型操作符
- 浮点型操作符
- 比较操作符和逻辑操作符
- 特殊操作符“?:”
- 字符串连接操作符“+”
- 操作符“”与对象的equals()方法 & 4.7.1 操作符“”
- 对象的equals()方法
- instanceof操作符
- 变量的赋值和类型转换
- 基本数据类型转换
- 引用类型的类型转换
- 流程控制
- 分支语句 & 5.1.1 if else语句
- switch语句
- 循环语句 & 5.2.1 while语句
- do while语句
- for语句
- foreach语句
- 多重循环 & 5.3 流程跳转语句
- 综合例子:八皇后问题
- 小结 & 5.6 思考题
- 继承的基本语法
- 方法重载(Overload)
- 方法覆盖(Override)
- 方法覆盖与方法重载的异同
- super关键字
- 继承的利弊和使用原则 & 6.7.1 继承树的层次不可太多 & 6.7.2 继承树的上层为抽象层
- 继承关系最大的弱点:打破封装
- 精心设计专门用于被继承的类
- 区分对象的属性与继承
- 比较组合与继承 & 6.8.1 组合关系的分解过程对应继承关系的抽象过程
- 组合关系的组合过程对应继承关系的扩展过程
- Java语言中的修饰符
- 访问控制修饰符
- abstract修饰符
- final修饰符 & 7.3.1 final类
- final方法
- final变量
- static修饰符 & 7.4.1 static变量
- static方法
- static代码块
- 用static进行静态导入
- 接口的概念和基本特征
- 比较抽象类与接口
- 与接口相关的设计模式 & 8.3.1 定制服务模式
- 适配器模式
- 默认适配器模式
- 代理模式
- 标识类型模式
- 常量接口模式
- 异常处理
- Java异常处理机制概述 & 9.1.1 Java异常处理机制的优点
- Java虚拟机的方法调用栈
- 异常处理对性能的影响 & 9.2 运用Java异常处理机制 & 9.2.1 try-catch语句:捕获异常
- finally语句:任何情况下必须执行的代码
- throws子句:声明可能会出现的异常
- throw语句:抛出异常
- 异常处理语句的语法规则
- 异常流程的运行过程
- 跟踪丢失的异常
- Java异常类
- 运行时异常
- 受检查异常(Checked Exception) & 9.3.3 区分运行时异常和受检查异常
- 用户定义异常
- 异常转译和异常链
- 处理多样化异常
- 异常处理原则 & 9.5.1 异常只能用于非正常情况
- 为异常提供说明文档 & 9.5.3 尽可能地避免异常
- 保持异常的原子性
- 避免过于庞大的try代码块 & 9.5.6 在catch子句中指定具体的异常类型
- 不要在catch代码块中忽略被捕获的异常
- 记录日志
- 创建Logger对象及设置日志级别
- 生成日志
- 把日志输出到文件
- 设置日志的输出格式
- 使用断言
- 类的生命周期
- 类的加载
- 类的验证
- 类的准备 & 10.2.4 类的解析
- 类的初始化
- 类的初始化的时机
- 类加载器
- 类加载的父亲委托机制
- 创建用户自定义的类加载器
- URLClassLoader类
- 类的卸载
- 对象的生命周期 & 创建对象的方式
- 构造方法
- 重载构造方法
- 默认构造方法
- 子类调用父类的构造方法
- 构造方法的作用域
- 构造方法的访问级别
- 静态工厂方法
- 不可变(immutable)类与可变类
- 具有实例缓存的不可变类
- 松耦合的系统接口
- 垃圾回收
- 对象的可触及性
- 垃圾回收的时间
- 对象的finalize()方法简介 & 11.4.4 对象的finalize()方法的特点
- 比较finalize()方法和finally代码块
- 清除过期的对象引用
- 对象的强、软、弱和虚引用
- 内部类的基本语法
- 实例内部类
- 静态内部类
- 局部内部类
- 内部类的继承
- 子类与父类中的内部类同名
- 内部接口以及接口中的内部类
- 内部类的用途 & 12.6.1 封装类型
- 直接访问外部类的成员
- 内部类的类文件
- Java线程的运行机制
- 线程的创建和启动 & 13.2.1 扩展java.lang.Thread类
- 实现Runnable接口
- 线程的状态转换 & 13.3.1 新建状态 & 13.3.2 就绪状态 & 13.3.3 运行状态 & 13.3.4 阻塞状态
- 死亡状态
- 线程调度
- 调整各个线程的优先级
- 线程睡眠:Thread.sleep()方法
- 线程让步:Thead.yield()方法
- 等待其他线程结束:join()
- 获得当前线程对象的引用
- 后台线程
- 线程的同步
- 同步代码块
- 线程同步的特征
- 同步与并发
- 线程安全的类
- 释放对象的锁
- 线程通信
- 中断阻塞
- 线程控制 & 13.11.1 被废弃的suspend()和resume()方法
- 被废弃的stop()方法 & 13.11.3 以编程的方式控制线程
- 处理线程未捕获的异常
- ThreadLocal类
- concurrent并发包 & 13.15.1 用于线程同步的Lock外部锁
- 用于线程通信的Condition条件接口
- 支持异步计算的Callable接口和Future接口
- 通过线程池来高效管理多个线程
- BlockingQueue阻塞队列
- 数组变量的声明 & 14.2 创建数组对象
- 访问数组的元素和长度
- 数组的初始化
- 多维数组以及不规则数组
- 调用数组对象的方法
- 把数组作为方法参数或返回值
- 数组的二分查找算法
- 数组实用类:Arrays
- 用符号“…”声明数目可变参数
- Java集合
- Collection和Iterator接口
- 集合中直接加入基本类型数据
- Set(集) & 15.3.1 Set的一般用法
- HashSet类
- TreeSet类
- List(列表) & 15.4.1 访问列表的元素
- ListIterator接口
- 获得固定长度的List对象
- 比较Java数组和各种List的性能
- Queue(队列)
- Deque(双向队列)
- PriorityQueue(优先级队列)
- Map(映射)
- HashSet和HashMap的负载因子
- 集合实用类:Collections
- 线程安全的集合
- 集合与数组的互换
- 集合的批量操作
- 历史集合类
- 枚举类型
- 枚举类型的构造方法
- EnumSet类和EnumMap类
- 泛型 & Java集合的泛型
- 定义泛型类和泛型接口
- 用extends关键字限定类型参数
- 定义泛型数组
- 定义泛型方法
- 使用“?”通配符
- 使用泛型的注意事项
- 小结 & 16.9 思考题
- Lambda表达式
- Lambda表达式的基本用法
- 用Lambda表达式代替内部类
- Lambda表达式和集合的forEach()方法
- Lambda表达式与Stream API联合使用
- Lambda表达式可操纵的变量作用域
- Lambda表达式中的方法引用
- 函数式接口(FunctionalInterface)
- 总结Java语法糖
- 小结 & 17.11 思考题
- 输入与输出(I/O)
- 输入流和输出流概述
- 输入流 & 18.2.1 字节数组输入流:ByteArrayInputStream类
- 文件输入流:FileInputStream类
- 管道输入流:PipedInputStream
- 过滤输入流:FilterInputStream & 18.3.1 装饰器设计模式
- 过滤输入流的种类 & 18.3.3 DataInputStream类
- BufferedInputStream类
- PushbackInputStream类 & 18.4 输出流
- 字节数组输出流:ByteArrayOutputStream类
- 文件输出流:FileOutputStream & 18.5 过滤输出流:FilterOutputStream
- DataOutputStream & 18.5.2 BufferedOutputStream
- PrintStream类
- Reader/Writer概述
- Reader类
- 字符数组输入流:CharArrayReader类
- 字符串输入流:StringReader类
- InputStreamReader类
- FileReader类 & 18.7.5 BufferedReader类
- Writer类
- 字符数组输出流:CharArrayWriter类
- OutputStreamWriter类
- FileWriter类 & 18.8.4 BufferedWriter类
- PrintWriter类
- 标准I/O
- 重新包装标准输入和输出
- 标准I/O重定向
- 随机访问文件类:RandomAccessFile
- 新I/O类库 & 18.11.1 缓冲器Buffer概述
- 通道Channel概述
- 字符编码Charset类概述 & 18.11.4 用FileChannel读写文件
- 控制缓冲区
- 字符编码转换
- 缓冲区视图
- 文件映射缓冲区:MappedByteBuffer
- 文件加锁
- 自动释放资源
- 用java.nio.file类库来操作文件系统
- 查看ZIP压缩文件
- 图形用户界面
- AWT组件和Swing组件
- 创建图形用户界面的基本步骤
- 布局管理器
- FlowLayout(流式布局管理器)
- BorderLayout(边界布局管理器)
- GridLayout(网格布局管理器)
- CardLayout(卡片布局管理器)
- GridBagLayout(网格包布局管理器)
- 事件处理 & 19.4.1 事件处理的软件实现
- 事件源、事件和监听器的类层次和关系
- AWT绘图
- Graphics类
- Graphics2D类
- AWT线程(事件分派线程)
- 常用Swing组件 & 边框(Border)
- 按钮组件(AbstractButton)及子类
- 文本框(JTextField)
- 文本区域(JTextArea)与滚动面板(JScrollPane)
- 复选框(JCheckBox)与单选按钮(JRadioButton)
- 下拉列表(JComboBox)
- 列表框(JList)
- 页签面板(JTabbedPane)
- 菜单(JMenu)
- 对话框(JDialog)
- 文件对话框(JFileChoose)
- 制作动画
- 播放音频文件
- BoxLayout布局管理器
- 设置Swing界面的外观和感觉
- Java常用类
- Object类
- String类和StringBuffer类 & 21.2.1 String类
- “hello”与new String(“hello”)的区别
- StringBuffer类
- 比较String类与StringBuffer类
- 正则表达式
- 格式化字符串
- 包装类 & 21.3.1 包装类的构造方法
- 包装类的常用方法
- 包装类的自动装箱和拆箱
- Math类
- Random类
- 传统的处理日期/时间的类 & 21.6.1 Date类
- DateFormat类
- Calendar类
- 新的处理日期/时间的类 & 21.7.1 LocalDate类
- LocalTime类
- LocalDateTime类
- BigInteger类
- BigDecimal类
- 用Optional类避免空指针异常
- Annotation注解 & 自定义Annotation注解类型
- 在类的源代码中引用注解类型
- 基本内置注解
- 小结 & 22.6 思考题
- Java基础
- 语言基础
- 对象和类
- 错误处理
- 操作数字
- 集合框架
- 输入/输出
- 并发工具
- Android简介
- 初识Android
- UI组件
- ListView
- GridView
- 样式和主题
- 位图处理
- 多面板布局
- 操作文件
- 操作数据库
- 获取图片
- 制作视频
- 声音录制
- 处理Handler
- 异步工具
- 广播接收器
- 闹钟服务
- 内容提供者
- 附录A javac
- 附录B java
- 附录C jar
- 附录D NetBeans
- 附录E Eclipse
- Java 年:道路与梦想
- Java 岁生日快乐
- Java 年:转角遇到Go
- Java 年:历史与未来
- Java 年:JVM虚拟化技术的发展
- 借助开源工具高效完成Java应用的运行分析
- 双重检查锁定与延迟初始化
- Gradle在大型Java项目上的应用
- 深入理解Java内存模型(五)——锁
- 深入分析ConcurrentHashMap
- HotSpot虚拟机对象探秘
- Java字节码忍者禁术
- DukeScript:随处运行Java的新尝试
- Java简介
- Java的基本数据类型
- 流程控制
- 面向对象篇
- 类与对象
- 控制逻辑
- 异常处理
- 嵌入式系统开发概述
- Swing常用控件
- JDBC数据库编程
- Java中输入/输出流
- 集合框架
- 网络编程
- 综合案例篇
- 学生管理系统
- Java核心技术 卷Ⅰ 基础知识(原书第版)
- Java核心技术 卷Ⅰ 基础知识(原书第版)
- Java“白皮书”的关键术语 & 1.2.1 简单性
- Java“白皮书”的关键术语 & 1.2.1 简单性
- 面向对象 & 1.2.3 分布式 & 1.2.4 健壮性
- 面向对象 & 1.2.3 分布式 & 1.2.4 健壮性
- 体系结构中立 & 1.2.7 可移植性
- 体系结构中立 & 1.2.7 可移植性
- 解释型 & 1.2.9 高性能
- 解释型 & 1.2.9 高性能 & 1.2.10 多线程
- 动态性 & 1.3 Java applet与Internet
- 多线程 & 1.2.11 动态性
- Java applet与Internet
- Java发展简史
- Java发展简史
- 关于Java的常见误解
- 关于Java的常见误解
- 设置JDK
- 设置JDK
- 安装库源文件和文档
- 安装库源文件和文档
- 使用命令行工具
- 使用命令行工具
- 使用集成开发环境
- 使用集成开发环境
- 注释 & 3.3 数据类型
- 注释 & 3.3 数据类型
- 浮点类型
- 浮点类型
- char类型
- char类型
- Unicode和char类型
- Unicode和char类型
- boolean类型 & 3.4 变量
- boolean类型 & 3.4 变量
- 变量初始化 & 3.4.2 常量
- 变量初始化 & 3.4.2 常量
- 数学函数与常量
- 数学函数与常量
- 数值类型之间的转换 & 3.5.3 强制类型转换
- 数值类型之间的转换 & 3.5.3 强制类型转换
- 结合赋值和运算符 & 3.5.5 自增与自减运算符 & 3.5.6 关系和boolean运算符
- 位运算符
- 结合赋值和运算符 & 3.5.5 自增与自减运算符 & 3.5.6 关系和boolean运算符
- 位运算符
- 括号与运算符级别 & 3.5.9 枚举类型 & 3.6 字符串
- 子串 & 3.6.2 拼接
- 括号与运算符级别 & 3.5.9 枚举类型 & 3.6 字符串
- 子串 & 3.6.2 拼接
- 不可变字符串
- 不可变字符串
- 检测字符串是否相等
- 检测字符串是否相等
- 空串与Null串 & 3.6.6 码点与代码单元
- String API
- 空串与Null串 & 3.6.6 码点与代码单元
- String API
- 阅读联机API文档
- 构建字符串
- 阅读联机API文档
- 构建字符串
- 输入输出 & 3.7.1 读取输入
- 格式化输出
- 输入输出 & 3.7.1 读取输入
- 格式化输出
- 文件输入与输出
- 文件输入与输出
- 控制流程 & 3.8.1 块作用域
- 控制流程 & 3.8.1 块作用域
- 条件语句 & 3.8.3 循环
- 确定循环
- 条件语句 & 3.8.3 循环
- 确定循环
- 多重选择:switch语句
- 多重选择:switch语句
- 中断控制流程语句
- 中断控制流程语句
- for each循环
- for each循环
- 数组初始化以及匿名数组 & 3.10.3 数组拷贝
- 数组初始化以及匿名数组 & 3.10.3 数组拷贝
- 多维数组
- 多维数组
- 不规则数组
- 不规则数组
- 识别类 & 4.1.4 类之间的关系
- 识别类 & 4.1.4 类之间的关系
- 使用预定义类 & 4.2.1 对象与对象变量
- Java类库中的LocalDate类
- 使用预定义类 & 4.2.1 对象与对象变量
- Java类库中的LocalDate类
- 更改器方法与访问器方法
- 更改器方法与访问器方法
- 用户自定义类 & 4.3.1 Employee类
- 用户自定义类 & 4.3.1 Employee类
- 多个源文件的使用 & 4.3.3 剖析Employee类
- 多个源文件的使用 & 4.3.3 剖析Employee类
- 从构造器开始
- 从构造器开始
- 隐式参数与显式参数
- 封装的优点
- 隐式参数与显式参数
- 封装的优点
- 基于类的访问权限 & 4.3.8 私有方法
- 基于类的访问权限 & 4.3.8 私有方法
- final实例域 & 4.4 静态域与静态方法 & 4.4.1 静态域
- final实例域 & 4.4 静态域与静态方法 & 4.4.1 静态域
- 静态常量 & 4.4.3 静态方法
- 静态常量 & 4.4.3 静态方法
- 工厂方法 & 4.4.5 main方法
- 方法参数
- 工厂方法 & 4.4.5 main方法
- 方法参数
- 对象构造 & 4.6.1 重载
- 对象构造 & 4.6.1 重载
- 默认域初始化 & 4.6.3 无参数的构造器
- 默认域初始化 & 4.6.3 无参数的构造器
- 显式域初始化 & 4.6.5 参数名
- 显式域初始化 & 4.6.5 参数名
- 调用另一个构造器 & 4.6.7 初始化块
- 调用另一个构造器 & 4.6.7 初始化块
- 对象析构与finalize方法
- 包 & 4.7.1 类的导入
- 对象析构与finalize方法
- 包 & 4.7.1 类的导入
- 静态导入 & 4.7.3 将类放入包中
- 包作用域
- 静态导入 & 4.7.3 将类放入包中
- 包作用域
- 设置类路径
- 设置类路径
- 文档注释 & 4.9.1 注释的插入
- 文档注释 & 4.9.1 注释的插入
- 类注释 & 4.9.3 方法注释 & 4.9.4 域注释 & 4.9.5 通用注释
- 类注释 & 4.9.3 方法注释 & 4.9.4 域注释 & 4.9.5 通用注释
- 包与概述注释 & 4.9.7 注释的抽取
- 类设计技巧
- 包与概述注释 & 4.9.7 注释的抽取
- 类设计技巧
- 继承 & 类、超类和子类
- 定义子类
- 继承 & 类、超类和子类
- 定义子类
- 覆盖方法
- 覆盖方法
- 子类构造器
- 子类构造器
- 继承层次 & 5.1.5 多态
- 继承层次 & 5.1.5 多态