Interface HasClipboard

All Superinterfaces:
CanRememberExtensionPresence, ExecutesMethod
All Known Subinterfaces:
HasAndroidClipboard, HasIOSClipboard
All Known Implementing Classes:
AndroidDriver, FlutterAndroidDriver, FlutterIOSDriver, IOSDriver

public interface HasClipboard extends ExecutesMethod, CanRememberExtensionPresence
  • Method Details

    • setClipboard

      default void setClipboard(ClipboardContentType contentType, byte[] base64Content)
      Set the content of device's clipboard.
      Parameters:
      contentType - one of supported content types.
      base64Content - base64-encoded content to be set.
    • getClipboard

      default String getClipboard(ClipboardContentType contentType)
      Get the content of the clipboard.
      Parameters:
      contentType - one of supported content types.
      Returns:
      the actual content of the clipboard as base64-encoded string or an empty string if the clipboard is empty
    • setClipboardText

      default void setClipboardText(String text)
      Set the clipboard text.
      Parameters:
      text - The actual text to be set.
    • getClipboardText

      default String getClipboardText()
      Get the clipboard text.
      Returns:
      Either the text, which is stored in the clipboard or an empty string if the clipboard is empty