Enum Class KeyEventFlag

java.lang.Object
java.lang.Enum<KeyEventFlag>
io.appium.java_client.android.nativekey.KeyEventFlag
All Implemented Interfaces:
Serializable, Comparable<KeyEventFlag>, Constable

public enum KeyEventFlag extends Enum<KeyEventFlag>
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    When associated with up key events, this indicates that the key press has been canceled.
    Set when a key event has CANCELED set because a long press action was executed while it was down.
    This mask is used for compatibility, to identify enter keys that are coming from an IME whose enter key has been auto-labelled "next" or "done".
    Set when a key event has been synthesized to implement default behavior for an event that the application did not handle.
    This mask is set if an event was known to come from a trusted part of the system.
    This mask is set if we don't want the key event to cause us to leave touch mode.
    This flag is set for the first key repeat that occurs after the long press timeout.
    Signifies that the key is being predispatched.
    This mask is set if the key event was generated by a software keyboard.
    Private control to determine when an app is tracking a key sequence.
    Private flag that indicates when the system has detected that this key event may be inconsistent with respect to the sequence of previously delivered key events, such as when a key up event is sent but the key was not down.
    Set for ACTION_UP when this event's key value is still being tracked from its initial down.
    This key event was generated by a virtual (on-screen) hard key area.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
     
    Returns the enum constant of this class with the specified name.
    static KeyEventFlag[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • SOFT_KEYBOARD

      public static final KeyEventFlag SOFT_KEYBOARD
      This mask is set if the key event was generated by a software keyboard.
    • KEEP_TOUCH_MODE

      public static final KeyEventFlag KEEP_TOUCH_MODE
      This mask is set if we don't want the key event to cause us to leave touch mode.
    • FROM_SYSTEM

      public static final KeyEventFlag FROM_SYSTEM
      This mask is set if an event was known to come from a trusted part of the system. That is, the event is known to come from the user, and could not have been spoofed by a third party component.
    • EDITOR_ACTION

      public static final KeyEventFlag EDITOR_ACTION
      This mask is used for compatibility, to identify enter keys that are coming from an IME whose enter key has been auto-labelled "next" or "done". This allows TextView to dispatch these as normal enter keys for old applications, but still do the appropriate action when receiving them.
    • CANCELED

      public static final KeyEventFlag CANCELED
      When associated with up key events, this indicates that the key press has been canceled. Typically this is used with virtual touch screen keys, where the user can slide from the virtual key area on to the display: in that case, the application will receive a canceled up event and should not perform the action normally associated with the key. Note that for this to work, the application can not perform an action for a key until it receives an up or the long press timeout has expired.
    • VIRTUAL_HARD_KEY

      public static final KeyEventFlag VIRTUAL_HARD_KEY
      This key event was generated by a virtual (on-screen) hard key area. Typically this is an area of the touchscreen, outside of the regular display, dedicated to "hardware" buttons.
    • LONG_PRESS

      public static final KeyEventFlag LONG_PRESS
      This flag is set for the first key repeat that occurs after the long press timeout.
    • CANCELED_LONG_PRESS

      public static final KeyEventFlag CANCELED_LONG_PRESS
      Set when a key event has CANCELED set because a long press action was executed while it was down.
    • TRACKING

      public static final KeyEventFlag TRACKING
      Set for ACTION_UP when this event's key value is still being tracked from its initial down. That is, somebody requested that tracking started on the key down and a long press has not caused the tracking to be canceled.
    • FALLBACK

      public static final KeyEventFlag FALLBACK
      Set when a key event has been synthesized to implement default behavior for an event that the application did not handle. Fallback key events are generated by unhandled trackball motions (to emulate a directional keypad) and by certain unhandled key presses that are declared in the key map (such as special function numeric keypad keys when numlock is off).
    • PREDISPATCH

      public static final KeyEventFlag PREDISPATCH
      Signifies that the key is being predispatched.
    • START_TRACKING

      public static final KeyEventFlag START_TRACKING
      Private control to determine when an app is tracking a key sequence.
    • TAINTED

      public static final KeyEventFlag TAINTED
      Private flag that indicates when the system has detected that this key event may be inconsistent with respect to the sequence of previously delivered key events, such as when a key up event is sent but the key was not down.
  • Method Details

    • values

      public static KeyEventFlag[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static KeyEventFlag valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public int getValue()