本文整理汇总了Java中org.netbeans.jemmy.operators.JTableOperator.findCellRow方法的典型用法代码示例。如果您正苦于以下问题:Java JTableOperator.findCellRow方法的具体用法?Java JTableOperator.findCellRow怎么用?Java JTableOperator.findCellRow使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.netbeans.jemmy.operators.JTableOperator
的用法示例。
在下文中一共展示了JTableOperator.findCellRow方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: selectPlugins
import org.netbeans.jemmy.operators.JTableOperator; //导入方法依赖的package包/类
/** Selects plugins in the table.
* @param pluginNames array of plugin names to be selected
*/
public void selectPlugins(String[] pluginNames) {
JTableOperator tableOper = table();
for (int i = 0; i < pluginNames.length; i++) {
String name = pluginNames[i];
int row = tableOper.findCellRow(name, new DefaultStringComparator(true, true), 1, 0);
if(row == -1) {
throw new JemmyException("Plugin "+name+" not found.");
}
tableOper.selectCell(row, 1);
tableOper.clickOnCell(row, 0);
}
}
示例2: selectTemplate
import org.netbeans.jemmy.operators.JTableOperator; //导入方法依赖的package包/类
public boolean selectTemplate(String abbrev) {
JTableOperator templatesTable1 = getTemplatesTable();
int row = templatesTable1.findCellRow(abbrev, 0, 0);
if(row==-1) return false;
templatesTable1.selectCell(row, 0);
return true;
}
示例3: selectDocument
import org.netbeans.jemmy.operators.JTableOperator; //导入方法依赖的package包/类
/** Pushes down arrow control button in top right corner intended to
* show list of opened documents and selects document with given name
* in the list.
*/
public static void selectDocument(String name) {
btDown().push();
JTableOperator tableOper = new JTableOperator(MainWindowOperator.getDefault());
int row = tableOper.findCellRow(name);
if (row > -1) {
tableOper.selectCell(row, 0);
} else {
throw new JemmyException("Cannot select document \"" + name + "\".");
}
}