CarPackageManager

public final class CarPackageManager
extends Object

java.lang.Object
   ↳ android.car.content.pm.CarPackageManager


Provides car specific API related with package management.

Summary

Public methods

boolean isActivityDistractionOptimized(String packageName, String className)

Check if given activity is distraction optimized, i.e, allowed in a restricted driving state

boolean isServiceDistractionOptimized(String packageName, String className)

Check if given service is distraction optimized, i.e, allowed in a restricted driving state.

Inherited methods

Public methods

isActivityDistractionOptimized

public boolean isActivityDistractionOptimized (String packageName, 
                String className)

Check if given activity is distraction optimized, i.e, allowed in a restricted driving state

Returns
boolean

Throws
CarNotConnectedException

isServiceDistractionOptimized

public boolean isServiceDistractionOptimized (String packageName, 
                String className)

Check if given service is distraction optimized, i.e, allowed in a restricted driving state.

Returns
boolean

Throws
CarNotConnectedException