Services Builder for Screens

com.attachmate.common.eai.tasks
Interface INativeAccess

All Superinterfaces:
INativeAccessConstants
All Known Subinterfaces:
INativeAccessEx
All Known Implementing Classes:
ScreenNativeAccess, ScreenNativeAccessEx

public interface INativeAccess
extends INativeAccessConstants

Defines an API through which data from the screen may be accessed generically. There should be no distinction between terminal types. A common set of attributes and modes are provided in INativeAccessConstants.

See Also:
INativeAccessConstants, com.attachmate.common.ITask

Field Summary
static int PROPERTY_NOT_INITIALIZED
          reserved for interal use.
 
Fields inherited from interface com.attachmate.common.eai.tasks.INativeAccessConstants
ATTR_BLINK, ATTR_CHAR_SET_APL, ATTR_COLUMN_SEPARATOR, ATTR_DEFAULT, ATTR_HIGH_INTENSITY, ATTR_LEFT_LINE, ATTR_OVERLINE, ATTR_REVERSE, ATTR_RIGHT_LINE, ATTR_STRIKETHROUGH, ATTR_UNDERLINE, ATTR_VISIBLE, CMD_ATTENTION, CMD_CLEAR, CMD_CTRL, CMD_DISABLEFORMS, CMD_ENABLEFORMS, CMD_F1, CMD_F10, CMD_F11, CMD_F12, CMD_F13, CMD_F14, CMD_F15, CMD_F16, CMD_F17, CMD_F18, CMD_F19, CMD_F2, CMD_F20, CMD_F21, CMD_F22, CMD_F23, CMD_F24, CMD_F3, CMD_F4, CMD_F5, CMD_F6, CMD_F7, CMD_F8, CMD_F9, CMD_HELP, CMD_LOCAL, CMD_MESSAGE_WAIT, CMD_PA1, CMD_PA2, CMD_PA3, CMD_PRINT, CMD_RECEIVE, CMD_REFRESH_NULL, CMD_RESET, CMD_ROLLDOWN, CMD_ROLLUP, CMD_SPECIFY, CMD_SYSTEM_MODE, CMD_SYSTEM_REQUEST, CMD_TEST, CMD_TRANSMIT, CMD_TRANSMIT_LINE, CMD_TRANSMIT_SCREEN, CMD_WORKSTATION_MODE, COLOR_BG_BLACK, COLOR_BG_BLUE, COLOR_BG_DEFAULT, COLOR_BG_DK_BLUE, COLOR_BG_DK_GREEN, COLOR_BG_DK_MAGENTA, COLOR_BG_DK_RED, COLOR_BG_DK_TURQUOISE, COLOR_BG_DK_YELLOW, COLOR_BG_GRAY, COLOR_BG_GREEN, COLOR_BG_LT_GRAY, COLOR_BG_MAGENTA, COLOR_BG_MASK, COLOR_BG_RED, COLOR_BG_TURQUOISE, COLOR_BG_WHITE, COLOR_BG_YELLOW, COLOR_FG_BLACK, COLOR_FG_BLUE, COLOR_FG_DEFAULT, COLOR_FG_DK_BLUE, COLOR_FG_DK_GREEN, COLOR_FG_DK_MAGENTA, COLOR_FG_DK_RED, COLOR_FG_DK_TURQUOISE, COLOR_FG_DK_YELLOW, COLOR_FG_GRAY, COLOR_FG_GREEN, COLOR_FG_LT_GRAY, COLOR_FG_MAGENTA, COLOR_FG_MASK, COLOR_FG_RED, COLOR_FG_TURQUOISE, COLOR_FG_WHITE, COLOR_FG_YELLOW, ERROR_CODE_FATAL, ERROR_CODE_INPUT_INHIBITED_EXCEPTION, ERROR_CODE_KEYLOCK, ERROR_CODE_PROTECTED_FIELD_EXCEPTION, ERROR_CODE_SCREEN_CHANGED, ERROR_CODE_TIMEOUT, ERROR_CODE_TRUNCATED_EXCEPTION, ERROR_CODE_UNKNOWN, ERROR_CODE_UNKNOWN_KEYLOCK, FIELD_ALPHA_ONLY, FIELD_ALPHA_SHIFT, FIELD_ATTRIB_SPACE, FIELD_ATTRIBUTE, FIELD_AUTO_ENTER, FIELD_CHECK_MOD_10, FIELD_CHECK_MOD_11, FIELD_DIGITS, FIELD_EXIT_REQ, FIELD_LIGHT_PEN, FIELD_MAGNETIC_STRIP, FIELD_MANDATORY_ENTRY, FIELD_MANDATORY_FILL, FIELD_MARK_DUP, FIELD_MODE_BLOCK, FIELD_MODE_PROTECTED, FIELD_MODIFIED, FIELD_NUMERIC_ONLY, FIELD_NUMERIC_SHIFT, FIELD_RA_BLANKFILL, FIELD_RA_ZEROFILL, FIELD_RIGHT_JUSTIFIED, FIELD_SIGNED_NUMERIC, FIELD_TRIGGER, FIELD_TYPE_MESSAGE, FIELD_TYPE_TABLE, FIELD_TYPE_USER, FIELD_UPPERCASE, STATUS_DATA_CHANGED, STATUS_EOR, STATUS_FORMAT_CHANGED, STATUS_KBD_UNLOCK, STATUS_MESSAGE_WAITING, STATUS_SCREEN_ERASED, STATUS_SIZE_CHANGED, STATUS_TYPE_CHANGED, STR_FATAL_ERROR, STR_SCREEN_CHANGED, STR_WARNING, STR_WARNING_KEYLOCK, STR_WARNING_TIMEOUT, STR_WARNING_UNKNOWN, USE_SYSTEM_DEFAULT
 
