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


Java ConfigurationModuleSelector类代码示例

本文整理汇总了Java中com.intellij.execution.ui.ConfigurationModuleSelector的典型用法代码示例。如果您正苦于以下问题:Java ConfigurationModuleSelector类的具体用法?Java ConfigurationModuleSelector怎么用?Java ConfigurationModuleSelector使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: DefracMainClassTextFieldWithBrowseButton

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public DefracMainClassTextFieldWithBrowseButton(@NotNull final Project project,
                                                @NotNull final ConfigurationModuleSelector moduleSelector) {
  super(project, true, new JavaCodeFragment.VisibilityChecker() {
    public Visibility isDeclarationVisible(PsiElement declaration, PsiElement place) {
      if(declaration instanceof PsiClass) {
        final PsiClass aClass = (PsiClass) declaration;

        if(isValidMainClass(aClass) || place.getParent() != null && isValidMainClass(moduleSelector.findClass(aClass.getQualifiedName()))) {
          return Visibility.VISIBLE;
        }
      }

      return Visibility.NOT_VISIBLE;
    }

    private boolean isValidMainClass(@Nullable final PsiClass cls) {
      return DefracRunUtil.isValidMainClass(moduleSelector.getModule(), cls);
    }
  });
}
 
开发者ID:defrac,项目名称:defrac-plugin-intellij,代码行数:21,代码来源:DefracMainClassTextFieldWithBrowseButton.java

示例2: DefracMainClassBrowser

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public DefracMainClassBrowser(@NotNull final Project project,
                              @NotNull final ConfigurationModuleSelector moduleSelector) {
  super(project, "Choose main class");

  this.moduleSelector = moduleSelector;
  this.classFilter = new ClassFilter.ClassFilterWithScope() {
    @Override
    public GlobalSearchScope getScope() {
      return GlobalSearchScope.moduleScope(moduleSelector.getModule());
    }

    @Override
    public boolean isAccepted(final PsiClass psiClass) {
      return DefracRunUtil.isValidMainClass(moduleSelector.getModule(), psiClass);
    }
  };
}
 
开发者ID:defrac,项目名称:defrac-plugin-intellij,代码行数:18,代码来源:DefracMainClassBrowser.java

