Пример #1
0
 /**
  * Get resources files in quick fix dialog.
  *
  * @return the resources
  */
 public List<String> getResources() {
   List<String> resources = new ArrayList<String>();
   Table resourcesTable = new DefaultTable(1);
   int count = resourcesTable.rowCount();
   for (int i = 0; i < count; i++) {
     resources.add(resourcesTable.getItem(i).getText());
   }
   return resources;
 }
Пример #2
0
 /**
  * Get available fixes provided by quick fix.
  *
  * @return available fixes
  */
 public List<String> getAvailableFixes() {
   List<String> fixes = new ArrayList<String>();
   Table fixesTable = new DefaultTable(0);
   int count = fixesTable.rowCount();
   for (int i = 0; i < count; i++) {
     fixes.add(fixesTable.getItem(i).getText());
   }
   return fixes;
 }
Пример #3
0
 /**
  * Select fix in available fixes with provided text.
  *
  * @param fix the fix
  */
 public void selectFix(String fix) {
   Table fixTable = new DefaultTable(0);
   int count = fixTable.rowCount();
   for (int i = 0; i < count; i++) {
     String fixInTable = fixTable.getItem(i).getText();
     if (fixInTable.contains(fix)) {
       fixTable.select(fixInTable);
       break;
     }
   }
 }