Open topic with navigation

com.hp.lft.sdk

## Interface KeyboardDevice

-     public interface KeyboardDevice

  An interface that provides low-level keyboard operations.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `keyDown(byte keyScanCode)` Deprecated. use `keyDown(Keyboard.Keys)` instead.
    `void` | `keyDown(Keyboard.Keys key)` Presses and holds the specified key using a keyboard virtual key.
    `void` | `keyUp(byte keyScanCode)` Deprecated. use `keyUp(Keyboard.Keys)` instead.
    `void` | `keyUp(Keyboard.Keys key)` Releases the specified key based on its keyboard virtual key.
    `void` | `pressKey(byte keyScanCode)` Deprecated. use `pressKey(Keyboard.Keys)` instead.
    `void` | `pressKey(Keyboard.Keys key)` Presses the specified key using a keyboard virtual key.
    `void` | `sendString(String stringToSend)` Types the specified string.

- - ### Method Detail

    - #### pressKey

          @Deprecated
          void pressKey(byte keyScanCode)
                        throws GeneralLeanFtException

      Deprecated. use `pressKey(Keyboard.Keys)` instead.
      Presses the specified key using a keyboard scan code.
      Supports scan code set 1, such as the list shown at: http://www.computer-engineering.org/ps2keyboard/scancodes1.html
      Parameters:
        `keyScanCode` - the keyboard scan code of the key.
      Throws:
        `GeneralLeanFtException` - if error occurs during execution

    - #### pressKey

          void pressKey(Keyboard.Keys key)
                        throws GeneralLeanFtException

      Presses the specified key using a keyboard virtual key.
      Parameters:
        `key` - the keyboard code of the key. Possible values: `Keyboard.Keys`
      Throws:
        `GeneralLeanFtException` - if error occurs during execution

    - #### keyDown

          @Deprecated
          void keyDown(byte keyScanCode)
                       throws GeneralLeanFtException

      Deprecated. use `keyDown(Keyboard.Keys)` instead.
      Presses and holds the specified key using a keyboard scan code.
      Supports scan code set 1, such as the list shown at: http://www.computer-engineering.org/ps2keyboard/scancodes1.html
      Parameters:
        `keyScanCode` - the keyboard scan code of the key to hold.
      Throws:
        `GeneralLeanFtException` - if error occurs during execution

    - #### keyDown

          void keyDown(Keyboard.Keys key)
                       throws GeneralLeanFtException

      Presses and holds the specified key using a keyboard virtual key.
      Parameters:
        `key` - the keyboard code of the key to hold. Possible values: `Keyboard.Keys`
      Throws:
        `GeneralLeanFtException` - if error occurs during execution

    - #### keyUp

          @Deprecated
          void keyUp(byte keyScanCode)
                     throws GeneralLeanFtException

      Deprecated. use `keyUp(Keyboard.Keys)` instead.
      Releases the specified key based on its keyboard scan code.
      Supports scan code set 1, such as the list shown at: http://www.computer-engineering.org/ps2keyboard/scancodes1.html
      Parameters:
        `keyScanCode` - the keyboard scan code of the key to release.
      Throws:
        `GeneralLeanFtException` - if error occurs during execution

    - #### keyUp

          void keyUp(Keyboard.Keys key)
                     throws GeneralLeanFtException

      Releases the specified key based on its keyboard virtual key.
      Parameters:
        `key` - the keyboard code of the key to release. Possible values: `Keyboard.Keys`
      Throws:
        `GeneralLeanFtException` - if error occurs during execution

    - #### sendString

          void sendString(String stringToSend)
                          throws GeneralLeanFtException

      Types the specified string.
      Parameters:
        `stringToSend` - the string to type.
      Throws:
        `GeneralLeanFtException` - if error occurs during execution