Method Summary
 long[] getCharacterAttr()
          Gets the extended attribute bits for the entire screen.
 int getColumns()
          Gets the number of columns on the screen
 int getCommand()
          Gets the current execution command
 int getCurrentPage()
          Gets the current page number
 int getCursorColumn()
          Gets the current cursor column position
 int getCursorRow()
          Gets the current row position of the cursor
 long[] getFieldAttr()
          Gets the attribute bits for every field on the screen.
 long getFieldAttr(int fieldIndex)
          Gets the attribute bits of the desired field.
 int getFieldCount()
          Gets the number of fields on the current screen
 int[] getFieldEndColumn()
          Gets the ending column of each field on the screen.
 int getFieldEndColumn(int fieldIndex)
          Gets the ending column for the desired field.
 int[] getFieldEndRow()
          Gets the ending row of each field on the screen.
 int getFieldEndRow(int fieldIndex)
          Gets the ending row of the desired field.
 java.lang.String[] getFieldInputText()
          Gets the text from all pre-defined input fields on the screen.
 java.lang.String getFieldInputText(int fieldIndex)
          Gets the field input text from the desired field.
 int[] getFieldLength()
          Gets the field length for each field on the screen.
 int getFieldLength(int fieldIndex)
          Gets the length of the desired field.
 int[] getFieldPage()
          Gets the screen page of all of the fields.
 int getFieldPage(int fieldIndex)
          Gets the screen page of the desired field.
 int[] getFieldStartColumn()
          Gets the starting column for each field on the screen.
 int getFieldStartColumn(int fieldIndex)
          Gets the starting column of the desired field.
 int[] getFieldStartRow()
          Gets the starting row of every field on the screen.
 int getFieldStartRow(int fieldIndex)
          Gets the starting row of the desired field.
 java.lang.String[] getFieldText()
          Gets the text from all pre-defined fields on the screen.
 java.lang.String getFieldText(int fieldIndex)
          Gets the visible text from the desired field.
 int getHostFlags()
          Gets the host status flags.
 java.lang.String getHostMessage()
          Deprecated.  
 java.lang.String getHostType()
          Gets the type of the host connection
 int getPageCount()
          Gets the number of pages on a multi-page viewer
 java.lang.String getPoolName()
          Gets the pool name
 int getRows()
          Gets the number rows on the screen
 java.lang.String getScreenName()
          Gets the name of the host screen.
 int getSettleTime()
          Gets the amount of time that NativeAccess will wait for a screen to settle before the screen data is returned.
 java.lang.String getShare()
          Gets the session's context name.
 void setCommand(int command)
          Sets the command to execute on the screen.
 void setCurrentPage(int newPage)
          Sets the currently active page.
 void setCursorColumn(int inColumn)
          Moves the cursor horizontally to the specified column.
 void setCursorRow(int inRow)
          Moves the cursor vertically to the specified row.
 void setFieldInputText(int fieldIndex, java.lang.String fieldText)
          Sets the text in the desired input field.
 void setFieldInputText(java.lang.String[] fieldsText)
          Sets the text in all input fields.
 void setSettleTime(int milliseconds)
          Sets the settle time for the screen to become stable.
 void setShare(java.lang.String name)
          Sets the name of the NavMap.
 

