boolean (final VirtualFile vf) { final String url = vf.getUrl(); for (String excludedByOtherVcs : myExcludedByOthers) { // use the fact that they are sorted if (url.length() > excludedByOtherVcs.length()) return true; if (url.startsWith(excludedByOtherVcs)) return false; } return true; }