本文整理汇总了Java中com.intellij.openapi.vfs.VfsUtilCore.isUnder方法的典型用法代码示例。如果您正苦于以下问题:Java VfsUtilCore.isUnder方法的具体用法?Java VfsUtilCore.isUnder怎么用?Java VfsUtilCore.isUnder使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.intellij.openapi.vfs.VfsUtilCore
的用法示例。
在下文中一共展示了VfsUtilCore.isUnder方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getNotExcludedRoots
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
private Set<VirtualFile> getNotExcludedRoots() {
Set<VirtualFile> roots = new LinkedHashSet<VirtualFile>();
String[] excludedRootUrls = getLibraryEditor().getExcludedRootUrls();
Set<VirtualFile> excludedRoots = new HashSet<VirtualFile>();
for (String url : excludedRootUrls) {
ContainerUtil.addIfNotNull(excludedRoots, VirtualFileManager.getInstance().findFileByUrl(url));
}
for (PersistentOrderRootType type : OrderRootType.getAllPersistentTypes()) {
VirtualFile[] files = getLibraryEditor().getFiles(type);
for (VirtualFile file : files) {
if (!VfsUtilCore.isUnder(file, excludedRoots)) {
roots.add(PathUtil.getLocalFile(file));
}
}
}
return roots;
}
示例2: isInTestSourceContent
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
public boolean isInTestSourceContent(@NotNull final VirtualFile fileOrDir) {
if (myProjectFileIndex.isInTestSourceContent(fileOrDir)) {
return true;
}
if (VfsUtilCore.isUnder(fileOrDir, myGeneratedTestRoots)) {
return true;
}
return false;
}
示例3: isInSourceContent
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
public boolean isInSourceContent(@NotNull final VirtualFile fileOrDir) {
if (myProjectFileIndex.isInSourceContent(fileOrDir)) {
return true;
}
if (VfsUtilCore.isUnder(fileOrDir, myRootToModuleMap.keySet())) {
return true;
}
return false;
}
示例4: isUnderRoots
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
private boolean isUnderRoots(@NotNull String url) {
for (VirtualFilePointerContainer container : myRoots.values()) {
if (VfsUtilCore.isUnder(url, Arrays.asList(container.getUrls()))) {
return true;
}
}
return false;
}
示例5: isUnderAnnotationRoot
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
public boolean isUnderAnnotationRoot(VirtualFile file) {
return VfsUtilCore.isUnder(file, initRoots());
}
示例6: contains
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
@Override
public boolean contains(@NotNull VirtualFile file) {
return VfsUtilCore.isUnder(file, myRoots);
}
示例7: isInSet
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
@Override
public boolean isInSet(@NotNull VirtualFile file) {
return VfsUtilCore.isUnder(file, getDirectories()) || cachedFiles.contains(file);
}
示例8: applyNotNull
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
@Override
public boolean applyNotNull(@NotNull final PyClass input) {
return VfsUtilCore.isUnder(input.getContainingFile().getVirtualFile(), mySourceRoots);
}
示例9: isAlreadyExcluded
import com.intellij.openapi.vfs.VfsUtilCore; //导入方法依赖的package包/类
public boolean isAlreadyExcluded(File f) {
String url = toUrl(f.getPath()).getUrl();
return VfsUtilCore.isUnder(url, Arrays.asList(myRootModel.getExcludeRootUrls()));
}