Field Detail

PROPERTY_NOT_INITIALIZED

public static final int PROPERTY_NOT_INITIALIZED
reserved for interal use.

See Also:
Constant Field Values
Method Detail

getPoolName

public java.lang.String getPoolName()
Gets the pool name

Returns:
the name of the pool this bean is accessing.

getHostMessage

public java.lang.String getHostMessage()
Deprecated.  

Returns:
the host message or null if there is no message.

getHostFlags

public int getHostFlags()
Gets the host status flags.

Returns:
the host message flags.

getShare

public java.lang.String getShare()
Gets the session's context name.

Returns:
the name of the NavMap or null if the name was not set.

setShare

public void setShare(java.lang.String name)
Sets the name of the NavMap.

Parameters:
name - the name of the NavMap used by the target session

getScreenName

public java.lang.String getScreenName()
Gets the name of the host screen.

Returns:
the name of the current screen or null if the screen was not recognized.

getRows

public int getRows()
Gets the number rows on the screen

Returns:
the number of rows on the screen.

getColumns

public int getColumns()
Gets the number of columns on the screen

Returns:
the number of columns on the screen.

getCursorRow

public int getCursorRow()
Gets the current row position of the cursor

Returns:
the row that the cursor is on.

setCursorRow

public void setCursorRow(int inRow)
Moves the cursor vertically to the specified row.

Parameters:
inRow - the desired cursor row

getCursorColumn

public int getCursorColumn()
Gets the current cursor column position

Returns:
the column that the cursor is on.

setCursorColumn

public void setCursorColumn(int inColumn)
Moves the cursor horizontally to the specified column.

Parameters:
inColumn - the desired cursor column

getFieldCount

public int getFieldCount()
Gets the number of fields on the current screen

Returns:
the number of pre-defined fields on the screen.

getFieldText

public java.lang.String getFieldText(int fieldIndex)
Gets the visible text from the desired field.

Parameters:
fieldIndex - the index of the field to retrieve text from
Returns:
the visible text from the field

getFieldText

public java.lang.String[] getFieldText()
Gets the text from all pre-defined fields on the screen.

Returns:
an array of Strings, one for each field's text

getFieldPage

public int getFieldPage(int fieldIndex)
Gets the screen page of the desired field.

Parameters:
fieldIndex - the index of the field to retrieve the page from
Returns:
the field's screen page

getFieldPage

public int[] getFieldPage()
Gets the screen page of all of the fields.

Returns:
an array of integers, one for each field's screen page

getFieldInputText

public java.lang.String getFieldInputText(int fieldIndex)
Gets the field input text from the desired field.

Parameters:
fieldIndex - the index of the field to retrieve text from
Returns:
the field input text from the field

getFieldInputText

public java.lang.String[] getFieldInputText()
Gets the text from all pre-defined input fields on the screen. The array is sorted by field id.

Returns:
an array of Strings, one for each field's input text

setFieldInputText

