Book Description

About the Author

Table of Contents

Source Code

Errata

Send Comments

Teaching Materials

Author's Homepage
 

Object-Oriented Software Development Using Java
Xiaoping Jia, Ph.D
Chapter 11: Concurrent Programming

Contents
   11.1 Threads
         11.1.1 Creation of Threads
         11.1.2 Controlling Threads
   11.2 Thread Safety and Liveness
         11.2.1 Synchronization
         11.2.2 Cooperation Among Threads
         11.2.3 Liveness Failures
   11.3 Design Case Study—Tic-Tac-Toe Game
         11.3.1 The Game Board
         11.3.2 The Game
         11.3.3 The Players
         11.3.4 Idiom: Taking Turns



Other Chapters

  • Example 11.1 A Simple Infinite Counter
    • Source code: Counter1.java
    • Compile:
      • javac Counter1.java
    • Run:
      • java Counter1
        Control-C to stop the program
  • Example 11.2 Stock Quote Generator
    • Source code: Quote.java
    • Compile:
      • javac Quote.java
    • Run:
      • java Quote
        Control-C to stop the program
  • Example 11.3 A Simple Infinite Counter II
    • Source code: Counter2.java
    • Compile:
      • javac Counter2.java
    • Run:
      • java Counter2
        Control-C to stop the program
  • Example 11.4 Bounded Queue (Sequential Version)
    • Source code: BoundedQueue.java
    • Compile:
      • javac BoundedQueue.java
    • Run:
      • java BoundedQueue
  • Example 11.5 Bounded Queue (Fully Synchronized Version)
  • Example 11.6 Bounded Queue with Guarded Suspension

Book Description - About the Author - Table of Contents
Source Code - Errata - Send Comments
Teaching Materials - Author's Homepage