com.hp.lft.sdk.mobile

Class LongPressArgs



  • public class LongPressArgs
    extends java.lang.Object
    Arguments that define additional behavior for Long Press operations.
    This class can be initialized using the builder pattern.
    • Constructor Summary

      Constructor and Description
      LongPressArgs()
      Initializes a new instance of the LongPressArgs class with default arguments (perform one long press at the center of the object, at one touch point, for the default long press duration).
    • Method Summary

      Modifier and Type Method and Description
      double getDuration()
      Returns the number of seconds to continue pressing.
      java.lang.String getGesture()
      Returns the gesture class designed by the mobile application developer to handle this gesture on this object.
      Location getLocation()
      Returns the Location to perform the long press.
      int getNumberOfTouchPoints()
      Returns the number of points to press, similar to the number of fingers you would use for the gesture on a real device.
      LongPressArgs setDuration(double duration)
      Sets the number of seconds to continue pressing.
      LongPressArgs setGesture(java.lang.String gesture)
      Sets the gesture class designed by the mobile application developer to handle this gesture on this object.
      LongPressArgs setLocation(Location location)
      Sets the location to perform the long press.
      LongPressArgs setNumberOfTouchPoints(int numberOfTouchPoints)
      Sets the the number of points to press, similar to the number of fingers you would use for the gesture on a real device.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • LongPressArgs

        public LongPressArgs()
        Initializes a new instance of the LongPressArgs class with default arguments (perform one long press at the center of the object, at one touch point, for the default long press duration).
    • Method Detail

      • getGesture

        public java.lang.String 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

        public LongPressArgs setGesture(java.lang.String gesture)
        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 LongPressArgs instance with the updated state (builder pattern).
      • getLocation

        public Location getLocation()
        Returns the Location to perform the long press.
        Default = center of the object
        Returns:
        the location to perform the long press.
      • setLocation

        public LongPressArgs setLocation(Location location)
        Sets the location to perform the long press.
        Parameters:
        location - the Location to perform the long press on the object.
        Returns:
        the LongPressArgs instance with the updated state (builder pattern).
      • getDuration

        public double getDuration()
        Returns the number of seconds to continue pressing. (iOS Only)
        Returns:
        the number of seconds to continue pressing.
      • setDuration

        public LongPressArgs setDuration(double duration)
        Sets the number of seconds to continue pressing. (iOS Only)
        Parameters:
        duration - the number of seconds to continue pressing.
        Returns:
        the LongPressArgs instance with the updated state (builder pattern).
      • getNumberOfTouchPoints

        public int getNumberOfTouchPoints()
        Returns the number of points to press, similar to the number of fingers you would use for the gesture on a real device. (iOS Only)
        Default = 1
        Returns:
        the number of points to press.
      • setNumberOfTouchPoints

        public LongPressArgs setNumberOfTouchPoints(int numberOfTouchPoints)
        Sets the the number of points to press, similar to the number of fingers you would use for the gesture on a real device. (iOS Only)
        Parameters:
        numberOfTouchPoints - the number of points to press.
        Returns:
        the LongPressArgs instance with the updated state (builder pattern).