本文整理汇总了Java中com.intellij.openapi.project.ProjectType类的典型用法代码示例。如果您正苦于以下问题:Java ProjectType类的具体用法?Java ProjectType怎么用?Java ProjectType使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ProjectType类属于com.intellij.openapi.project包,在下文中一共展示了ProjectType类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: registerChameleon
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
private AnAction registerChameleon(String actionId, AnAction action, PluginId pluginId, String projectType) {
ProjectType type = projectType == null ? null : new ProjectType(projectType);
// make sure id+projectType is unique
AnAction o = myId2Action.get(actionId);
ChameleonAction chameleonAction;
if (o == null) {
chameleonAction = new ChameleonAction(action, type);
myId2Action.put(actionId, chameleonAction);
return chameleonAction;
}
if (o instanceof ChameleonAction) {
chameleonAction = (ChameleonAction)o;
}
else {
chameleonAction = new ChameleonAction(o, type);
myId2Action.put(actionId, chameleonAction);
}
AnAction old = chameleonAction.addAction(action, type);
if (old != null) {
reportActionError(pluginId,
"action with the ID \"" + actionId + "\" was already registered. Action being registered is " + action +
"; Registered action is " +
myId2Action.get(actionId) + getPluginInfo(pluginId));
return null;
}
return chameleonAction;
}
示例2: addAction
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
public AnAction addAction(AnAction action, ProjectType projectType) {
if (action instanceof ActionStub) {
String type = ((ActionStub)action).getProjectType();
action = ActionManagerImpl.convertStub((ActionStub)action);
projectType = type == null ? null : new ProjectType(type);
}
return myActions.put(projectType, action);
}
示例3: getAction
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
@Nullable
private AnAction getAction(AnActionEvent e) {
Project project = CommonDataKeys.PROJECT.getData(e.getDataContext());
ProjectType projectType = ProjectTypeService.getProjectType(project);
AnAction action = myActions.get(projectType);
if (action == null) action = myActions.get(null);
return action;
}
示例4: shouldBeBuiltByExternalSystem
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
private static boolean shouldBeBuiltByExternalSystem(@NotNull Project project) {
// skip resource compilation by IDE for Android projects
// TODO [vlad] this check should be replaced when an option to make any gradle project with gradle be introduced.
ProjectType projectType = ProjectTypeService.getProjectType(project);
if (projectType != null && "Android".equals(projectType.getId())) return true;
return false;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:8,代码来源:GradleResourceCompilerConfigurationGenerator.java
示例5: ChameleonAction
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
public ChameleonAction(@NotNull AnAction first, ProjectType projectType) {
addAction(first, projectType);
copyFrom(myActions.values().iterator().next());
}
示例6: getActions
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
@TestOnly
public Map<ProjectType, AnAction> getActions() {
return myActions;
}
示例7: getProjectType
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
protected ProjectType getProjectType() {
return null;
}
示例8: setProjectType
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
protected void setProjectType(Module module) {
ProjectType projectType = getProjectType();
if (projectType != null && ProjectTypeService.getProjectType(module.getProject()) == null) {
ProjectTypeService.setProjectType(module.getProject(), projectType);
}
}
示例9: getProjectType
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
@Override
protected ProjectType getProjectType() {
return ANDROID_PROJECT_TYPE;
}
示例10: getProjectType
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
@Override
protected ProjectType getProjectType() {
return AndroidModuleBuilder.ANDROID_PROJECT_TYPE;
}
示例11: getProjectType
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
/**
* Project Type
* @return
*/
@Override
protected ProjectType getProjectType() {
return PI_PROJECT_TYPE;
}
示例12: getProjectType
import com.intellij.openapi.project.ProjectType; //导入依赖的package包/类
/**
* Project Type
* @return
*/
@Override
protected ProjectType getProjectType() {
return BBB_PROJECT_TYPE;
}
开发者ID:asebak,项目名称:embeddedlinux-jvmdebugger-intellij,代码行数:9,代码来源:BeagleBoneBlackJavaModuleBuilder.java