Bug 77586 Build Path inclusion filters: filter language must be explained
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/TypeRestrictionEntryDialog.java
}
		ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(shell, lp, cp);
		dialog.setTitle(title);
		dialog.setValidator(validator);
		dialog.setMessage(message);
		dialog.addFilter(filter);
		dialog.setInput(currentSourceFolder);
		dialog.setInitialSelection(initialElement);
		dialog.setSorter(new ResourceSorter(ResourceSorter.NAME));
		
		if (dialog.open() == Window.OK) {
			Object[] objects= dialog.getResult();
			int existingSegments= currentSourceFolder.getFullPath().segmentCount();
			
			IPath[] resArr= new IPath[objects.length];
			for (int i= 0; i < objects.length; i++) {
				IResource currRes= (IResource) objects[i];
				IPath path= currRes.getFullPath().removeFirstSegments(existingSegments).makeRelative();
				if (currRes instanceof IContainer) {
					path= path.addTrailingSeparator();
				}
				resArr[i]= path;
			}
			return resArr;
		}
		return null;
	}	
	
}