reklama - zainteresowany?

Java Threads. 3rd Edition - Helion

Java Threads. 3rd Edition
ebook
Autor: Scott Oaks, Henry Wong
ISBN: 978-14-493-6666-7
stron: 362, Format: ebook
Data wydania: 2004-09-10
Księgarnia: Helion

Cena książki: 118,15 zł (poprzednio: 137,38 zł)
Oszczędzasz: 14% (-19,23 zł)

Dodaj do koszyka Java Threads. 3rd Edition

Tagi: Java - Programowanie

Threads are essential to Java programming, but learning to use them effectively is a nontrivial task. This new edition of the classic Java Threads shows you how to take full advantage of Java's threading facilities and brings you up-to-date with the watershed changes in Java 2 Standard Edition version 5.0 (J2SE 5.0). It provides a thorough, step-by-step approach to threads programming.Java's threading system is simple relative to other threading systems. In earlier versions of Java, this simplicity came with tradeoffs: some of the advanced features in other threading systems were not available in Java. J2SE 5.0 changes all that: it provides a large number of new thread-related classes that make the task of writing multithreaded programs that much easier.You'll learn where to use threads to increase efficiency, how to use them effectively, and how to avoid common mistakes. This book discusses problems like deadlock, race conditions, and starvation in detail, helping you to write code without hidden bugs.Java Threads, Third Edition, has been thoroughly expanded and revised. It incorporates the concurrency utilities from java.util.concurrent throughout. New chapters cover thread performance, using threads with Swing, threads and Collection classes, thread pools, and threads and I/O (traditional, new, and interrupted). Developers who cannot yet deploy J2SE 5.0 can use thread utilities provided in the Appendix to achieve similar functionality with earlier versions of Java.Topics include:

  • Lock starvation and deadlock detection
  • Atomic classes and minimal synchronization (J2SE 5.0)
  • Interaction of Java threads with Swing, I/O, and Collection classes
  • Programmatically controlled locks and condition variables (J2SE 5.0)
  • Thread performance and security
  • Thread pools (J2SE 5.0)
  • Thread groups
  • Platform-specific thread scheduling
  • Task schedulers (J2SE 5.0)
  • Parallelizing loops for multiprocessor machines
In short, this new edition of Java Threads covers everything you need to know about threads, from the simplest animation program to the most complex applications. If you plan to do any serious work in Java, you will find this book invaluable.Scott Oaks is a senior software engineer for the Java Performance Engineering group at Sun Microsystems and the author of four books in the O'Reilly Java series.Formerly a senior systems engineer at Sun Microsystems, Henry Wong is an independent consultant working on various Java related projects.

Dodaj do koszyka Java Threads. 3rd Edition

 

Osoby które kupowały "Java Threads. 3rd Edition", wybierały także:

  • Metoda dziel i zwyci
  • JÄ™zyk C. Kurs video. Praktyczne wprowadzenie do programowania
  • Wprowadzenie do Javy. Programowanie i struktury danych. Wydanie XII
  • Spring i Spring Boot. Kurs video. Testowanie aplikacji i bezpiecze
  • Maven. Kurs video. Automatyzacja tworzenia aplikacji w Javie

Dodaj do koszyka Java Threads. 3rd Edition

Spis treści

