private void print(final HtmlPrinter printer, final Priority priority, final int count) { print(printer, priority.getLocalizedString(), count); }
/** * Returns the annotations with {@link Priority#HIGH}. * * @return the annotations with {@link Priority#HIGH} */ public DefaultAnnotationContainer getHigh() { return new DefaultAnnotationContainer(Priority.HIGH.getLocalizedString(), getHighAnnotations()); }
/** * Returns a tooltip showing the distribution of priorities for this container. * * @return a tooltip showing the distribution of priorities */ public String getToolTip() { StringBuilder message = new StringBuilder(); String separator = " - "; for (Priority priority : Priority.values()) { if (hasAnnotations(priority)) { message.append(priority.getLocalizedString()); message.append(":"); message.append(getNumberOfAnnotations(priority)); message.append(separator); } } return StringUtils.removeEnd(message.toString(), separator); }
/** * Returns the annotations with {@link Priority#LOW}. * * @return the annotations with {@link Priority#LOW} */ public DefaultAnnotationContainer getLow() { return new DefaultAnnotationContainer(Priority.LOW.getLocalizedString(), getLowAnnotations()); }
/** * Returns the annotations with {@link Priority#LOW}. * * @return the annotations with {@link Priority#LOW} */ public DefaultAnnotationContainer getLow() { return new DefaultAnnotationContainer(Priority.LOW.getLocalizedString(), getLowAnnotations()); }
/** * Returns the annotations with {@link Priority#HIGH}. * * @return the annotations with {@link Priority#HIGH} */ public DefaultAnnotationContainer getHigh() { return new DefaultAnnotationContainer(Priority.HIGH.getLocalizedString(), getHighAnnotations()); }
/** * Returns the annotations with {@link Priority#NORMAL}. * * @return the annotations with {@link Priority#NORMAL} */ public DefaultAnnotationContainer getNormal() { return new DefaultAnnotationContainer(Priority.NORMAL.getLocalizedString(), getNormalAnnotations()); }
/** * Returns a tooltip showing the distribution of priorities for this container. * * @return a tooltip showing the distribution of priorities */ public String getToolTip() { StringBuilder message = new StringBuilder(); String separator = " - "; for (Priority priority : Priority.values()) { if (hasAnnotations(priority)) { message.append(priority.getLocalizedString()); message.append(':'); message.append(getNumberOfAnnotations(priority)); message.append(separator); } } return StringUtils.removeEnd(message.toString(), separator); }
/** * Returns the annotations with {@link Priority#NORMAL}. * * @return the annotations with {@link Priority#NORMAL} */ public DefaultAnnotationContainer getNormal() { return new DefaultAnnotationContainer(Priority.NORMAL.getLocalizedString(), getNormalAnnotations()); }
private void createAllMessage(final StringBuilder logger, final int annotationCount, final String threshold, final int delta, final Priority... priorities) { if (priorities.length == 1) { Priority priority = priorities[0]; if (annotationCount == 1) { logger.append(Messages.BuildResultEvaluator_unstable_one_all_priority( threshold, delta, priorities[0].getLocalizedString(), url, getPriorityUrl(priority))); } else { logger.append(Messages.BuildResultEvaluator_unstable_all_priority(annotationCount, threshold, delta, priorities[0].getLocalizedString(), url, getPriorityUrl(priority))); } } else { if (annotationCount == 1) { logger.append(Messages.BuildResultEvaluator_unstable_one_all( threshold, delta, url)); } else { logger.append(Messages.BuildResultEvaluator_unstable_all(annotationCount, threshold, delta, url)); } } }
private void createNewMessage(final StringBuilder logger, final int annotationCount, final String threshold, final int delta, final Priority... priorities) { String newUrl = url + "/new"; if (priorities.length == 1) { Priority priority = priorities[0]; if (annotationCount == 1) { logger.append(Messages.BuildResultEvaluator_unstable_one_new_priority(threshold, delta, priorities[0].getLocalizedString(), newUrl, getPriorityUrl(priority))); } else { logger.append(Messages.BuildResultEvaluator_unstable_new_priority( annotationCount, threshold, delta, priorities[0].getLocalizedString(), newUrl, getPriorityUrl(priority))); } } else { if (annotationCount == 1) { logger.append(Messages.BuildResultEvaluator_unstable_one_new(threshold, delta, newUrl)); } else { logger.append(Messages.BuildResultEvaluator_unstable_new(annotationCount, threshold, delta, newUrl)); } } }