FileDocCategorySizeDatePackage
SuspendBlocker.javaAPI DocAndroid 5.1 API1397Thu Mar 12 22:22:42 GMT 2015com.android.server.power

SuspendBlocker

public interface SuspendBlocker
Low-level suspend blocker mechanism equivalent to holding a partial wake lock. This interface is used internally to avoid introducing internal dependencies on the high-level wake lock mechanism.

Fields Summary
Constructors Summary
Methods Summary
public voidacquire()
Acquires the suspend blocker. Prevents the CPU from going to sleep. Calls to acquire() nest and must be matched by the same number of calls to release().

public voidrelease()
Releases the suspend blocker. Allows the CPU to go to sleep if no other suspend blockers are held. It is an error to call release() if the suspend blocker has not been acquired. The system may crash.