当前位置: 首页>>代码示例>>Java>>正文


Java Project.getComponent方法代码示例

本文整理汇总了Java中com.intellij.openapi.project.Project.getComponent方法的典型用法代码示例。如果您正苦于以下问题:Java Project.getComponent方法的具体用法?Java Project.getComponent怎么用?Java Project.getComponent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.intellij.openapi.project.Project的用法示例。


在下文中一共展示了Project.getComponent方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: configureProject

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
@Override
public void configureProject(@NotNull final Project project, @NotNull final VirtualFile baseDir,
                             @NotNull PyNewProjectSettings settings,
                             @NotNull Module module,
                             @Nullable final PyProjectSynchronizer synchronizer) {
  final Course course = getCourse(project, mySettingsPanel);
  EduUsagesCollector.projectTypeCreated(CCUtils.COURSE_MODE);
  final CCProjectComponent component = project.getComponent(CCProjectComponent.class);
  component.registerListener();
  final PsiDirectory projectDir = PsiManager.getInstance(project).findDirectory(baseDir);
  if (projectDir == null) return;
  new WriteCommandAction.Simple(project) {
    @Override
    protected void run() throws Throwable {

      createTestHelper(project, projectDir);

      PsiDirectory lessonDir = new CCCreateLesson().createItem(null, project, projectDir, course);
      if (lessonDir == null) {
        LOG.error("Failed to create lesson");
        return;
      }
      new CCCreateTask().createItem(null, project, lessonDir, course);
    }
  }.execute();
}
 
开发者ID:medvector,项目名称:educational-plugin,代码行数:27,代码来源:PyCCProjectGenerator.java

示例2: createToolWindowContent

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
@Override
public void createToolWindowContent(@NotNull Project project, @NotNull ToolWindow toolWindow) {
    final DateTimeConverterView view = project.getComponent(DateTimeConverterView.class);
    view.getModel().addRow(DateTimeUtil.nowGasDay());

    final Content content = ContentFactory.SERVICE.getInstance().createContent(view.getComponent(), "", false);
    content.setCloseable(true);

    toolWindow.getContentManager().addContent(content);
}
 
开发者ID:imgruntw,项目名称:date-time-converter-plugin,代码行数:11,代码来源:DateTimeConverterWindowFactory.java

示例3: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
public static ReactNativeConsole getInstance(Project project) {
    return project.getComponent(ReactNativeConsole.class);
}
 
开发者ID:beansoftapp,项目名称:react-native-console,代码行数:4,代码来源:ReactNativeConsole.java

示例4: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
public static ReactNativeTerminal getInstance(Project project) {
    return project.getComponent(ReactNativeTerminal.class);
}
 
开发者ID:beansoftapp,项目名称:react-native-console,代码行数:4,代码来源:ReactNativeTerminal.java

示例5: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
@Nonnull
public static GuiceManager getInstance(@Nonnull Project project) {
    return project.getComponent(GuiceManager.class);
}
 
开发者ID:t28hub,项目名称:json2java4idea,代码行数:5,代码来源:GuiceManager.java

示例6: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
public static BPMNPaletteToolWindowManager getInstance(Project project) {
    return project.getComponent(BPMNPaletteToolWindowManager.class);
}
 
开发者ID:Blenta,项目名称:intellij-bpmn-editor,代码行数:4,代码来源:BPMNPaletteToolWindowManager.java

示例7: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
public static SeedStackNavigator getInstance(Project project) {
    return project.getComponent(SeedStackNavigator.class);
}
 
开发者ID:seedstack,项目名称:intellij-plugin,代码行数:4,代码来源:SeedStackNavigator.java

示例8: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
public static SettingService getInstance(Project project) {
    return project.getComponent(SettingService.class);
}
 
开发者ID:dpzxsm,项目名称:ReactPropTypes-Plugin,代码行数:4,代码来源:SettingService.java

示例9: getInstance

import com.intellij.openapi.project.Project; //导入方法依赖的package包/类
/**
 * Returns the bucklescript instance for the specified project.
 *
 * @param project the project for which the bucklescript is requested.
 * @return the bucklescript instance.
 */
public static Bucklescript getInstance(Project project) {
    return project.getComponent(Bucklescript.class);
}
 
开发者ID:reasonml-editor,项目名称:reasonml-idea-plugin,代码行数:10,代码来源:BucklescriptProjectComponent.java


注:本文中的com.intellij.openapi.project.Project.getComponent方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。