Bug 305114 [CommonNavigator] ResourceSelectionUtil has been deprecated without public replacement
Public API class org.eclipse.ui.views.navigator.ResourceSelectionUtil has been deprecated in 3.5 with the hint to "use the Common Navigator Framework classes instead", but the CNF counterpart is internal.
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/navigator/ResourceSelectionUtil.java
public static boolean allResourcesAreOfType(IStructuredSelection selection,
            int resourceMask) {
        Iterator resources = selection.iterator();
        while (resources.hasNext()) {
            Object next = resources.next();
            if (!(next instanceof IResource)) {
				return false;
			}
            if (!resourceIsType((IResource) next, resourceMask)) {
				return false;
			}
        }
        return true;
    }
    /**
     * Returns the selection adapted to IResource. Returns null
     * if any of the entries are not adaptable.
     * 
     * @param selection the selection
     * @param resourceMask resource mask formed by bitwise OR of resource type
     *   constants (defined on <code>IResource</code>)
     * @return IStructuredSelection or null if any of the entries are not adaptable.
     * @see IResource#getType()
     */
    public static IStructuredSelection allResources(
            IStructuredSelection selection, int resourceMask) {
        Iterator adaptables = selection.iterator();
        List result = new ArrayList();
        while (adaptables.hasNext()) {
            Object next = adaptables.next();