public void setFieldInputText(int fieldIndex,
                              java.lang.String fieldText)
Sets the text in the desired input field.

Parameters:
fieldIndex - the index of the field to write to
fieldText - the text to write to the desired field

setFieldInputText

public void setFieldInputText(java.lang.String[] fieldsText)
Sets the text in all input fields. The array is sorted by field id.

Parameters:
fieldsText - an array of Strings to write to the screen's fields

getCharacterAttr

public long[] getCharacterAttr()
Gets the extended attribute bits for the entire screen.

Returns:
an array of longs representing the extended character attributes
See Also:
INativeAccessConstants

getFieldAttr

public long getFieldAttr(int fieldIndex)
Gets the attribute bits of the desired field.

Parameters:
fieldIndex - index of the desired field
Returns:
a long representing the field's attributes
See Also:
INativeAccessConstants

getFieldAttr

public long[] getFieldAttr()
Gets the attribute bits for every field on the screen.

Returns:
an array of longs representing the each field's attributes
See Also:
INativeAccessConstants

getFieldStartRow

public int getFieldStartRow(int fieldIndex)
Gets the starting row of the desired field.

Parameters:
fieldIndex - index of the desired field
Returns:
the row that the field begins on

getFieldStartRow

public int[] getFieldStartRow()
Gets the starting row of every field on the screen.

Returns:
an array of integers, one for each starting row

getFieldStartColumn

public int getFieldStartColumn(int fieldIndex)
Gets the starting column of the desired field.

Parameters:
fieldIndex - index of the desired field
Returns:
the column that the field starts on

getFieldStartColumn

public int[] getFieldStartColumn()
Gets the starting column for each field on the screen.

Returns:
an array of integers, one for each starting column

getFieldEndRow

public int getFieldEndRow(int fieldIndex)
Gets the ending row of the desired field.

Parameters:
fieldIndex - index for the desired field
Returns:
the row that the field ends on

getFieldEndRow

public int[] getFieldEndRow()
Gets the ending row of each field on the screen.

Returns:
an array of integers, one for each ending row.

getFieldEndColumn

public int getFieldEndColumn(int fieldIndex)
Gets the ending column for the desired field.

Parameters:
fieldIndex - index for the desired field
Returns:
the column that the field ends on

getFieldEndColumn

public int[] getFieldEndColumn()
Gets the ending column of each field on the screen.

Returns:
an array of integers, one for each ending column.

getFieldLength

public int getFieldLength(int fieldIndex)
Gets the length of the desired field.

Parameters:
fieldIndex - index of the desired field
Returns:
the length of the desired field

getFieldLength

public int[] getFieldLength()
Gets the field length for each field on the screen.

Returns:
an array of integers, one for each field length.

getHostType

public java.lang.String getHostType()
Gets the type of the host connection

Returns:
a String that represents the current host type.

setCommand

public void setCommand(int command)
Sets the command to execute on the screen. Does not execute the command. When execute is called, all modified fields are sent to the host, and the command is sent to the screen at the current cursor position. If command is null, execute refreshes the properties to reflect the current host screen. No command or data is sent to the host.

Parameters:
command - a string representing a command
See Also:
INativeAccessConstants

getCommand

public int getCommand()
Gets the current execution command

Returns:
an integer representing the command to execute on the screen.

setSettleTime

public void setSettleTime(int milliseconds)
Sets the settle time for the screen to become stable.

Parameters:
milliseconds - the number of milliseconds to wait for the screen to become stable

getSettleTime

public int getSettleTime()
Gets the amount of time that NativeAccess will wait for a screen to settle before the screen data is returned.

Returns:
the number of milliseconds to wait for the screen to become stable

getPageCount

public int getPageCount()
Gets the number of pages on a multi-page viewer

Returns:
the number of pages on the current screen.

getCurrentPage

public int getCurrentPage()
Gets the current page number

Returns:
the currently active page

setCurrentPage

public void setCurrentPage(int newPage)
Sets the currently active page.

Parameters:
newPage - the active page

Services Builder for Screens