java.lang.Object
com.smartdevicelink.proxy.RPCStruct
com.smartdevicelink.proxy.RPCMessage
com.smartdevicelink.proxy.RPCNotification
Notifies application of button press events for buttons to which the application is subscribed. SDL supports two button press events defined as follows:
Parameter List:
Name | Type | Description | Req | Notes | SmartDeviceLink Ver Available |
---|---|---|---|---|---|
buttonName | ButtonName | Name of the button which triggered this event | SmartDeviceLink 1.0 | ||
buttonPressMode | ButtonPressMode | Indicates whether this is an SHORT or LONG button press event. | SmartDeviceLink 1.0 | ||
customButtonID | Integer | If ButtonName is "CUSTOM_BUTTON", this references the integer ID passed by a custom button. (e.g. softButton ID) | N | Minvalue=0 Maxvalue=65536 | SmartDeviceLink 2.0 |
public static final java.lang.String KEY_BUTTON_PRESS_MODE
public static final java.lang.String KEY_BUTTON_NAME
public static final java.lang.String KEY_CUSTOM_BUTTON_ID
Constructs a newly allocated OnButtonPress object
public OnButtonPress()
Constructs a newly allocated OnButtonPress object indicated by the Hashtable parameter
public OnButtonPress(java.util.Hashtable<java.lang.String, java.lang.Object> hash)
Constructs a newly allocated OnButtonPress object
public OnButtonPress(ButtonName buttonName,ButtonPressMode buttonPressMode)
Returns an ButtonName the button's name
public com.smartdevicelink.proxy.rpc.enums.ButtonName getButtonName()
Set the button's name
public com.smartdevicelink.proxy.rpc.OnButtonPress setButtonName(ButtonName buttonName)
Returns ButtonPressMode
public com.smartdevicelink.proxy.rpc.enums.ButtonPressMode getButtonPressMode()
Set the button press mode of the event
public com.smartdevicelink.proxy.rpc.OnButtonPress setButtonPressMode(ButtonPressMode buttonPressMode)
Set CustomButtonID of the button If ButtonName is "CUSTOM_BUTTON", this references the integer ID passed by a custom button. (e.g. softButton ID)
public com.smartdevicelink.proxy.rpc.OnButtonPress setCustomButtonID(Integer customButtonID)
Get CustomButtonID of the button If ButtonName is "CUSTOM_BUTTON", this references the integer ID passed by a custom button. (e.g. softButton ID)
public java.lang.Integer getCustomButtonID()
From Class | Methods |
---|---|
com.smartdevicelink.proxy.RPCMessage | getFunctionID, getFunctionName, setFunctionName, getMessageType, setParameters, getParameters, getObject, getString, getInteger, getFloat, getDouble, getBoolean, getLong |
com.smartdevicelink.proxy.RPCStruct | getStoreValue, getStore, deserializeJSON, serializeJSON, serializeJSON, format, getBulkData, setBulkData, setPayloadProtected, isPayloadProtected, getMessageTypeName, hasKey, setValue, getValue, getObject, formatObject, getValueForString, getString, getInteger, getDouble, getFloat, getBoolean, getLong, clone, equals, hashCode |
java.lang.Object | getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize |