コード例 #1
0
 /**
  * Get a Collection containing all known bug category keys. E.g., "CORRECTNESS", "MT_CORRECTNESS",
  * "PERFORMANCE", etc.
  *
  * <p>Excludes hidden bug categories
  *
  * @return Collection of bug category keys.
  */
 public Collection<String> getBugCategories() {
   ArrayList<String> result = new ArrayList<String>(categoryDescriptionMap.size());
   for (BugCategory c : categoryDescriptionMap.values()) {
     if (!c.isHidden()) {
       result.add(c.getCategory());
     }
   }
   return result;
 }
コード例 #2
0
 /**
  * Set the metadata for a bug category. If the category's metadata has already been set, this does
  * nothing.
  *
  * @param bc the BugCategory object holding the metadata for the category
  * @return false if the category's metadata has already been set, true otherwise
  */
 public boolean registerBugCategory(BugCategory bc) {
   String category = bc.getCategory();
   if (categoryDescriptionMap.get(category) != null) {
     return false;
   }
   categoryDescriptionMap.put(category, bc);
   return true;
 }
コード例 #3
0
 protected boolean unRegisterBugCategory(BugCategory bc) {
   String category = bc.getCategory();
   categoryDescriptionMap.remove(category);
   return true;
 }