Bug 57629 Hierarchy view shows too many types [type hierarchy]
Try opening the hierarchy view on the org.eclipse.ui.internal package. You end up with tons of types. It's not obvious why many of the types are being included. I have a working set with only 10 types from this package selected. Yet there are hundreds of types in the package hierarchy view, including interfaces which doen't even have implementors. So you get all of these root interfaces which are grayed out with no children. Even the class "Action" is showing up under Object, grayed out, without any subtypes present in the working set.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyContentProvider.java
import org.eclipse.jdt.internal.corext.util.JavaModelUtil;
/**
 * Base class for content providers for type hierarchy viewers.
 * Implementors must override 'getTypesInHierarchy'.
 * Java delta processing is also performed by the content provider
 */
public abstract class TypeHierarchyContentProvider implements ITreeContentProvider, IWorkingCopyProvider {
	protected static final Object[] NO_ELEMENTS= new Object[0];
	
	protected TypeHierarchyLifeCycle fTypeHierarchy;
	protected IMember[] fMemberFilter;
	
	protected TreeViewer fViewer;
	private ViewerFilter fWorkingSetFilter;
	
	public TypeHierarchyContentProvider(TypeHierarchyLifeCycle lifecycle) {
		fTypeHierarchy= lifecycle;
		fMemberFilter= null;
		fWorkingSetFilter= null;
	}
	
	/**
	 * Sets members to filter the hierarchy for. Set to <code>null</code> to disable member filtering.
	 * When member filtering is enabled, the hierarchy contains only types that contain
	 * an implementation of one of the filter members and the members themself.
	 * The hierarchy can be empty as well.
	 */
	public void setMemberFilter(IMember[] memberFilter) {
		fMemberFilter= memberFilter;
	}