public class OnDriverDistraction extends RPCNotification
Notifies the application of the current driver distraction state (whether driver distraction rules are in effect, or not).
HMI Status Requirements:| Name | Type | Description | SmartDeviceLink Ver Available |
|---|---|---|---|
| state | DriverDistractionState | Current driver distraction state (i.e. whether driver distraction rules are in effect, or not). | SmartDeviceLink 1.0 |
| Modifier and Type | Field and Description |
|---|---|
static String |
KEY_LOCKSCREEN_DISMISSIBLE |
static String |
KEY_LOCKSCREEN_DISMISSIBLE_MSG |
static String |
KEY_STATE |
function, KEY_CORRELATION_ID, KEY_FUNCTION_NAME, KEY_NOTIFICATION, KEY_PARAMETERS, KEY_REQUEST, KEY_RESPONSE, messageType, parametersKEY_BULK_DATA, KEY_PROTECTED, store| Constructor and Description |
|---|
OnDriverDistraction()
Constructs a newly allocated OnDriverDistraction object
|
OnDriverDistraction(DriverDistractionState state)
Constructs a newly allocated OnDriverDistraction object
|
OnDriverDistraction(Hashtable<String,Object> hash)
Constructs a newly allocated OnDriverDistraction object indicated by the Hashtable parameter
|
| Modifier and Type | Method and Description |
|---|---|
Boolean |
getLockscreenDismissibility()
Called to get the dismissible state of Lockscreen
|
String |
getLockscreenWarningMessage()
Called to get the lockscreen warning message
|
DriverDistractionState |
getState()
Called to get the current driver distraction state(i.e.
|
OnDriverDistraction |
setLockscreenDismissibility(boolean isDismissible)
Called to set dismissible state of Lockscreen
|
OnDriverDistraction |
setLockscreenWarningMessage(String msg)
Called to set a warning message for the lockscreen
|
OnDriverDistraction |
setState(DriverDistractionState state)
Called to set the driver distraction state(i.e.
|
getBoolean, getDouble, getFloat, getFunctionID, getFunctionName, getInteger, getLong, getMessageType, getObject, getParameters, getString, setFunctionName, setParametersclone, deserializeJSON, equals, format, formatObject, getBulkData, getMessageTypeName, getStore, getStoreValue, getValue, getValueForString, hashCode, hasKey, isPayloadProtected, serializeJSON, serializeJSON, setBulkData, setPayloadProtected, setValuepublic static final String KEY_STATE
public static final String KEY_LOCKSCREEN_DISMISSIBLE
public static final String KEY_LOCKSCREEN_DISMISSIBLE_MSG
public OnDriverDistraction()
public OnDriverDistraction(Hashtable<String,Object> hash)
Constructs a newly allocated OnDriverDistraction object indicated by the Hashtable parameter
hash - The Hashtable to usepublic OnDriverDistraction(@NonNull
DriverDistractionState state)
state - the current driver distraction statepublic DriverDistractionState getState()
Called to get the current driver distraction state(i.e. whether driver distraction rules are in effect, or not)
public OnDriverDistraction setState(@NonNull DriverDistractionState state)
Called to set the driver distraction state(i.e. whether driver distraction rules are in effect, or not)
state - the current driver distraction statepublic OnDriverDistraction setLockscreenDismissibility(boolean isDismissible)
Called to set dismissible state of Lockscreen
isDismissible - the Lockscreen's dismissibilitypublic Boolean getLockscreenDismissibility()
Called to get the dismissible state of Lockscreen
public OnDriverDistraction setLockscreenWarningMessage(String msg)
msg - the message to be setpublic String getLockscreenWarningMessage()