Expand Minimize Picture-in-picture Power Device Status Voice Recognition Skip Back Skip Forward Minus Plus Play Search
Internet Explorer alert
This browser is not recommended for use with smartdevicelink.com, and may not function properly. Upgrade to a different browser to guarantee support of all features.
close alert
To Top Created with Sketch. To Top
To Bottom Created with Sketch. To Bottom
JavaSE Documentation
TouchEvent

Class TouchEvent

Hierarchy

java.lang.Object
     com.smartdevicelink.proxy.RPCStruct

Package
com.smartdevicelink.proxy.rpc

Overview

For touchscreen interactions, the mode of how the choices are presented.

Parameter List

Name Type Description Reg. Notes Version
id Integer A touch's unique identifier. The application can track the current touch events by id. If a touch event has type begin, the id should be added to the set of touches. If a touch event has type end, the id should be removed from the set of touches. N Min Value: 0; Max Value: 9 SmartDeviceLink 3.0
ts Float The time that the touch was recorded.

This number can the time since the beginning of the session or something else as long as the units are in milliseconds.

The timestamp is used to determined the rate of change of position of a touch.

The application also uses the time to verify whether two touches,with different ids, are part of a single action by the user.

If there is only a single timestamp in this array,

it is the same for every coordinate in the coordinates array.
Y minvalue="0" maxvalue="5000000000" minsize="1" maxsize="1000" SmartDeviceLink 3.0
c Integer The coordinates of the screen area where the touch event occurred. Y SmartDeviceLink 3.0

Fields

KEY_ID

public static final java.lang.String KEY_ID
Constant Value
"id"

KEY_TS

public static final java.lang.String KEY_TS
Constant Value
"ts"

KEY_C

public static final java.lang.String KEY_C
Constant Value
"c"

Inherited Fields

From Class Fields
com.smartdevicelink.proxy.RPCStruct KEY_BULK_DATA, KEY_PROTECTED, store

Constructors

TouchEvent()

public TouchEvent()

TouchEvent( java.util.Hashtable<java.lang.String, java.lang.Object> hash )

Constructs a new TouchEvent object indicated by the Hashtable parameter

public TouchEvent(java.util.Hashtable<java.lang.String, java.lang.Object> hash)

Constructor Parameters

hash
The Hashtable to use

TouchEvent( Integer id, java.util.List<java.lang.Long> ts, java.util.List<com.smartdevicelink.proxy.rpc.TouchCoord> c )

Constructs a new TouchEvent object

public TouchEvent(Integer id,java.util.List<java.lang.Long> ts,java.util.List<com.smartdevicelink.proxy.rpc.TouchCoord> c)

Constructor Parameters

id
A touch's unique identifier.
ts
The time that the touch was recorded.
c
The coordinates of the screen area where the touch event occurred.

Methods

setId( Integer id )

public com.smartdevicelink.proxy.rpc.TouchEvent setId(Integer id)

Method Parameters

id

getId()

public java.lang.Integer getId()

getTs()

Deprecated
Use getTimestamps

public java.util.List getTs()

getTimestamps()

public java.util.List getTimestamps()

setTimestamps( java.util.List<java.lang.Long> ts )

public com.smartdevicelink.proxy.rpc.TouchEvent setTimestamps(java.util.List<java.lang.Long> ts)

Method Parameters

ts

setTs( java.util.List<java.lang.Long> ts )

Deprecated
Use setTimestamps.

public com.smartdevicelink.proxy.rpc.TouchEvent setTs(java.util.List<java.lang.Long> ts)

Method Parameters

ts

getC()

Deprecated
Use getTouchCoordinates

public java.util.List getC()

getTouchCoordinates()

public java.util.List getTouchCoordinates()

setC( java.util.List<com.smartdevicelink.proxy.rpc.TouchCoord> c )

Deprecated
Use setTouchCoordinates

public com.smartdevicelink.proxy.rpc.TouchEvent setC(java.util.List<com.smartdevicelink.proxy.rpc.TouchCoord> c)

Method Parameters

c

setTouchCoordinates( java.util.List<com.smartdevicelink.proxy.rpc.TouchCoord> c )

public com.smartdevicelink.proxy.rpc.TouchEvent setTouchCoordinates(java.util.List<com.smartdevicelink.proxy.rpc.TouchCoord> c)

Method Parameters

c

Inherited Methods

From Class Methods
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
View on GitHub.com
Previous Section Next Section