Methods Summary

Exbot class include several action methods based on Java Robot. It allows you to quickly create robot workflow that interacts with the operating system of a computer.

Method and Description

Modifier and Type

Operating system

Exbot() Constructs an Exbot object in the coordinate system of the primary screen.

-

All

mouseClickAt(int x, int y) Perform a click at the specified coordinates

void

All

mouseRightClickAt(int x, int y) Perform a right click at the specified coordinates

void

All

mouseDoubleClick(int x, int y) Perform a double click at the specified coordinates

void

All

mouseDragAndDrop(int srcX, int srcY, int destX, int destY) Drag and drop form a source coordinate to a destination coordinate

void

All

pressEnter() Press the ENTER key

void

All

typeText(String text) Write text as direct keyboard input (A-Z letters, space, numbers or dot only)

void

All

writeText(String text) Write text with the bot by pasting a given string from the clipboard

void

All

closeCurrentWindows() Close the current windows

void

All

closeCurrentWindows(boolean quit) Close the current windows or quit the current app (on macOS)

void

All

shortcut(int keycode) with the cmd or ctrl key (depending of the os) and another specified key

void

All

macShowSpotlight(String text) Do a "cmd + space" to show the Spotlight search box on mac

void

windowsShowStart(String text) Press on the "windows" key to show the start menu on Windows

void

messageSender(int x, int y, String text) Write string in a text box and "send" it one times (by pressing enter)

void

All

messageSender(int x, int y, String text, int frequency) Write string in a text box and "send" it several times (by pressing enter)

void

All

messageSender(int x, int y, String text, int frequency, int interval) Write string in a text box and "send" it several times (by pressing enter), at a given interval.

void

All

encode(String textToEncode) Encode a string using BASE64

static String

All

decode(String textToDecode) Decode a BASE64 string

static String

All

About OS exclusive methods

Methods starting with mac or windows, for instance macShowSpotlight(), are exclusive to their operating system. You should only use them on the appropriate OS. Of course, other methods can be use on all systems.

Last updated

Was this helpful?