public class CFHTMLTable extends CFComponent
ComponentFunction.Window
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ACTIVATECELL |
static java.lang.String |
ASSIGNCELLCONTAINSTEXTROW |
static java.lang.String |
ASSIGNCELLTEXTROW |
static java.lang.String |
ASSIGNVARIABLECELLTEXT |
static java.lang.String |
CAPTUREFUZZYRANGETOFILE |
static java.lang.String |
CAPTURERANGETOFILE |
static java.lang.String |
CLICKCELL |
protected java.lang.String |
detail |
static java.lang.String |
DOUBLECLICKCELL |
protected java.lang.String |
msg |
static java.lang.String |
RIGHTCLICKCELL |
static java.lang.String |
SELECTCELL |
static java.lang.String |
SELECTCELLCONTAINSTEXTFIND |
static java.lang.String |
SELECTCELLTEXT |
static java.lang.String |
SELECTCELLTEXTFIND |
static java.lang.String |
SELECTCELLTEXTSPECIAL |
static java.lang.String |
SELECTFUZZYCELLTEXT |
static java.lang.String |
SELECTFUZZYCELLTEXTFIND |
static java.lang.String |
VERIFYCELLEDITABLE |
static java.lang.String |
VERIFYCELLTEXT |
static java.lang.String |
VERIFYCELLTEXTCONTAINS |
static java.lang.String |
VERIFYCELLTEXTFIND |
static java.lang.String |
VERIFYCELLVALUE |
static java.lang.String |
VERIFYCOLUMNLABEL |
static java.lang.String |
VERIFYFUZZYCELLTEXT |
static java.lang.String |
VERIFYFUZZYCELLTEXTCONTAINS |
static java.lang.String |
VERIFYFUZZYCELLTEXTFIND |
compObject, keysparser, robot, selenium, sHelper, sUtils, winObject
action, ALTCLICK, ALTLEFTDRAG, altText, ASSIGNPROPERTYVARIABLE, CAPTUREOBJECTDATATOFILE, CAPTUREPROPERTIESTOFILE, CAPTUREPROPERTYTOFILE, CLEARAPPMAPCACHE, CLICK, CLOSEWINDOW, compName, COMPONENTCLICK, CTRLALTLEFTDRAG, CTRLCLICK, CTRLLEFTDRAG, CTRLRIGHTCLICK, CTRLSHIFTLEFTDRAG, DOUBLECLICK, GETGUIIMAGE, GETTEXTFROMGUI, GUIDOESEXIST, GUIDOESNOTEXIST, HOVERMOUSE, HSCROLLTO, INPUTCHARACTERS, INPUTKEYS, ISPROPERTYEXIST, iterator, LEFTDRAG, LOCATESCREENIMAGE, mapname, MAXIMIZE, MINIMIZE, MOUSECLICK, OBJECT_DATA, PARAM_FILTER, PARAM_UUID, PROPERTY_DOT_itemText, PROPERTY_innerHTML, PROPERTY_innerText, PROPERTY_Items, PROPERTY_text, PROPERTY_textContent, RELATIVE_TO_PARENT, RELATIVE_TO_SCREEN, RESTORE, RIGHTCLICK, RIGHTDRAG, SAVETEXTFROMGUI, SELECTMENUITEM, SELECTMENUITEMCONTAINS, SENDEVENT, SETPOSITION, SETPROPERTYVALUE, SHIFTCLICK, SHIFTLEFTDRAG, TEST_DATA_SUFFIX, utils, VERIFYARRAYPROPERTYTOFILE, VERIFYBINARYFILETOFILE, VERIFYCLIPBOARDTOFILE, VERIFYFILETOFILE, VERIFYGUIIMAGETOFILE, VERIFYMENUITEM, VERIFYMENUITEMCONTAINS, VERIFYOBJECTDATATOFILE, VERIFYPROPERTY, VERIFYPROPERTYCONTAINS, VERIFYPROPERTYTOFILE, VERIFYTEXTFILETOFILE, VERIFYVALUECONTAINS, VERIFYVALUEEQUALS, VERIFYVALUES, VERIFYVALUESIGNORECASE, VSCROLLTO, WAITFORGUI, windowName
breakpointsOn, CASE_INSENSITIVE_FLAG, CASEINSENSITIVE_FLAG, clearProxiesAlways, commandLineBreakpoint, customStr, customText, DEBUG_MESSAGE, debugStr, debugText, DEFAULT_CUSTOM_PROCESSOR_PACKAGE, DEFAULT_CUSTOM_PROCESSOR_SUBPACKAGE, DEFAULT_PROCESSOR_PACKAGE, FAILED_MESSAGE, FAILED_OK_MESSAGE, failedStr, failedText, FAILURE_DETAIL, GENERIC_MESSAGE, genericStr, genericText, LINE_FAILURE_4, log, myBreakpointsOn, otherStr, otherText, PARAM_SIZE_1, PARAM_SIZE_2, PARAM_SIZE_3, PARAM_SIZE_4, params, PASSED_MESSAGE, passedStr, passedText, PRE_TXT_SUCCESS_4, PRE_TXT_SUCCESS_5, processorConfigSet, processorMap, recordProcessed, RECTYPE_DRIVER_COMMAND, RECTYPE_DRIVER_COMMAND_F, RECTYPE_DRIVER_COMMAND_W, RECTYPE_TEST_STEP, RECTYPE_TEST_STEP_F, RECTYPE_TEST_STEP_W, RFSMCache, RFSMOnly, RFT_FIND_SEARCH_MODE_ALGORITHM, RFT_FIND_SEARCH_MODE_CACHE, SAFS_CLEARPROXIESALWAYS_ITEM, SAFS_COMMANDLINEBREAKPOINT_ITEM, SAFS_COMMANDLINEBREAKPOINT_VARIABLE, SAFS_PARAMS_FILE, SAFS_RESBUN_NAME, SAFS_SECSWAITFORCOMPONENT_ITEM, SAFS_SECSWAITFORCOMPONENT_VARIABLE, SAFS_SECSWAITFORWINDOW_ITEM, SAFS_SECSWAITFORWINDOW_VARIABLE, SAFS_TESTDOMAINS_ITEM, SAFS_TESTDOMAINS_VARIABLE, secsWaitForComponent, secsWaitForWindow, SENT_MSG_3, testDomains, testRecordData, testrecordStackable, TXT_FAILURE_1, TXT_FAILURE_2, TXT_FAILURE_3, TXT_FAILURE_4, TXT_FAILURE_5, TXT_SUCCESS_1, TXT_SUCCESS_2, TXT_SUCCESS_2a, TXT_SUCCESS_3, TXT_SUCCESS_3a, TXT_SUCCESS_4, TXT_SUCCESS_5, unexpectedAlertBehaviour, WARNING_MESSAGE, WARNING_OK_MESSAGE, warningStr, warningText
Constructor and Description |
---|
CFHTMLTable() |
Modifier and Type | Method and Description |
---|---|
protected void |
actionCaptureRangeToFile(java.lang.String row,
java.lang.String column,
int rows,
int columns,
boolean fuzzy,
java.lang.String filename,
java.lang.String encoding) |
protected void |
actionVerify(int row,
int col,
java.lang.String column,
boolean fuzzy,
java.lang.String val) |
protected void |
commandAssignCellTextRow(boolean fuzzy) |
protected void |
commandCaptureRangeToFile(boolean fuzzy) |
protected void |
commandClickFind(boolean fuzzy) |
protected void |
commandVerifyCellTextFind(boolean fuzzy) |
protected void |
commandVerifyCellValue() |
protected void |
commandVerifyColumnLabel() |
protected void |
commandVerifyFuzzyCellText(boolean benchFuzzy) |
java.lang.Integer |
convertNum(java.lang.String number)
Note: As the method of super will subtract 1 from the returned value,
so that a 0-based index can be returned
But we need a 1-based index in this class, so I override the it and add 1 back. |
protected void |
doCellEditable() |
protected void |
doCellText() |
protected void |
doClicks() |
protected java.lang.String |
getCellText(int row,
int column) |
protected int |
getColi(boolean fuzzy,
java.lang.String column) |
protected int |
getColumnCount(java.lang.String tableXpath) |
protected java.util.List<java.lang.String> |
getHeaders(java.lang.String tableXpath) |
protected java.util.List<java.lang.String> |
getObjectData(java.lang.String row,
java.lang.String column,
int rows,
int columns,
boolean fuzzy) |
protected int |
getRowCount(java.lang.String tableXpath) |
protected int |
getRowi(boolean fuzzy,
java.util.List rowvals) |
protected java.awt.Rectangle |
getTableCellLocation(int row,
int column) |
protected java.lang.String[][] |
getTableContents(java.lang.String tableXpath) |
protected boolean |
hasHeader(java.lang.String tableXpath)
Note: This method only works for the simplest table
If the table is composite with another table and the other table has header , this method can't detect it. |
protected void |
localProcess() |
protected int |
paramColumn(java.util.Iterator iter,
boolean fuzzy)
Note: Consume one object from parameter 'iter'.
This object is a 'column number' or a 'column header'. |
protected int |
paramRow(java.util.Iterator iter,
boolean fuzzy)
Note: Consume one object from parameter 'iter'.
This object is a 'row number' or a 'row header'. 'row header' is the value of the cell from first column |
protected int |
paramRowFromColumns(java.util.Iterator iter,
boolean fuzzy)
Note: Consume objects from parameter 'iter'.
These objects are pairs of ('column number/column header', 'cell value'). These pairs are used as condition to match a row. |
protected java.lang.String |
paramRowIndexVariable(java.util.Iterator iter)
Note: Consume one object from parameter 'iter'.
This object is a variable name, it will be initialized to "". |
protected java.lang.String |
recRowCol(java.lang.String rec,
int row,
int col) |
protected boolean |
setVariableLogWhenFail(java.lang.String variable,
java.lang.String value)
Note: This method is used to store a value to a SAFS Variable.
If it fails to do that, it will set status code to failure and log failed message and return false. |
_maximize, _minimize, _restore, _setPosition, _setSize, action_getGuiImage, action_verifyGuiImageToFile, captureObjectData, closeWindow, componentClick, exist, getComponentBounds, getComponentRectangle, getComponentRectangleOnScreen, getProperties, getPropertyObject, getWindowRectangleOnScreen, inputKeystrokes, maximize, minimize, performHoverMouse, process, restore, scrollToAndClickComponent, scrollToComponent, setPosition, verifyProperty
_close, action_ComputedStyle, action_GetSaveTextFromGUI, action_showOnPage, assignPropertyVariable, captureObjectDataToFile, capturePropertiesToFile, capturePropertyToFile, checkForCoord, checkForCoord, clearAppMapCache, clearCache, close, componentExecutedFailureMessage, componentFailureMessage, componentProcess, componentSuccessMessage, convertCoords, convertLine, convertWindowPosition, ConvertWindowPosition, deduceImageRect, dragTo, executeScript, getAlternateParams, getHelpers, getHelpersWorker, getPossibleMapItem, getProperty, getPropertyCollection, getPropertyCollection, getRectangleImage, getStringValue, getUUIDBoolean, guiDoesExist, hoverMouse, hoverScreenLocation, isPropertyExist, issueFileErrorFailure, issueParameterCountFailure, issueParameterCountFailure, issueParameterValueFailure, issuePassedSuccess, issuePassedSuccessUsing, issueUnknownErrorFailure, isSupportedRecordType, locateScreenImage, lookupAppMapCoordReference, lookupAppMapLineReference, lookupAppMapNumReference, lookupAppMapReference, normalizeFileEncoding, normalizePropertyCollection, performDrag, performScorll, selectMenuItem, sendEvent, setIterator, setPropertyValue, setRectVars, showComponentAsMuchPossible, updateFromTestRecordData, verifyClipboardToFile, verifyFileToFile, verifyMenuItem, verifyObjectDataToFile, verifyPropertiesToFile, verifyPropertyContains, verifyPropertyToFile, verifyValueContains, verifyValues, waitForGUI, waitForObject
activateBreakpoint, checkBreakpoints, checkMyBreakpoints, deduceBenchFile, deduceDiffFile, deduceProjectFile, deduceTestFile, delay, distributeConfigInformation, getAbsolutFileName, getAppMapItem, getChainedProcessor, getClassInstance, getClearProxiesAlways, getCustomProcClassNames, getCustomProcInstancePath, getLogUtilities, getParams, getProcClassNames, getProcInstance, getProcInstancePath, getRequiredField, getSecsWaitForComponent, getSecsWaitForWindow, getStandardErrorMessage, getTestRecordData, getUnexpectedAlertBehaviour, getVariable, hasChainedProcessor, initProcessorAndProcess, instanceProcessorAndProcess, isBreakpointsOn, isComponentFunctionRecord, isDriverCommandRecord, isEngineCommandRecord, isMyBreakpointsOn, isRecordProcessed, isRFSMCache, isRFSMOnly, issueActionFailure, issueActionOnXFailure, issueErrorPerformingAction, issueErrorPerformingActionOnX, issueErrorPerformingActionUsing, issueInputRecordFailure, issueInputRecordFailure, issuePassedSuccess, logFailureMessage, normalizeTestFileName, paramsFailedMsg, paramsFailedMsg, popTestRecord, processCustomProcessor, processSubclassProcessor, pushTestRecord, setAtEndOfProcess, setBreakpointsOn, setChainedProcessor, setClearProxiesAlways, setCommandLineBreakpoint, setCustomProcInstancePath, setLogUtilities, setMyBreakpointsOn, setParams, setProcInstance, setProcInstancePath, setRecordProcessed, setRFSMCache, setRFSMOnly, setSecsWaitForComponent, setSecsWaitForWindow, setTestDomains, setTestRecordData, setUnexpectedAlertBehaviour, setVariable, standardFailureMessage, substituteVariable, validateParamSize, validProcessorClassName
public static final java.lang.String ACTIVATECELL
public static final java.lang.String ASSIGNVARIABLECELLTEXT
public static final java.lang.String CLICKCELL
public static final java.lang.String DOUBLECLICKCELL
public static final java.lang.String SELECTCELLTEXTSPECIAL
public static final java.lang.String VERIFYCELLEDITABLE
public static final java.lang.String VERIFYCELLTEXT
public static final java.lang.String VERIFYCELLTEXTCONTAINS
public static final java.lang.String SELECTCELL
public static final java.lang.String CAPTURERANGETOFILE
public static final java.lang.String CAPTUREFUZZYRANGETOFILE
public static final java.lang.String ASSIGNCELLCONTAINSTEXTROW
public static final java.lang.String ASSIGNCELLTEXTROW
public static final java.lang.String RIGHTCLICKCELL
public static final java.lang.String SELECTCELLCONTAINSTEXTFIND
public static final java.lang.String SELECTCELLTEXT
public static final java.lang.String SELECTCELLTEXTFIND
public static final java.lang.String SELECTFUZZYCELLTEXT
public static final java.lang.String SELECTFUZZYCELLTEXTFIND
public static final java.lang.String VERIFYCELLTEXTFIND
public static final java.lang.String VERIFYCELLVALUE
public static final java.lang.String VERIFYCOLUMNLABEL
public static final java.lang.String VERIFYFUZZYCELLTEXT
public static final java.lang.String VERIFYFUZZYCELLTEXTCONTAINS
public static final java.lang.String VERIFYFUZZYCELLTEXTFIND
protected java.lang.String msg
protected java.lang.String detail
protected void localProcess()
localProcess
in class CFComponent
protected java.awt.Rectangle getTableCellLocation(int row, int column) throws SAFSException
SAFSException
protected void doClicks()
protected void doCellText()
protected void doCellEditable()
protected boolean hasHeader(java.lang.String tableXpath)
tableXpath
- protected java.lang.String recRowCol(java.lang.String rec, int row, int col)
rec
- The table xpathrow
- The row number, begin from 1col
- The column number, begin from 1protected java.util.List<java.lang.String> getHeaders(java.lang.String tableXpath)
tableXpath
- The xpath representing the table.protected int getRowCount(java.lang.String tableXpath)
tableXpath
- The xpath representing the tableprotected int getColumnCount(java.lang.String tableXpath)
tableXpath
- The xpath representing the tableprotected java.lang.String[][] getTableContents(java.lang.String tableXpath)
tableXpath
- The xpath representing the table.protected java.util.List<java.lang.String> getObjectData(java.lang.String row, java.lang.String column, int rows, int columns, boolean fuzzy) throws SAFSException
row
- The beginning row numbercolumn
- The beginning column number or the beginning column header namerows
- The number of rows to capturecolumns
- The number of columns to capturefuzzy
- If it is true, the header will be matched partially and ignoring caseSAFSException
protected void actionCaptureRangeToFile(java.lang.String row, java.lang.String column, int rows, int columns, boolean fuzzy, java.lang.String filename, java.lang.String encoding) throws SAFSException
row
- The beginning row numbercolumn
- The beginning column number or the beginning column header namerows
- The number of rows to capturecolumns
- The number of columns to capturefuzzy
- If it is true, the header will be matched partially and ignoring casefilename
- The file to which the table content will be writtenencoding
- The encoding to be used to write a file.SAFSException
protected void commandCaptureRangeToFile(boolean fuzzy) throws SAFSException
SAFSException
protected int getColi(boolean fuzzy, java.lang.String column)
fuzzy
- If it is true, the header will be matched partially and ignoring case.column
- The column header to match.protected int getRowi(boolean fuzzy, java.util.List rowvals)
fuzzy
- If it is true, the header will be matched partially and ignoring case.rowvals
- A list of list of pair (Integer columnIndex, String value)protected java.lang.String getCellText(int row, int column)
row
- Row number, begin from 1.column
- Column number, begin from 1.protected java.lang.String paramRowIndexVariable(java.util.Iterator iter) throws SAFSException, SAFSParamException
iter
- A Iterator, contains the parameters of SAFS's keywordSAFSException
SAFSParamException
protected int paramRow(java.util.Iterator iter, boolean fuzzy) throws SAFSParamException
iter
- A Iterator, contains the parameters of SAFS's keywordfuzzy
- boolean, if the comparison is case-sensitiveSAFSParamException
protected int paramColumn(java.util.Iterator iter, boolean fuzzy) throws SAFSParamException
iter
- A Iterator, contains the parameters of SAFS's keywordfuzzy
- boolean, if the comparison is case-sensitiveSAFSParamException
protected int paramRowFromColumns(java.util.Iterator iter, boolean fuzzy) throws SAFSParamException
iter
- A Iterator, contains the parameters of SAFS's keywordfuzzy
- boolean, if the comparison is case-sensitiveSAFSParamException
protected boolean setVariableLogWhenFail(java.lang.String variable, java.lang.String value) throws SAFSException
variable
- The SAFS Variable to store value.value
- The value to be stored.SAFSException
protected void commandAssignCellTextRow(boolean fuzzy) throws SAFSException
SAFSException
protected void commandClickFind(boolean fuzzy) throws SAFSException
SAFSException
protected void commandVerifyCellTextFind(boolean fuzzy) throws SAFSException
SAFSException
protected void commandVerifyCellValue() throws SAFSException
SAFSException
protected void commandVerifyFuzzyCellText(boolean benchFuzzy) throws SAFSException
SAFSException
protected void commandVerifyColumnLabel() throws SAFSException
SAFSException
protected void actionVerify(int row, int col, java.lang.String column, boolean fuzzy, java.lang.String val) throws SAFSException
SAFSException
public java.lang.Integer convertNum(java.lang.String number)
convertNum
in class ComponentFunction
number
- The number to be converted to integerCopyright © SAS Institute. All Rights Reserved.