Package de.alpharogroup.swing.robot
Class RobotExtensions
- java.lang.Object
-
- de.alpharogroup.swing.robot.RobotExtensions
-
public class RobotExtensions extends java.lang.ObjectThe classRobotExtensions.
-
-
Constructor Summary
Constructors Constructor Description RobotExtensions()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static intgetKeyCode(char character)Gets the key code from the given char.static voidtypeCharacter(java.awt.Robot robot, char character)Types the given char with the given robot.static voidtypeString(java.awt.Robot robot, java.lang.String input)Type the given string with the given robot.
-
-
-
Method Detail
-
getKeyCode
public static int getKeyCode(char character) throws java.lang.IllegalAccessException, java.lang.NoSuchFieldExceptionGets the key code from the given char.- Parameters:
character- the character- Returns:
- the key code
- Throws:
java.lang.IllegalAccessException- the illegal access exceptionjava.lang.NoSuchFieldException- the no such field exception
-
typeCharacter
public static void typeCharacter(java.awt.Robot robot, char character) throws java.lang.IllegalAccessException, java.lang.NoSuchFieldExceptionTypes the given char with the given robot.- Parameters:
robot- the robotcharacter- the character- Throws:
java.lang.IllegalAccessException- the illegal access exceptionjava.lang.NoSuchFieldException- the no such field exception
-
typeString
public static void typeString(java.awt.Robot robot, java.lang.String input) throws java.lang.NoSuchFieldException, java.lang.IllegalAccessExceptionType the given string with the given robot.- Parameters:
robot- the robotinput- the input- Throws:
java.lang.NoSuchFieldException- the no such field exceptionjava.lang.IllegalAccessException- the illegal access exception
-
-