March 2013
Intermediate to advanced
346 pages
8h 4m
English
The previous recipe discusses how to synchronize threads with mutex. This recipe describes how to use conditional variables.
The following steps will help us create an Android project that demonstrates the usage of pthread conditional variables:
NativeThreadsCondVar. Set the package name as cookbook.chapter6.nativethreadscondvar. Refer to the Loading native libraries and registering native methods recipe in Chapter 2, Java Native Interface for more detailed instructions.MainActivity.java under the package cookbook.chapter6.nativethreadscondvar ...