/** * Get the clipboard text. * * @return Either the text, which is stored in the clipboard or an empty string if the clipboard is empty */ default String getClipboardText() { byte[] base64decodedBytes = Base64 .getMimeDecoder() .decode(getClipboard(ClipboardContentType.PLAINTEXT)); return new String(base64decodedBytes, StandardCharsets.UTF_8); } }
/** * Get the clipboard text. * * @return Either the text, which is stored in the clipboard or an empty string if the clipboard is empty */ default String getClipboardText() { byte[] base64decodedBytes = Base64 .getMimeDecoder() .decode(getClipboard(ClipboardContentType.PLAINTEXT)); return new String(base64decodedBytes, StandardCharsets.UTF_8); } }