本文整理汇总了Java中consulo.roots.impl.ProductionResourceContentFolderTypeProvider.getInstance方法的典型用法代码示例。如果您正苦于以下问题:Java ProductionResourceContentFolderTypeProvider.getInstance方法的具体用法?Java ProductionResourceContentFolderTypeProvider.getInstance怎么用?Java ProductionResourceContentFolderTypeProvider.getInstance使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类consulo.roots.impl.ProductionResourceContentFolderTypeProvider
的用法示例。
在下文中一共展示了ProductionResourceContentFolderTypeProvider.getInstance方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: filterResourceFiles
import consulo.roots.impl.ProductionResourceContentFolderTypeProvider; //导入方法依赖的package包/类
@NotNull
private static List<VirtualFile> filterResourceFiles(CompileContext compileContext, VirtualFile[] virtualFiles)
{
ProjectFileIndex fileIndex = ProjectFileIndex.getInstance(compileContext.getProject());
List<VirtualFile> list = new ArrayList<>(virtualFiles.length);
for(VirtualFile file : virtualFiles)
{
ContentFolderTypeProvider provider = fileIndex.getContentFolderTypeForFile(file);
if(provider == ProductionResourceContentFolderTypeProvider.getInstance() || provider == TestResourceContentFolderTypeProvider.getInstance())
{
continue;
}
list.add(file);
}
return list;
}
示例2: toField
import consulo.roots.impl.ProductionResourceContentFolderTypeProvider; //导入方法依赖的package包/类
private CommitableFieldPanel toField(ContentFolderTypeProvider contentFolderTypeProvider) {
if (contentFolderTypeProvider == ProductionContentFolderTypeProvider.getInstance()) {
return myOutputPathPanel;
}
else if (contentFolderTypeProvider == ProductionResourceContentFolderTypeProvider.getInstance()) {
return myResourcesOutputPathPanel;
}
else if (contentFolderTypeProvider == TestContentFolderTypeProvider.getInstance()) {
return myTestsOutputPathPanel;
}
else if (contentFolderTypeProvider == TestResourceContentFolderTypeProvider.getInstance()) {
return myTestResourcesOutputPathPanel;
}
throw new IllegalArgumentException(contentFolderTypeProvider.getId());
}
示例3: isInResource
import consulo.roots.impl.ProductionResourceContentFolderTypeProvider; //导入方法依赖的package包/类
@Override
public boolean isInResource(@Nonnull VirtualFile fileOrDir) {
DirectoryInfo info = getInfoForFileOrDirectory(fileOrDir);
return info.isInModuleSource() && myDirectoryIndex.getContentFolderType(info) == ProductionResourceContentFolderTypeProvider.getInstance();
}
示例4: ProductionResourceModuleOutputElementType
import consulo.roots.impl.ProductionResourceContentFolderTypeProvider; //导入方法依赖的package包/类
public ProductionResourceModuleOutputElementType() {
super("module-production-resource-output", ProductionResourceContentFolderTypeProvider.getInstance());
}
示例5: isInsideResourceRoot
import consulo.roots.impl.ProductionResourceContentFolderTypeProvider; //导入方法依赖的package包/类
private static boolean isInsideResourceRoot(VirtualFile file, ProjectFileIndex fileIndex)
{
ContentFolderTypeProvider provider = fileIndex.getContentFolderTypeForFile(file);
return provider == ProductionResourceContentFolderTypeProvider.getInstance() || provider == TestResourceContentFolderTypeProvider.getInstance();
}