Esempio n. 1
0
 private TreeItem getTestDescriptionItem(String descriptionStr) {
   for (TreeItem item : treeStore.getRootItems()) {
     if (descriptionStr.equals(item.get(NAME))) {
       return item;
     }
   }
   TreeItem description = new TreeItem(descriptionStr);
   description.put(NAME, descriptionStr);
   treeStore.add(description);
   return description;
 }
Esempio n. 2
0
  // clear everything but Session Information
  public void clearTreeStore() {

    for (TreeItem root : treeStore.getRootItems()) {
      if (root.getKey().equals(SESSION_INFO_ID)) {
        continue;
      }
      for (TreeItem test : treeStore.getChildren(root)) {
        for (TreeItem item : treeStore.getChildren(test)) {
          if (TEST_INFO.equals(item.get(NAME))) {
            continue;
          }
          removeWithParent(item);
        }
      }
    }
  }