示例3: getFilter

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
protected ClassFilter.ClassFilterWithScope getFilter() throws NoFilterException {
  final ConfigurationModuleSelector moduleSelector = getModuleSelector();
  final Module module = moduleSelector.getModule();
  if (module == null) {
    throw NoFilterException.moduleDoesntExist(moduleSelector);
  }
  final ClassFilter.ClassFilterWithScope classFilter;
  try {
    final JUnitConfiguration configurationCopy =
      new JUnitConfiguration(ExecutionBundle.message("default.junit.configuration.name"), getProject(),
                             JUnitConfigurationType.getInstance().getConfigurationFactories()[0]);
    applyEditorTo(configurationCopy);
    classFilter = TestClassFilter
      .create(configurationCopy.getTestObject().getSourceScope(), configurationCopy.getConfigurationModule().getModule());
  }
  catch (JUnitUtil.NoJUnitException e) {
    throw NoFilterException.noJUnitInModule(module);
  }
  return classFilter;
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:21,代码来源:JUnitConfigurable.java

示例4: AndroidInheritingClassBrowser

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public AndroidInheritingClassBrowser(@NotNull Project project,
                                     @NotNull ConfigurationModuleSelector moduleSelector,
                                     @NotNull String baseClassName,
                                     @NotNull String dialogTitle,
                                     boolean includeLibraryClasses) {
  super(project, moduleSelector, dialogTitle, includeLibraryClasses);
  myBaseClassName = baseClassName;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:9,代码来源:AndroidInheritingClassBrowser.java

示例5: AndroidClassBrowserBase

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public AndroidClassBrowserBase(@NotNull Project project,
                               @NotNull ConfigurationModuleSelector moduleSelector,
                               @NotNull String dialogTitle,
                               boolean includeLibraryClasses) {
  super(project);
  myIncludeLibraryClasses = includeLibraryClasses;
  myDialogTitle = dialogTitle;
  myModuleSelector = moduleSelector;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:10,代码来源:AndroidClassBrowserBase.java

示例6: TestRunParameters

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
TestRunParameters(Project project, ConfigurationModuleSelector moduleSelector) {
  myProject = project;
  myModuleSelector = moduleSelector;

  myPackageComponent.setComponent(new EditorTextFieldWithBrowseButton(project, false));
  bind(myPackageComponent, new MyPackageBrowser());

  myClassComponent
    .setComponent(new EditorTextFieldWithBrowseButton(project, true, new AndroidTestClassVisibilityChecker(moduleSelector)));

  bind(myClassComponent,
       new AndroidTestClassBrowser(project, moduleSelector, AndroidBundle.message("android.browse.test.class.dialog.title"), false));

  myRunnerComponent.setComponent(new EditorTextFieldWithBrowseButton(project, true,
                                                                     new AndroidInheritingClassVisibilityChecker(myProject, moduleSelector,
                                                                                                       AndroidUtils.INSTRUMENTATION_RUNNER_BASE_CLASS)));
  bind(myRunnerComponent, new AndroidInheritingClassBrowser(project, moduleSelector, AndroidUtils.INSTRUMENTATION_RUNNER_BASE_CLASS,
                                                  AndroidBundle.message("android.browse.instrumentation.class.dialog.title"), true
  ));
  bind(myMethodComponent, new MyMethodBrowser());

  addTestingType(TEST_ALL_IN_MODULE, myAllInModuleButton);
  addTestingType(TEST_ALL_IN_PACKAGE, myAllInPackageButton);
  addTestingType(TEST_CLASS, myClassButton);
  addTestingType(TEST_METHOD, myTestMethodButton);

  setAnchor(myPackageComponent.getLabel());
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:29,代码来源:TestRunParameters.java

示例7: AndroidInheritingClassVisibilityChecker

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public AndroidInheritingClassVisibilityChecker(@NotNull Project project,
                                               @NotNull ConfigurationModuleSelector moduleSelector,
                                               @NotNull String baseClassName) {
  super(moduleSelector);
  myProject = project;
  myBaseClassName = baseClassName;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:8,代码来源:AndroidInheritingClassVisibilityChecker.java

示例8: PageObjectConfigurable

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public PageObjectConfigurable(Project project) {
    this.project = project;
    myModuleSelector = new ConfigurationModuleSelector(project, myModule.getComponent());
    myCommonJavaParameters.setModuleContext(myModuleSelector.getModule());
    myCommonJavaParameters.setHasModuleMacro();
    myModule.getComponent().addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent e) {
            myCommonJavaParameters.setModuleContext(myModuleSelector.getModule());
        }
    });
}
 
开发者ID:bjorm,项目名称:PageObjectEvaluator,代码行数:12,代码来源:PageObjectConfigurable.java

示例9: ApplicationConfigurable

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public ApplicationConfigurable(final Project project) {
  myProject = project;
  myModuleSelector = new ConfigurationModuleSelector(project, myModule.getComponent());
  myCommonProgramParameters.setModuleContext(myModuleSelector.getModule());
  myModule.getComponent().addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent e) {
      myCommonProgramParameters.setModuleContext(myModuleSelector.getModule());
    }
  });
  ClassBrowser.createApplicationClassBrowser(project, myModuleSelector).setField(getMainClassField());
  myVersionDetector = new JreVersionDetector();

  myAnchor = UIUtil.mergeComponentsWithAnchor(myMainClass, myCommonProgramParameters, myAlternativeJREPanel, myModule);
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:15,代码来源:ApplicationConfigurable.java

示例10: AndroidClassVisibilityCheckerBase

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public AndroidClassVisibilityCheckerBase(@NotNull ConfigurationModuleSelector moduleSelector) {
  myModuleSelector = moduleSelector;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:AndroidClassVisibilityCheckerBase.java

示例11: getModuleSelector

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public ConfigurationModuleSelector getModuleSelector() {
  return myModuleSelector;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:AndroidRunConfigurationEditor.java

示例12: AndroidTestClassVisibilityChecker

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public AndroidTestClassVisibilityChecker(@NotNull ConfigurationModuleSelector moduleSelector) {
  super(moduleSelector);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:AndroidTestClassVisibilityChecker.java

示例13: AndroidTestClassBrowser

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public AndroidTestClassBrowser(@NotNull Project project,
                               @NotNull ConfigurationModuleSelector moduleSelector,
                               @NotNull String dialogTitle,
                               boolean includeLibraryClasses) {
  super(project, moduleSelector, dialogTitle, includeLibraryClasses);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:7,代码来源:AndroidTestClassBrowser.java

示例14: getModuleSelector

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public ConfigurationModuleSelector getModuleSelector() {
  return moduleSelector;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:TestNGConfigurationEditor.java

示例15: RunConfigurationEditor

import com.intellij.execution.ui.ConfigurationModuleSelector; //导入依赖的package包/类
public RunConfigurationEditor(Project project) {

        myProject = project;

        myModuleSelector = new ConfigurationModuleSelector(project, myModule.getComponent());

        ClassBrowser.createApplicationClassBrowser(project, myModuleSelector).setField(myMainClass.getComponent());

        myAnchor = UIUtil.mergeComponentsWithAnchor(repositoryUIDField, repositoryURLField, repositoryClassField,
                specificationsField, workingVersionCheckBox, myMainClass, myModule, myCommonProgramParameters);
    }
 
开发者ID:testIT-LivingDoc,项目名称:livingdoc-intellij,代码行数:12,代码来源:RunConfigurationEditor.java


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