public class RumbaScreen extends RumbaObject
Modifier | Constructor and Description |
---|---|
protected |
RumbaScreen(JtfObjectHandle handle,
Desktop desktop)
Creates a new RumbaScreen with a JtfObjectHandle.
|
Modifier and Type | Method and Description |
---|---|
void |
clear()
Clears the screen by sending the "clear" key.
|
void |
connect()
Connects to the hosts in the current configuration.
|
void |
connect(int screenUpdateWaitCount)
Connects to the hosts in the current configuration.
|
void |
connect(int screenUpdateWaitCount,
int timeout)
Connects to the hosts in the current configuration.
|
void |
disconnect()
Disconnects the current connection.
|
Color |
getBackgroundColor()
Gets the background color of the display control.
|
List<RumbaCharacterAttribute> |
getCharacterAttributes(TextPosition position,
int length)
Gets the character attributes for length-number of characters starting at the given position.
|
int |
getCharacterSetId()
Gets a value that identifies the character set translation table used by the Display control.
|
int |
getColumnCount()
Gets a value that indicates the number of columns on the current screen.
|
String |
getContent(TextPosition fromPosition)
Retrieves a string containing the screen without line breaks starting at the specified text position.
|
String |
getContent(TextPosition fromPosition,
int length)
Retrieves a string containing the screen without line breaks starting at the specified text position.
|
int |
getCursorColumn()
Gets the column position of the cursor on the screen.
|
int |
getCursorLine()
Gets the line position of the cursor on the screen.
|
TextPosition |
getCursorPosition()
Gets the current cursor position on the screen.
|
String |
getHostDeviceName()
Gets the host device name.
|
String |
getHostIpAddress()
Gets the host IP address.
|
int |
getLineCount()
Gets a value that indicates the number of lines on the current screen.
|
List<String> |
getLines()
Retrieves a clipping of the screen and returns the selected lines in a list of strings.
|
List<String> |
getLines(TextPosition fromPosition)
Retrieves a clipping of the screen and returns the selected lines in a list of strings.
|
List<String> |
getLines(TextPosition fromPosition,
TextPosition toPosition)
Retrieves a clipping of the screen and returns the selected lines in a list of strings.
|
int |
getScreenId()
Gets the screen id.
|
TextPosition |
getScreenSize()
Gets the size of the screen in text lines and columns.
|
String |
getSessionName()
Gets the session name.
|
boolean |
isHostConnected()
Gets a value that indicates if the host is connected.
|
boolean |
isKeyboardLocked()
Gets a value that indicates whether keyboard input is inhibited.
|
boolean |
isSupportsStructuredFields()
Gets a value that indicates if the host supports structured field decoding.
|
void |
reset()
Resets the screen by sending the "reset" key.
|
void |
setCursorPosition(TextPosition position)
Moves the cursor to the given position of the screen.
|
void |
submit()
Submits the entered data to the server by sending the "submit" key.
|
void |
waitForHostConnected()
Waits until the session is connected.
|
void |
waitForHostConnected(int timeout)
Waits until the session is connected.
|
void |
writeText(String text)
Writes text on the screen.
|
void |
writeText(String text,
TextPosition position)
Writes text on the screen.
|
click, click, click, click, doubleClick, doubleClick, doubleClick, doubleClick, isFocused, mouseMove, mouseMove, pressKeys, pressKeys, pressMouse, pressMouse, pressMouse, pressMouse, releaseKeys, releaseKeys, releaseMouse, releaseMouse, releaseMouse, releaseMouse, sendKeys, setFocus, synchSendKeys, synchSendKeys, synchSendKeys, typeKeys, typeKeys, typeKeys, typePasswordKeys, typePasswordKeys, typePasswordKeys
captureBitmap, captureBitmap, exists, exists, generateLocator, getChildren, getDynamicMethodList, getParent, getPropertyList, getRect, getRect, getText, getValue, highlightObject, highlightObject, highlightObject, invokeMethods, textCapture, textCapture, textClick, textClick, textClick, textClick, textClick, textClick, textExists, textExists, textExists, textExists, textExists, textRectangle, textRectangle, textRectangle, textRectangle, textRectangle, waitForChildDisappearance, waitForChildDisappearance, waitForDisappearance, waitForDisappearance, waitForObject, waitForObject, waitForProperty, waitForProperty
equals, exists, find, find, findAll, findAll, getCustomTypeName, getDesktop, getHandle, getLocator, getProperty, getTypeName, hashCode, imageClick, imageClick, imageClick, imageClick, imageClick, imageClick, imageClickFile, imageClickFile, imageClickFile, imageClickFile, imageClickFile, imageClickFile, imageExists, imageExists, imageExists, imageExistsFile, imageExistsFile, imageExistsFile, imageRectangle, imageRectangle, imageRectangle, imageRectangleFile, imageRectangleFile, imageRectangleFile, invoke, preventFinalLocator, setProperty, toString
protected RumbaScreen(JtfObjectHandle handle, Desktop desktop)
handle
- the handle that identifies the RumbaScreendesktop
- the desktop on which this object livespublic void clear()
public void connect()
public void connect(int screenUpdateWaitCount)
screenUpdateWaitCount
- the number of screen updates that need to be awaited until the first stable screen is ready for further interaction. Defaults to 1. If screenUpdateWaitCount is zero, no synchronization is done and the parameter timeout is ignored.public void connect(int screenUpdateWaitCount, int timeout)
screenUpdateWaitCount
- the number of screen updates that need to be awaited until the first stable screen is ready for further interaction. Defaults to 1. If screenUpdateWaitCount is zero, no synchronization is done and the parameter timeout is ignored.timeout
- the timeout in milliseconds. Defaults to 30000ms. If timeout is exceeded, an exception is thrown.public void disconnect()
public List<RumbaCharacterAttribute> getCharacterAttributes(TextPosition position, int length)
position
- the position where the retrieval should startlength
- the amount of characters whose attributes should be returnedpublic String getContent(TextPosition fromPosition)
Position values must be greater than 0 and less than the corresponding screen dimension.
fromPosition
- the start position on the screen, starting with 1 for the first column or linepublic String getContent(TextPosition fromPosition, int length)
Position values must be greater than 0 and less than the corresponding screen dimension.
fromPosition
- the start position on the screen, starting with 1 for the first column or linelength
- the number of characters on the screen to read. A specified length must be greater than -1. Reading stops at the end of the screen. If omitted the content to the end of the screen is returned.public List<String> getLines()
public List<String> getLines(TextPosition fromPosition)
fromPosition
- the upper left position of the clipping on the screen, starting with 1 for the first line or column. Position values must be greater than 0 and less than the corresponding screen dimension, otherwise an Exception will be thrown.public List<String> getLines(TextPosition fromPosition, TextPosition toPosition)
fromPosition
- the upper left position of the clipping on the screen, starting with 1 for the first line or column. Position values must be greater than 0 and less than the corresponding screen dimension, otherwise an Exception will be thrown.toPosition
- the lower right position of the clipping on the screen. An exception will be thrown if the relative position to $fromPosition$ is invalid. Position values must be greater than 0 and less than the corresponding screen dimension, otherwise an Exception will be thrown.public void reset()
public void setCursorPosition(TextPosition position)
position
- the position where the cursor should be moved to, starting with 1 for the first line or columnpublic void submit()
public void waitForHostConnected()
public void waitForHostConnected(int timeout)
timeout
- the timeout in milliseconds. Defaults to 30000ms. If timeout is exceeded, an exception is thrown.public void writeText(String text)
If no Position is specified the current cursor position is the place for insertion.
text
- text which is written to the screenpublic void writeText(String text, TextPosition position)
If no Position is specified the current cursor position is the place for insertion.
text
- text which is written to the screenposition
- the starting position of insertion, starting with 1 for the first line or columnpublic Color getBackgroundColor()
public int getCharacterSetId()
public int getColumnCount()
public int getCursorColumn()
public int getCursorLine()
public TextPosition getCursorPosition()
public boolean isHostConnected()
public String getHostDeviceName()
public String getHostIpAddress()
public boolean isKeyboardLocked()
public int getLineCount()
public int getScreenId()
public TextPosition getScreenSize()
public String getSessionName()
public boolean isSupportsStructuredFields()
Copyright 2009-2012 Micro Focus. All Rights Reserved.