Bug 53603 [search] the new search view needs expand all/collapse all actions
to make it convenient to work with the tree there should be both expand and collapse all action provided in the toolbar
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/search/JavaSearchResultPage.java
return MessageFormat.format(message, new Object[] { label, new Integer(getFilteredMatchCount()) });
			}
		}
		return label;
	}
	private int getMatchFiltersCount() {
		MatchFilter[] filters= getMatchFilters();
		AbstractTextSearchResult result= getInput();
		if (result == null)
			return 0;
		int filterCount= 0;
		for (int i= 0; i < filters.length; i++) {
			if (filters[i].isApplicable((JavaSearchQuery) result.getQuery()))
				filterCount++;
		}
		return filterCount;
	}
	private int getFilteredMatchCount() {
		AbstractTextSearchResult result= getInput();
		if (result == null)
			return 0;
		Object[] elements= result.getElements();
		int count= 0;
		for (int i= 0; i < elements.length; i++) {
			count+= getDisplayedMatchCount(elements[i]);
		}
		return count;
	}
}