Java Threads. 3rd Edition eBook -- spis treści

  • Java Threads, 3rd Edition
  • A Note Regarding Supplemental Files
  • Preface
    • Who Should Read This Book?
    • Versions Used in This Book
    • Whats New in This Edition?
    • Organization of This Book
    • Conventions Used in This Book
    • Code Examples
    • How to Contact Us
    • Safari Enabled
    • Acknowledgments
  • 1. Introduction to Threads
    • 1.1. Java Terms
      • 1.1.1. Java Versions, Tools, and Code
    • 1.2. About the Examples
      • 1.2.1. Compiling and Running the Examples
    • 1.3. Why Threads?
      • 1.3.1. Nonblocking I/O
      • 1.3.2. Alarms and Timers
      • 1.3.3. Independent Tasks
      • 1.3.4. Parallelizable Algorithms
    • 1.4. Summary
  • 2. Thread Creation and Management
    • 2.1. What Is a Thread?
    • 2.2. Creating a Thread
      • 2.2.1. The Example Architecture
      • 2.2.2. The Thread Class
    • 2.3. The Lifecycle of a Thread
      • 2.3.1. Creating a Thread
      • 2.3.2. Starting a Thread
      • 2.3.3. Terminating a Thread
      • 2.3.4. Pausing, Suspending, and Resuming Threads
      • 2.3.5. Thread Cleanup
    • 2.4. Two Approaches to Stopping a Thread
      • 2.4.1. Setting a Flag
      • 2.4.2. Interrupting a Thread
    • 2.5. The Runnable Interface
    • 2.6. Threads and Objects
      • 2.6.1. Determining the Current Thread
    • 2.7. Summary
      • 2.7.1. Example Classes
  • 3. Data Synchronization
    • 3.1. The Synchronized Keyword
    • 3.2. The Volatile Keyword
    • 3.3. More on Race Conditions
    • 3.4. Explicit Locking
    • 3.5. Lock Scope
      • 3.5.1. Synchronized Blocks
    • 3.6. Choosing a Locking Mechanism
      • 3.6.1. The Lock Interface
    • 3.7. Nested Locks
    • 3.8. Deadlock
    • 3.9. Lock Fairness
    • 3.10. Summary
      • 3.10.1. Example Classes
  • 4. Thread Notification
    • 4.1. Wait and Notify
      • 4.1.1. The Wait-and-Notify Mechanism and Synchronization
      • 4.1.2. wait( ), notify( ), and notifyAll( )
      • 4.1.3. Wait-and-Notify Mechanism with Synchronized Blocks
    • 4.2. Condition Variables
    • 4.3. Summary
      • 4.3.1. Example Classes
  • 5. Minimal Synchronization Techniques
    • 5.1. Can You Avoid Synchronization?
      • 5.1.1. The Effect of Registers
      • 5.1.2. The Effect of Reordering Statements
      • 5.1.3. Double-Checked Locking
    • 5.2. Atomic Variables
      • 5.2.1. Overview of the Atomic Classes
      • 5.2.2. Using the Atomic Classes
        • 5.2.2.1. Variable substitution
        • 5.2.2.2. Changing algorithms
        • 5.2.2.3. Retrying operations
      • 5.2.3. Notifications and Atomic Variables
      • 5.2.4. Summary of Atomic Variable Usage
        • 5.2.4.1. Data exchange
        • 5.2.4.2. Compare and set
        • 5.2.4.3. Advanced atomic data types
        • 5.2.4.4. Bulk data modification
    • 5.3. Thread Local Variables
      • 5.3.1. Inheritable Thread Local Variables
    • 5.4. Summary
      • 5.4.1. Example Classes
  • 6. Advanced Synchronization Topics
    • 6.1. Synchronization Terms
    • 6.2. Synchronization Classes Added in J2SE 5.0
      • 6.2.1. Semaphore
      • 6.2.2. Barrier
      • 6.2.3. Countdown Latch
      • 6.2.4. Exchanger
      • 6.2.5. Reader/Writer Locks
    • 6.3. Preventing Deadlock
      • 6.3.1. Deadlock and Automatic Lock Releases
      • 6.3.2. Preventing Deadlock with Timeouts
    • 6.4. Deadlock Detection
    • 6.5. Lock Starvation
      • 6.5.1. Lock Starvation and Reader/Writer Locks
    • 6.6. Summary
      • 6.6.1. Example Classes
  • 7. Threads and Swing
    • 7.1. Swing Threading Restrictions
    • 7.2. Processing on the Event-Dispatching Thread
    • 7.3. Using invokeLater( ) and invokeAndWait( )
    • 7.4. Long-Running Event Callbacks
    • 7.5. Summary
      • 7.5.1. Example Classes
  • 8. Threads and Collection Classes
    • 8.1. Overview of Collection Classes
      • 8.1.1. Collection Interfaces
      • 8.1.2. Threadsafe Collection Classes
      • 8.1.3. Thread-Unsafe Collection Classes
      • 8.1.4. Thread-Notification Collection Classes
    • 8.2. Synchronization and Collection Classes
      • 8.2.1. Simple Synchronization
      • 8.2.2. Complex Synchronization
      • 8.2.3. Iterators and Enumerations
      • 8.2.4. Thread-Aware Classes
    • 8.3. The Producer/Consumer Pattern
    • 8.4. Using the Collection Classes
    • 8.5. Summary
      • 8.5.1. Example Classes
  • 9. Thread Scheduling
    • 9.1. An Overview of Thread Scheduling
      • 9.1.1. Priority-Based Scheduling
      • 9.1.2. The Scheduling Process
      • 9.1.3. Priority Exceptions
        • 9.1.3.1. Priority inversion
        • 9.1.3.2. Complex priorities
    • 9.2. Scheduling with Thread Priorities
      • 9.2.1. Other Thread-Scheduling Methods
    • 9.3. Popular Threading Implementations
      • 9.3.1. Green Threads
      • 9.3.2. Windows Native Threads
      • 9.3.3. Solaris Native Threads
      • 9.3.4. Linux Native Threads
    • 9.4. Summary
      • 9.4.1. Example Classes
  • 10. Thread Pools
    • 10.1. Why Thread Pools?
      • 10.1.1. Thread Pools and Throughput
      • 10.1.2. Why Not Thread Pools?
    • 10.2. Executors
    • 10.3. Using a Thread Pool
    • 10.4. Queues and Sizes
      • 10.4.1. Rejected Tasks
    • 10.5. Thread Creation
    • 10.6. Callable Tasks and Future Results
      • 10.6.1. The FutureTask Class
    • 10.7. Single-Threaded Access
    • 10.8. Summary
      • 10.8.1. Example Classes
  • 11. Task Scheduling
    • 11.1. Overview of Task Scheduling
    • 11.2. The java.util.Timer Class
      • 11.2.1. Using the Timer
    • 11.3. The javax.swing.Timer Class
      • 11.3.1. Using the javax.swing.Timer Class
    • 11.4. The ScheduledThreadPoolExecutor Class
      • 11.4.1. Using the ScheduledThreadPoolExecutor Class
      • 11.4.2. Using the Future Interface
    • 11.5. Summary
      • 11.5.1. Example Classes
  • 12. Threads and I/O
    • 12.1. A Traditional I/O Server
      • 12.1.1. An Example Multithreaded Server
        • 12.1.1.1. Using the multithreaded server
      • 12.1.2. Scaling Using Traditional I/O
    • 12.2. A New I/O Server
      • 12.2.1. Nonblocking I/O
      • 12.2.2. A Single-Threaded NIO Server
      • 12.2.3. A Multithreaded New I/O Server
    • 12.3. Interrupted I/O
    • 12.4. Summary
      • 12.4.1. Example Classes
  • 13. Miscellaneous Thread Topics
    • 13.1. Thread Groups
    • 13.2. Threads and Java Security
    • 13.3. Daemon Threads
    • 13.4. Threads and Class Loading
    • 13.5. Threads and Exception Handling
      • 13.5.1. The ThreadDeath Class
    • 13.6. Threads, Stacks, and Memory Usage
      • 13.6.1. Stack Overflow Errors
      • 13.6.2. Out of Memory Errors
      • 13.6.3. Specifying Stack Sizes
      • 13.6.4. Stack APIs
    • 13.7. Summary
      • 13.7.1. Example Classes
  • 14. Thread Performance
    • 14.1. Overview of Performance
      • 14.1.1. Measuring Java Performance
    • 14.2. Synchronized Collections
    • 14.3. Atomic Variables and Contended Synchronization
      • 14.3.1. The ConcurrentHashMap Class
    • 14.4. Thread Creation and Thread Pools
    • 14.5. Summary
      • 14.5.1. Example Classes
  • 15. Parallelizing Loops for Multiprocessor Machines
    • 15.1. Parallelizing a Single-Threaded Program
      • 15.1.1. Loop Scheduling and Load Balancing
        • 15.1.1.1. Static or chunk scheduling
        • 15.1.1.2. Self-scheduling
        • 15.1.1.3. Guided self-scheduling
        • 15.1.1.4. User-defined scheduling
      • 15.1.2. Variable Classifications
        • 15.1.2.1. Loop-private variables
        • 15.1.2.2. Read-only variables
        • 15.1.2.3. Storeback variables
        • 15.1.2.4. Reduction variables
        • 15.1.2.5. Shared variables
      • 15.1.3. Loop Analysis and Transformations
        • 15.1.3.1. Loop distribution
        • 15.1.3.2. Loop isolation
        • 15.1.3.3. Loop interchange
        • 15.1.3.4. Loop reimplementation
      • 15.1.4. Inner-Loop Threading
      • 15.1.5. Loop Printing
    • 15.2. Multiprocessor Scaling
      • 15.2.1. A Simple Loop Test
      • 15.2.2. A Reduction Variable Test
      • 15.2.3. A Small Inner-Loop Test
      • 15.2.4. A Printing Test
    • 15.3. Summary
      • 15.3.1. Example Classes
  • A. Superseded Threading Utilities
    • A.1. The BusyFlag Class
    • A.2. The CondVar Class
    • A.3. The Barrier Class
    • A.4. The RWLock Class
    • A.5. The ThreadPool Class
    • A.6. The JobScheduler Class
      • A.6.1. The DaemonLock Class
    • A.7. Summary
  • Index
  • About the Authors
  • Colophon
  • Copyright

Dodaj do koszyka Java Threads. 3rd Edition

Code, Publish & WebDesing by CATALIST.com.pl



(c) 2005-2024 CATALIST agencja interaktywna, znaki firmowe należą do wydawnictwa Helion S.A.