Package com.hp.lft.sdk.mobile
Class PinchArgs
java.lang.Object
com.hp.lft.sdk.mobile.PinchArgs
Arguments that define additional behavior for Pinch operations.
This class can be initialized using the builder pattern.
This class can be initialized using the builder pattern.
-
Constructor Summary
ConstructorsConstructorDescriptionInitializes a new instance of the PinchArgs class with default arguments (pinch the center of the object). -
Method Summary
Modifier and TypeMethodDescriptionReturns the gesture class designed by the mobile application developer to handle this gesture on this object.Returns the location to perform the pinch operation.Returns the speed at which to perform the pinch gesture.setGesture
(String gesture) Sets the gesture class designed by the mobile application developer to handle this gesture on this object.setLocation
(Location location) Sets the location to perform the pinch operation.setVelocity
(Double velocity) Sets the speed at which to perform the pinch gesture.
-
Constructor Details
-
PinchArgs
public PinchArgs()Initializes a new instance of the PinchArgs class with default arguments (pinch the center of the object).
-
-
Method Details
-
getGesture
Returns the gesture class designed by the mobile application developer to handle this gesture on this object. (iOS Only)
Needed only if the application developer overrode the default iOS gesture class.- Returns:
- the gesture class designed by the mobile application developer.
-
setGesture
Sets the gesture class designed by the mobile application developer to handle this gesture on this object. (iOS Only)
Needed only if the application developer overrode the default iOS gesture class.- Parameters:
gesture
- the gesture class designed by the mobile application developer.- Returns:
- the PinchArgs instance with the updated state (builder pattern).
-
getVelocity
Returns the speed at which to perform the pinch gesture. This number specifies the scale factor per second, meaning the ratio between the touch point distance at one second, and the touch point distance one second later.
For example, if performing a pinch from 6 cm to 3 cm (0.5 scale) takes 2 seconds, then the velocity is 0.25.- Returns:
- the speed at which to perform the pinch gesture.
-
setVelocity
Sets the speed at which to perform the pinch gesture. This number specifies the scale factor per second, meaning the ratio between the touch point distance at one second, and the touch point distance one second later.
For example, if performing a pinch from 6 cm to 3 cm (0.5 scale) takes 2 seconds, then the velocity is 0.25.- Parameters:
velocity
- the speed at which to perform the pinch gesture.- Returns:
- the PinchArgs instance with the updated state (builder pattern).
-
getLocation
Returns the location to perform the pinch operation.
Default = center of the object- Returns:
- the location to perform the pinch operation.
-
setLocation
Sets the location to perform the pinch operation.- Parameters:
location
- the location to perform the pinch operation.- Returns:
- the PinchArgs instance with the updated state (builder pattern).
-