biz.neustar.wpm.api
Interface DesktopController


public interface DesktopController

An object that can be used to make Linux agents perform mouse/keyboard actions from the active VNC session.


Method Summary
 void click(int x, int y)
          Issues a normal left click at the specified X and Y coordinates.
 void close()
          Safely close the connection
 void keyPress(java.lang.String keycode)
          Issues a keyboard key press.
 void setWiggle(boolean wiggleOn)
          Continuously wiggle the mouse.
 void typeKeys(java.lang.String string)
          Issues a series of keyboard key presses keyPress(String), each followed by a short delay to simulate realistic typing speeds.
 

Method Detail

click

void click(int x,
           int y)
           throws java.io.IOException
Issues a normal left click at the specified X and Y coordinates.

Parameters:
x - the pixel locator for the X axis
y - the pixel locator for the Y axis
Throws:
java.io.IOException

keyPress

void keyPress(java.lang.String keycode)
              throws java.io.IOException
Issues a keyboard key press. The keycode must either be a single character ("w" or "W") or a string starting in the format of "\119", where 119 is the ASCII code off they key to press. Keycodes can be referenced in the Wikipedia article on ASCII.

Parameters:
keycode - the individual character or keycode to press
Throws:
java.io.IOException

typeKeys

void typeKeys(java.lang.String string)
              throws java.io.IOException
Issues a series of keyboard key presses keyPress(String), each followed by a short delay to simulate realistic typing speeds.

Parameters:
string - the string to type
Throws:
java.io.IOException

setWiggle

void setWiggle(boolean wiggleOn)
Continuously wiggle the mouse. Some content (e.g. Flash) won't load unless mouse movement is detected.

Parameters:
wiggleOn - when true, the mouse will automatically move

close

void close()
Safely close the connection


Copyright © 2014 Neustar, Inc. All Rights Reserved.