diff --git a/java/compiler/impl/src/com/intellij/compiler/CompilerManagerImpl.java b/java/compiler/impl/src/com/intellij/compiler/CompilerManagerImpl.java index 151c79c70c8a..3e035e7051a9 100644 --- a/java/compiler/impl/src/com/intellij/compiler/CompilerManagerImpl.java +++ b/java/compiler/impl/src/com/intellij/compiler/CompilerManagerImpl.java @@ -172,9 +172,8 @@ public class CompilerManagerImpl extends CompilerManager { return getCompilers(compilerClass, CompilerFilter.ALL); } - @Override @NotNull - public T[] getCompilers(@NotNull Class compilerClass, CompilerFilter filter) { + private T[] getCompilers(@NotNull Class compilerClass, CompilerFilter filter) { final List compilers = new ArrayList<>(myCompilers.size()); for (final Compiler item : myCompilers) { if (compilerClass.isAssignableFrom(item.getClass()) && filter.acceptCompiler(item)) { @@ -272,13 +271,6 @@ public class CompilerManagerImpl extends CompilerManager { new CompileDriver(myProject).make(scope, true, new ListenerNotificator(callback)); } - @Override - public void make(@NotNull CompileScope scope, CompilerFilter filter, @Nullable CompileStatusNotification callback) { - final CompileDriver compileDriver = new CompileDriver(myProject); - compileDriver.setCompilerFilter(filter); - compileDriver.make(scope, new ListenerNotificator(callback)); - } - @Override public boolean isUpToDate(@NotNull final CompileScope scope) { return new CompileDriver(myProject).isUpToDate(scope); diff --git a/java/compiler/openapi/src/com/intellij/openapi/compiler/CompilerManager.java b/java/compiler/openapi/src/com/intellij/openapi/compiler/CompilerManager.java index 809d3a1a95a7..c2ce8cf67b8d 100644 --- a/java/compiler/openapi/src/com/intellij/openapi/compiler/CompilerManager.java +++ b/java/compiler/openapi/src/com/intellij/openapi/compiler/CompilerManager.java @@ -75,6 +75,7 @@ public abstract class CompilerManager { * integrate into 'external build system' instead (https://confluence.jetbrains.com/display/IDEADEV/External+Builder+API+and+Plugins). * Since IDEA 13 users cannot switch to the old build system via UI and it will be completely removed in IDEA 14. */ + @Deprecated public abstract void addTranslatingCompiler(@NotNull TranslatingCompiler compiler, Set inputTypes, Set outputTypes); /** @@ -93,12 +94,6 @@ public abstract class CompilerManager { @NotNull public abstract T[] getCompilers(@NotNull Class compilerClass); - /** - * @deprecated use {@link #getCompilers(Class)} instead - */ - @NotNull - public abstract T[] getCompilers(@NotNull Class compilerClass, CompilerFilter filter); - /** * Registers the type as a compilable type so that Compile action will be enabled on files of this type. * @@ -220,11 +215,6 @@ public abstract class CompilerManager { */ public abstract void makeWithModalProgress(@NotNull CompileScope scope, @Nullable CompileStatusNotification callback); - /** - * @deprecated use {@link #make(CompileScope, CompileStatusNotification)} instead - */ - public abstract void make(@NotNull CompileScope scope, CompilerFilter filter, @Nullable CompileStatusNotification callback); - /** * Checks if compile scope given is up-to-date * @param scope diff --git a/java/idea-ui/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactoryImpl.java b/java/idea-ui/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactoryImpl.java index f5dda04d5c2c..846375388986 100644 --- a/java/idea-ui/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactoryImpl.java +++ b/java/idea-ui/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactoryImpl.java @@ -17,19 +17,14 @@ package com.intellij.ide.util.projectWizard; import com.intellij.ide.util.newProjectWizard.AbstractProjectWizard; import com.intellij.ide.util.newProjectWizard.SourcePathsStep; -import com.intellij.ide.util.newProjectWizard.SupportForFrameworksStep; import com.intellij.openapi.projectRoots.Sdk; import com.intellij.openapi.projectRoots.SdkType; import com.intellij.openapi.projectRoots.SdkTypeId; -import com.intellij.openapi.roots.ui.configuration.ModulesProvider; -import com.intellij.openapi.roots.ui.configuration.projectRoot.LibrariesContainer; -import com.intellij.openapi.roots.ui.configuration.projectRoot.LibrariesContainerFactory; import com.intellij.openapi.util.Computable; import com.intellij.openapi.util.Condition; import com.intellij.openapi.util.Key; import org.jetbrains.annotations.NonNls; import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; import javax.swing.*; @@ -43,25 +38,10 @@ public class ProjectWizardStepFactoryImpl extends ProjectWizardStepFactory { return new ProjectNameStep(wizardContext); } - public ModuleWizardStep createSourcePathsStep(ModuleWizardStep nameAndLocationStep, SourcePathsBuilder builder, Icon icon, String helpId) { - return null; - } - public ModuleWizardStep createSourcePathsStep(final WizardContext context, final SourcePathsBuilder builder, final Icon icon, @NonNls final String helpId) { return new SourcePathsStep(builder, icon, helpId); } - /** - * @deprecated - */ - public ModuleWizardStep createProjectJdkStep(WizardContext context, - final JavaModuleBuilder builder, - final Computable isVisible, - final Icon icon, - final String helpId) { - return createProjectJdkStep(context, null, builder, isVisible, icon, helpId); - } - public ModuleWizardStep createProjectJdkStep(WizardContext context, SdkType type, final JavaModuleBuilder builder, @@ -110,23 +90,6 @@ public class ProjectWizardStepFactoryImpl extends ProjectWizardStepFactory { return projectSdkStep; } - @Nullable - @Override - public Sdk getNewProjectSdk(WizardContext wizardContext) { - return AbstractProjectWizard.getNewProjectJdk(wizardContext); - } - - @Override - public ModuleWizardStep createSupportForFrameworksStep(WizardContext wizardContext, ModuleBuilder moduleBuilder) { - return createSupportForFrameworksStep(wizardContext, moduleBuilder, ModulesProvider.EMPTY_MODULES_PROVIDER); - } - - @Override - public ModuleWizardStep createSupportForFrameworksStep(@NotNull WizardContext context, @NotNull ModuleBuilder builder, @NotNull ModulesProvider modulesProvider) { - final LibrariesContainer container = LibrariesContainerFactory.createContainer(context, modulesProvider); - return new SupportForFrameworksStep(context, builder, container); - } - @Override public ModuleWizardStep createJavaSettingsStep(@NotNull SettingsStep settingsStep, @NotNull ModuleBuilder moduleBuilder, @NotNull Condition sdkFilter) { return new JavaSettingsStep(settingsStep, moduleBuilder, sdkFilter); diff --git a/java/java-impl/src/com/intellij/codeInsight/hint/api/impls/AnnotationParameterInfoHandler.java b/java/java-impl/src/com/intellij/codeInsight/hint/api/impls/AnnotationParameterInfoHandler.java index 0d822feff94c..d8cd15564fb6 100644 --- a/java/java-impl/src/com/intellij/codeInsight/hint/api/impls/AnnotationParameterInfoHandler.java +++ b/java/java-impl/src/com/intellij/codeInsight/hint/api/impls/AnnotationParameterInfoHandler.java @@ -35,11 +35,6 @@ public class AnnotationParameterInfoHandler implements ParameterInfoHandler= 0 ? (PsiElement)objectsToView[index]:null); } - @Override - @NotNull - public String getParameterCloseChars() { - return ",>"; - } - - @Override - public boolean tracksParameterIndex() { - return true; - } - @Override public void updateUI(PsiTypeParameter o, @NotNull ParameterInfoUIContext context) { updateTypeParameter(o, context); diff --git a/java/java-impl/src/com/intellij/ide/util/PackageUtil.java b/java/java-impl/src/com/intellij/ide/util/PackageUtil.java index 1bb4969c556c..1c825c8517a5 100644 --- a/java/java-impl/src/com/intellij/ide/util/PackageUtil.java +++ b/java/java-impl/src/com/intellij/ide/util/PackageUtil.java @@ -86,19 +86,6 @@ public class PackageUtil { String packageName, PsiDirectory baseDir, boolean askUserToCreate) throws IncorrectOperationException { - return findOrCreateDirectoryForPackage(project, packageName, baseDir, askUserToCreate, false); - } - - /** - * @deprecated - */ - @Deprecated - @Nullable - public static PsiDirectory findOrCreateDirectoryForPackage(Project project, - String packageName, - PsiDirectory baseDir, - boolean askUserToCreate, boolean filterSourceDirsForTestBaseDir) throws IncorrectOperationException { - PsiDirectory psiDirectory = null; if (!"".equals(packageName)) { @@ -111,9 +98,6 @@ public class PackageUtil { postfixToShow = File.separatorChar + postfixToShow; } PsiDirectory[] directories = rootPackage.getDirectories(); - if (filterSourceDirsForTestBaseDir) { - directories = filterSourceDirectories(baseDir, project, directories); - } psiDirectory = DirectoryChooserUtil.selectDirectory(project, directories, baseDir, postfixToShow); if (psiDirectory == null) return null; } diff --git a/java/java-impl/src/com/intellij/testIntegration/JavaTestFinder.java b/java/java-impl/src/com/intellij/testIntegration/JavaTestFinder.java index 1321c4dacdf1..10b158c33d00 100644 --- a/java/java-impl/src/com/intellij/testIntegration/JavaTestFinder.java +++ b/java/java-impl/src/com/intellij/testIntegration/JavaTestFinder.java @@ -63,13 +63,6 @@ public class JavaTestFinder implements TestFinder { return TestFinderHelper.getSortedElements(classesWithWeights, false); } - /** - * @deprecated {@link JavaTestFinder#getSearchScope(com.intellij.psi.PsiElement, boolean)} - */ - protected GlobalSearchScope getSearchScope(PsiElement element) { - return getSearchScope(element, true); - } - protected GlobalSearchScope getSearchScope(PsiElement element, boolean dependencies) { final Module module = getModule(element); if (module != null) { diff --git a/java/java-psi-api/src/com/intellij/codeInsight/AnnotationUtil.java b/java/java-psi-api/src/com/intellij/codeInsight/AnnotationUtil.java index e7e7381817d3..06489a5793d0 100644 --- a/java/java-psi-api/src/com/intellij/codeInsight/AnnotationUtil.java +++ b/java/java-psi-api/src/com/intellij/codeInsight/AnnotationUtil.java @@ -667,16 +667,6 @@ public class AnnotationUtil { return isAnnotated(listOwner, annotationFQN, flags(checkHierarchy, skipExternal, skipExternal)); } - /** @deprecated use {@link #isAnnotated(PsiModifierListOwner, String, int)} (to be removed in IDEA 2019) */ - @Deprecated - public static boolean isAnnotated(@NotNull PsiModifierListOwner listOwner, - @NotNull String annotationFQN, - boolean checkHierarchy, - boolean skipExternal, - boolean skipInferred) { - return isAnnotated(listOwner, annotationFQN, flags(checkHierarchy, skipExternal, skipInferred)); - } - private static @Flags int flags(boolean checkHierarchy, boolean skipExternal, boolean skipInferred) { int flags = CHECK_TYPE; if (checkHierarchy) flags |= CHECK_HIERARCHY; diff --git a/java/java-psi-api/src/com/intellij/psi/CommonReferenceProviderTypes.java b/java/java-psi-api/src/com/intellij/psi/CommonReferenceProviderTypes.java index 234c15ac0da2..605c7beefdfd 100644 --- a/java/java-psi-api/src/com/intellij/psi/CommonReferenceProviderTypes.java +++ b/java/java-psi-api/src/com/intellij/psi/CommonReferenceProviderTypes.java @@ -16,21 +16,12 @@ package com.intellij.psi; import com.intellij.openapi.components.ServiceManager; -import com.intellij.openapi.project.Project; /** * @author peter */ public abstract class CommonReferenceProviderTypes { - /** - * @deprecated - * @see #getInstance() - */ - public static CommonReferenceProviderTypes getInstance(final Project project) { - return getInstance(); - } - public static CommonReferenceProviderTypes getInstance() { return ServiceManager.getService(CommonReferenceProviderTypes.class); } diff --git a/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsParsingUtil.java b/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsParsingUtil.java index cab80bbdb5b8..e0f45ce5a3a8 100644 --- a/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsParsingUtil.java +++ b/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsParsingUtil.java @@ -175,10 +175,4 @@ public class ClsParsingUtil { } return null; } - - /** @deprecated use {@link #getJdkVersionByBytecode(int)} (to be removed in IDEA 2019) */ - public static LanguageLevel getLanguageLevelByVersion(int major) { - JavaSdkVersion sdkVersion = getJdkVersionByBytecode(major); - return sdkVersion != null ? sdkVersion.getMaxLanguageLevel() : null; - } } \ No newline at end of file diff --git a/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsStubBuilderFactory.java b/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsStubBuilderFactory.java deleted file mode 100644 index 64f7a8567502..000000000000 --- a/java/java-psi-impl/src/com/intellij/psi/impl/compiled/ClsStubBuilderFactory.java +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright 2000-2015 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.psi.impl.compiled; - -import com.intellij.openapi.extensions.ExtensionPointName; -import com.intellij.openapi.project.Project; -import com.intellij.openapi.vfs.VirtualFile; -import com.intellij.psi.PsiFile; -import com.intellij.psi.stubs.PsiFileStub; -import com.intellij.util.cls.ClsFormatException; - -/** @deprecated API no longer supported, use {@link com.intellij.psi.compiled.ClassFileDecompilers} instead (to remove in IDEA 14) */ -@SuppressWarnings({"deprecation", "unused"}) -public abstract class ClsStubBuilderFactory { - public static final ExtensionPointName EP_NAME = ExtensionPointName.create("com.intellij.clsStubBuilderFactory"); - - public abstract PsiFileStub buildFileStub(final VirtualFile file, byte[] bytes) throws ClsFormatException; - - public PsiFileStub buildFileStub(final VirtualFile file, byte[] bytes, Project project) throws ClsFormatException { - return buildFileStub(file, bytes); - } - - public abstract boolean canBeProcessed(final VirtualFile file, byte[] bytes); - - public abstract boolean isInnerClass(final VirtualFile file); - - public int getStubVersion() { - return 1; - } -} diff --git a/java/java-tests/testSrc/com/intellij/java/execution/actions/ContextConfigurationTest.java b/java/java-tests/testSrc/com/intellij/java/execution/actions/ContextConfigurationTest.java index 85ff53420f30..8ce19863b8eb 100644 --- a/java/java-tests/testSrc/com/intellij/java/execution/actions/ContextConfigurationTest.java +++ b/java/java-tests/testSrc/com/intellij/java/execution/actions/ContextConfigurationTest.java @@ -6,6 +6,7 @@ import com.intellij.execution.RunManager; import com.intellij.execution.RunnerAndConfigurationSettings; import com.intellij.execution.actions.ConfigurationContext; import com.intellij.execution.application.ApplicationConfiguration; +import com.intellij.execution.configurations.RunConfiguration; import com.intellij.execution.junit.AllInPackageConfigurationProducer; import com.intellij.execution.junit.JUnitConfiguration; import com.intellij.execution.junit.JUnitUtil; @@ -15,9 +16,7 @@ import com.intellij.execution.junit2.info.MethodLocation; import com.intellij.execution.testframework.TestSearchScope; import com.intellij.java.execution.BaseConfigurationTestCase; import com.intellij.openapi.actionSystem.CommonDataKeys; -import com.intellij.openapi.actionSystem.DataConstants; import com.intellij.openapi.actionSystem.LangDataKeys; -import com.intellij.openapi.actionSystem.ex.DataConstantsEx; import com.intellij.openapi.module.Module; import com.intellij.openapi.module.ModuleUtilCore; import com.intellij.openapi.util.text.StringUtil; @@ -136,7 +135,7 @@ public class ContextConfigurationTest extends BaseConfigurationTestCase { configuration.getPersistentData().setScope(TestSearchScope.MODULE_WITH_DEPENDENCIES); configuration.setModule(getModule2()); MapDataContext dataContext = new MapDataContext(); - dataContext.put(DataConstantsEx.RUNTIME_CONFIGURATION, configuration); + dataContext.put(RunConfiguration.DATA_KEY, configuration); configuration = createJUnitConfiguration(psiClass, TestInClassConfigurationProducer.class, dataContext); checkClassName(psiClass.getQualifiedName(), configuration); assertEquals(Collections.singleton(getModule2()), new HashSet(Arrays.asList(configuration.getModules()))); @@ -147,7 +146,7 @@ public class ContextConfigurationTest extends BaseConfigurationTestCase { PsiPackage psiPackage = JUnitUtil.getContainingPackage(psiClass); final MapDataContext dataContext = new MapDataContext(); final Module module = ModuleUtilCore.findModuleForPsiElement(psiClass); - dataContext.put(DataConstants.MODULE, module); + dataContext.put(LangDataKeys.MODULE.getName(), module); JUnitConfiguration configuration = createJUnitConfiguration(psiPackage, AllInPackageConfigurationProducer.class, dataContext); checkTestObject(JUnitConfiguration.TEST_PACKAGE, configuration); checkPackage(PACKAGE_NAME, configuration); @@ -160,7 +159,7 @@ public class ContextConfigurationTest extends BaseConfigurationTestCase { PsiPackage defaultPackage = psiPackage.getParentPackage(); final Module module = ModuleUtilCore.findModuleForPsiElement(psiClass); final MapDataContext dataContext = new MapDataContext(); - dataContext.put(DataConstants.MODULE, module); + dataContext.put(LangDataKeys.MODULE.getName(), module); JUnitConfiguration configuration = createJUnitConfiguration(defaultPackage, AllInPackageConfigurationProducer.class, dataContext); checkTestObject(JUnitConfiguration.TEST_PACKAGE, configuration); checkPackage("", configuration); diff --git a/java/openapi/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactory.java b/java/openapi/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactory.java index 2be0235569c6..254ca1b41e10 100644 --- a/java/openapi/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactory.java +++ b/java/openapi/src/com/intellij/ide/util/projectWizard/ProjectWizardStepFactory.java @@ -16,15 +16,12 @@ package com.intellij.ide.util.projectWizard; import com.intellij.openapi.components.ServiceManager; -import com.intellij.openapi.projectRoots.Sdk; import com.intellij.openapi.projectRoots.SdkType; import com.intellij.openapi.projectRoots.SdkTypeId; -import com.intellij.openapi.roots.ui.configuration.ModulesProvider; import com.intellij.openapi.util.Computable; import com.intellij.openapi.util.Condition; import org.jetbrains.annotations.NonNls; import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; import javax.swing.*; @@ -39,37 +36,11 @@ public abstract class ProjectWizardStepFactory { public abstract ModuleWizardStep createNameAndLocationStep(WizardContext wizardContext); - /** - * @deprecated Use another version of this method: - * @see com.intellij.ide.util.projectWizard.ProjectWizardStepFactory#createSourcePathsStep(WizardContext, SourcePathsBuilder, javax.swing.Icon, String) - */ - @Deprecated - public abstract ModuleWizardStep createSourcePathsStep(ModuleWizardStep nameAndLocationStep, SourcePathsBuilder builder, Icon icon, @NonNls String helpId); - public abstract ModuleWizardStep createSourcePathsStep(WizardContext context, SourcePathsBuilder builder, Icon icon, @NonNls String helpId); - /** - * @deprecated - */ - @Deprecated - public abstract ModuleWizardStep createProjectJdkStep(WizardContext context, JavaModuleBuilder builder, Computable isVisibile, Icon icon, @NonNls String helpId); - public abstract ModuleWizardStep createProjectJdkStep(WizardContext context, SdkType type, JavaModuleBuilder builder, Computable isVisibile, Icon icon, @NonNls String helpId); public abstract ModuleWizardStep createProjectJdkStep(final WizardContext wizardContext); - @Nullable - public abstract Sdk getNewProjectSdk(WizardContext wizardContext); - - /** - * @deprecated use {@link #createSupportForFrameworksStep(WizardContext, ModuleBuilder, com.intellij.openapi.roots.ui.configuration.ModulesProvider)} instead - */ - @Deprecated - @Nullable - public abstract ModuleWizardStep createSupportForFrameworksStep(WizardContext context, ModuleBuilder builder); - - @Nullable - public abstract ModuleWizardStep createSupportForFrameworksStep(@NotNull WizardContext context, @NotNull ModuleBuilder builder, @NotNull ModulesProvider modulesProvider); - public abstract ModuleWizardStep createJavaSettingsStep(@NotNull SettingsStep settingsStep, @NotNull ModuleBuilder moduleBuilder, @NotNull Condition sdkFilter); } diff --git a/java/testFramework/src/com/intellij/testFramework/IdeaTestCase.java b/java/testFramework/src/com/intellij/testFramework/IdeaTestCase.java index a888c7329831..667e9d1f2dca 100644 --- a/java/testFramework/src/com/intellij/testFramework/IdeaTestCase.java +++ b/java/testFramework/src/com/intellij/testFramework/IdeaTestCase.java @@ -59,13 +59,6 @@ public abstract class IdeaTestCase extends PlatformTestCase { return StdModuleTypes.JAVA; } - /** - * @deprecated calling this method is no longer necessary - */ - @Deprecated - public static void initPlatformPrefix() { - } - protected static void sortClassesByName(@NotNull PsiClass[] classes) { Arrays.sort(classes, (o1, o2) -> o1.getName().compareTo(o2.getName())); } diff --git a/platform/analysis-api/src/com/intellij/codeInspection/GlobalInspectionContext.java b/platform/analysis-api/src/com/intellij/codeInspection/GlobalInspectionContext.java index d94394f37f31..6d85ee2262f0 100644 --- a/platform/analysis-api/src/com/intellij/codeInspection/GlobalInspectionContext.java +++ b/platform/analysis-api/src/com/intellij/codeInspection/GlobalInspectionContext.java @@ -44,17 +44,6 @@ public interface GlobalInspectionContext extends UserDataHolder { @NotNull RefManager getRefManager(); - /** - * Checks if the inspection with the specified ID is suppressed for the - * specified reference graph node. Should not be called manually in normal case. - * You need to check suppressions only when you use {@link GlobalInspectionTool#runInspection} - * @param entity the reference graph node to check. - * @param inspectionToolId the ID of the inspection to check. - * @return true if the inspection is suppressed, false otherwise. - * @deprecated use #shouldCheck instead - */ - boolean isSuppressed(@NotNull RefEntity entity, @NotNull String inspectionToolId); - /** * Checks if the inspection is suppressed for the specified reference graph node. Should not be called manually in normal case. * You need to check suppressions only when you use {@link GlobalInspectionTool#runInspection} diff --git a/platform/analysis-impl/src/com/intellij/codeInspection/ex/GlobalInspectionContextBase.java b/platform/analysis-impl/src/com/intellij/codeInspection/ex/GlobalInspectionContextBase.java index 0f316afae685..972999064ee6 100644 --- a/platform/analysis-impl/src/com/intellij/codeInspection/ex/GlobalInspectionContextBase.java +++ b/platform/analysis-impl/src/com/intellij/codeInspection/ex/GlobalInspectionContextBase.java @@ -129,11 +129,6 @@ public class GlobalInspectionContextBase extends UserDataHolderBase implements G return profile; } - @Override - public boolean isSuppressed(@NotNull RefEntity entity, @NotNull String id) { - return entity instanceof RefElementImpl && ((RefElementImpl)entity).isSuppressed(id); - } - @Override public boolean shouldCheck(@NotNull RefEntity entity, @NotNull GlobalInspectionTool tool) { return !(entity instanceof RefElementImpl) || isToCheckMember((RefElementImpl)entity, tool); diff --git a/platform/core-api/src/com/intellij/openapi/command/WriteCommandAction.java b/platform/core-api/src/com/intellij/openapi/command/WriteCommandAction.java index 7c4ce6a62d29..951dcd954292 100644 --- a/platform/core-api/src/com/intellij/openapi/command/WriteCommandAction.java +++ b/platform/core-api/src/com/intellij/openapi/command/WriteCommandAction.java @@ -32,7 +32,6 @@ import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import java.util.Arrays; -import java.util.Collection; public abstract class WriteCommandAction extends BaseActionRunnable { private static final Logger LOG = Logger.getInstance("#com.intellij.openapi.command.WriteCommandAction"); @@ -374,13 +373,4 @@ public abstract class WriteCommandAction extends BaseActionRunnable { return writeCommandAction(project).compute(computable); } - // - /** - * @deprecated use {@link FileModificationService#preparePsiElementsForWrite(Collection)} (to be removed in IDEA 2018) - */ - @SuppressWarnings("unused") - public static boolean ensureFilesWritable(@NotNull Project project, @NotNull Collection psiFiles) { - return FileModificationService.getInstance().preparePsiElementsForWrite(psiFiles); - } - //} } \ No newline at end of file diff --git a/platform/core-api/src/com/intellij/openapi/command/undo/UndoUtil.java b/platform/core-api/src/com/intellij/openapi/command/undo/UndoUtil.java index 928f28a8bc6a..55a354750a9e 100644 --- a/platform/core-api/src/com/intellij/openapi/command/undo/UndoUtil.java +++ b/platform/core-api/src/com/intellij/openapi/command/undo/UndoUtil.java @@ -22,7 +22,6 @@ package com.intellij.openapi.command.undo; import com.intellij.openapi.command.CommandProcessor; import com.intellij.openapi.editor.Document; import com.intellij.openapi.project.Project; -import com.intellij.openapi.vfs.VirtualFile; import com.intellij.psi.PsiDocumentManager; import com.intellij.psi.PsiFile; import org.jetbrains.annotations.NotNull; @@ -43,14 +42,6 @@ public class UndoUtil { CommandProcessor.getInstance().addAffectedDocuments(project, document); } - /** - * @deprecated please use {@link CommandProcessor#addAffectedFiles} instead - */ - @Deprecated - public static void markVirtualFileForUndo(@NotNull Project project, @NotNull VirtualFile file) { - CommandProcessor.getInstance().addAffectedFiles(project, file); - } - public static void disableUndoFor(@NotNull Document document) { document.putUserData(UndoConstants.DONT_RECORD_UNDO, Boolean.TRUE); } diff --git a/platform/core-api/src/com/intellij/psi/CommonClassNames.java b/platform/core-api/src/com/intellij/psi/CommonClassNames.java index ef7aa38ea342..83ab4e0e2a14 100644 --- a/platform/core-api/src/com/intellij/psi/CommonClassNames.java +++ b/platform/core-api/src/com/intellij/psi/CommonClassNames.java @@ -107,9 +107,4 @@ public interface CommonClassNames { String CLASS_FILE_EXTENSION = ".class"; - // - /** @deprecated use {@link #JAVA_UTIL_FUNCTION_BI_FUNCTION} (to be removed in IDEA 2019) */ - @SuppressWarnings("SpellCheckingInspection") - String JAVA_UTIL_FUNCTION_BIFUNCTION = JAVA_UTIL_FUNCTION_BI_FUNCTION; - // } \ No newline at end of file diff --git a/platform/core-impl/src/com/intellij/psi/impl/source/resolve/reference/impl/providers/PsiFileSystemItemUtil.java b/platform/core-impl/src/com/intellij/psi/impl/source/resolve/reference/impl/providers/PsiFileSystemItemUtil.java index 3d20efa37d8c..b9ce18b1af43 100644 --- a/platform/core-impl/src/com/intellij/psi/impl/source/resolve/reference/impl/providers/PsiFileSystemItemUtil.java +++ b/platform/core-impl/src/com/intellij/psi/impl/source/resolve/reference/impl/providers/PsiFileSystemItemUtil.java @@ -4,7 +4,6 @@ package com.intellij.psi.impl.source.resolve.reference.impl.providers; import com.intellij.openapi.vfs.VfsUtilCore; import com.intellij.openapi.vfs.VirtualFile; import com.intellij.psi.PsiFileSystemItem; -import com.intellij.util.IncorrectOperationException; import org.jetbrains.annotations.Nullable; import static com.intellij.openapi.vfs.VfsUtilCore.VFS_SEPARATOR_CHAR; @@ -26,69 +25,4 @@ public class PsiFileSystemItemUtil { VirtualFile ancestorVFile = ancestor != null ? ancestor.getVirtualFile() : null; return vFile != null && ancestorVFile != null ? VfsUtilCore.getRelativePath(vFile, ancestorVFile, VFS_SEPARATOR_CHAR) : null; } - - // - @Nullable - private static PsiFileSystemItem getCommonAncestor(PsiFileSystemItem file1, PsiFileSystemItem file2) { - if (file1 == file2) return file1; - - int depth1 = getDepth(file1); - int depth2 = getDepth(file2); - - PsiFileSystemItem parent1 = file1; - PsiFileSystemItem parent2 = file2; - while (depth1 > depth2 && parent1 != null) { - parent1 = parent1.getParent(); - depth1--; - } - while (depth2 > depth1 && parent2 != null) { - parent2 = parent2.getParent(); - depth2--; - } - while (parent1 != null && parent2 != null && !parent1.equals(parent2)) { - parent1 = parent1.getParent(); - parent2 = parent2.getParent(); - } - return parent1; - } - - private static int getDepth(PsiFileSystemItem file) { - int depth = 0; - while (file != null) { - depth++; - file = file.getParent(); - } - return depth; - } - - /** @deprecated incorrect when {@code src} is a directory; use {@link #findRelativePath(PsiFileSystemItem, PsiFileSystemItem)} instead */ - @Deprecated - public static String getNotNullRelativePath(PsiFileSystemItem src, PsiFileSystemItem dst) throws IncorrectOperationException { - final String s = getRelativePath(src, dst); - if (s == null) throw new IncorrectOperationException("No way from " + src.getVirtualFile() + " to " + dst.getVirtualFile()); - return s; - } - - /** @deprecated incorrect when {@code src} is a directory; use {@link #findRelativePath(PsiFileSystemItem, PsiFileSystemItem)} instead */ - @Deprecated - @Nullable - public static String getRelativePath(PsiFileSystemItem src, PsiFileSystemItem dst) { - final PsiFileSystemItem commonAncestor = getCommonAncestor(src, dst); - - if (commonAncestor != null) { - StringBuilder buffer = new StringBuilder(); - if (!src.equals(commonAncestor)) { - while (!commonAncestor.equals(src.getParent())) { - buffer.append("..").append('/'); - src = src.getParent(); - assert src != null; - } - } - buffer.append(getRelativePathFromAncestor(dst, commonAncestor)); - return buffer.toString(); - } - - return null; - } - // } \ No newline at end of file diff --git a/platform/external-system-api/src/com/intellij/openapi/externalSystem/service/project/manage/AbstractProjectDataService.java b/platform/external-system-api/src/com/intellij/openapi/externalSystem/service/project/manage/AbstractProjectDataService.java index 4ae781e0bb74..8c9700ffaf49 100644 --- a/platform/external-system-api/src/com/intellij/openapi/externalSystem/service/project/manage/AbstractProjectDataService.java +++ b/platform/external-system-api/src/com/intellij/openapi/externalSystem/service/project/manage/AbstractProjectDataService.java @@ -72,17 +72,10 @@ public abstract class AbstractProjectDataService implements ProjectDataSer @NotNull IdeModifiableModelsProvider modelsProvider) { } - /** - * @deprecated use {@link #onSuccessImport(Collection, ProjectData, Project, IdeModelsProvider)} - */ - public void onSuccessImport(@NotNull Project project) { - } - public void onSuccessImport(@NotNull Collection> imported, @Nullable ProjectData projectData, @NotNull Project project, @NotNull IdeModelsProvider modelsProvider) { - onSuccessImport(project); } @ApiStatus.Experimental diff --git a/platform/external-system-api/src/com/intellij/openapi/externalSystem/util/ExternalSystemApiUtil.java b/platform/external-system-api/src/com/intellij/openapi/externalSystem/util/ExternalSystemApiUtil.java index ff0f58314876..8eba527f25de 100644 --- a/platform/external-system-api/src/com/intellij/openapi/externalSystem/util/ExternalSystemApiUtil.java +++ b/platform/external-system-api/src/com/intellij/openapi/externalSystem/util/ExternalSystemApiUtil.java @@ -16,7 +16,6 @@ package com.intellij.openapi.externalSystem.util; import com.intellij.execution.rmi.RemoteUtil; -import com.intellij.ide.util.PropertiesComponent; import com.intellij.openapi.application.*; import com.intellij.openapi.externalSystem.ExternalSystemAutoImportAware; import com.intellij.openapi.externalSystem.ExternalSystemManager; @@ -28,7 +27,6 @@ import com.intellij.openapi.externalSystem.model.ProjectSystemId; import com.intellij.openapi.externalSystem.model.project.LibraryData; import com.intellij.openapi.externalSystem.model.project.ProjectData; import com.intellij.openapi.externalSystem.model.settings.ExternalSystemExecutionSettings; -import com.intellij.openapi.externalSystem.service.ParametersEnhancer; import com.intellij.openapi.externalSystem.settings.AbstractExternalSystemLocalSettings; import com.intellij.openapi.externalSystem.settings.AbstractExternalSystemSettings; import com.intellij.openapi.externalSystem.settings.ExternalProjectSettings; @@ -38,7 +36,6 @@ import com.intellij.openapi.module.Module; import com.intellij.openapi.module.ModuleManager; import com.intellij.openapi.project.Project; import com.intellij.openapi.roots.ExternalProjectSystemRegistry; -import com.intellij.openapi.roots.ModifiableRootModel; import com.intellij.openapi.roots.OrderRootType; import com.intellij.openapi.roots.ProjectModelExternalSource; import com.intellij.openapi.roots.libraries.Library; @@ -54,7 +51,6 @@ import com.intellij.openapi.vfs.VirtualFile; import com.intellij.util.*; import com.intellij.util.containers.*; import com.intellij.util.containers.Stack; -import com.intellij.util.lang.UrlClassLoader; import com.intellij.util.ui.UIUtil; import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.Contract; @@ -64,13 +60,8 @@ import org.jetbrains.annotations.Nullable; import java.io.File; import java.io.PrintWriter; import java.io.StringWriter; -import java.lang.reflect.InvocationTargetException; -import java.lang.reflect.Method; -import java.net.URL; import java.util.*; import java.util.Queue; -import java.util.regex.Matcher; -import java.util.regex.Pattern; import static com.intellij.util.PlatformUtils.*; @@ -79,12 +70,9 @@ import static com.intellij.util.PlatformUtils.*; * @since 4/1/13 1:31 PM */ public class ExternalSystemApiUtil { - private static final String LAST_USED_PROJECT_PATH_PREFIX = "LAST_EXTERNAL_PROJECT_PATH_"; @NotNull public static final String PATH_SEPARATOR = "/"; - @NotNull private static final Pattern ARTIFACT_PATTERN = Pattern.compile("(?:.*/)?(.+?)(?:-([\\d+](?:\\.[\\d]+)*))?(?:\\.[^.]+?)?"); - @NotNull public static final Comparator ORDER_AWARE_COMPARATOR = new Comparator() { @Override @@ -177,19 +165,6 @@ public class ExternalSystemApiUtil { return library.getName() != null && StringUtil.startsWithIgnoreCase(library.getName(), externalSystemId.getId() + ": "); } - /** - * @deprecated to be removed in 2018.2 - */ - @Deprecated - @Nullable - public static ArtifactInfo parseArtifactInfo(@NotNull String fileName) { - Matcher matcher = ARTIFACT_PATTERN.matcher(fileName); - if (!matcher.matches()) { - return null; - } - return new ArtifactInfo(matcher.group(1), null, matcher.group(2)); - } - public static void orderAwareSort(@NotNull List data) { Collections.sort(data, ORDER_AWARE_COMPARATOR); } @@ -405,68 +380,6 @@ public class ExternalSystemApiUtil { return null; } - /** - * @deprecated to be removed in 2018.2 - */ - @Deprecated - public static void commitChangedModels(boolean synchronous, Project project, List models) { - final List changedModels = ContainerUtil.findAll(models, model -> model.isChanged()); - if (!changedModels.isEmpty()) { - executeProjectChangeAction(synchronous, new DisposeAwareProjectChange(project) { - @Override - public void execute() { - for (Library.ModifiableModel modifiableModel : changedModels) { - modifiableModel.commit(); - } - } - }); - } - } - - /** - * @deprecated to be removed in 2018.2 - */ - @Deprecated - public static void disposeModels(@NotNull Collection models) { - for (ModifiableRootModel model : models) { - if (!model.isDisposed()) { - model.dispose(); - } - } - } - - /** - * @deprecated to be removed in 2018.2 - */ - @Deprecated - public static void commitModels(boolean synchronous, Project project, List models) { - final List changedModels = ContainerUtilRt.newArrayList(); - for (ModifiableRootModel modifiableRootModel : models) { - if (modifiableRootModel.isDisposed()) { - continue; - } - if (modifiableRootModel.isChanged()) { - changedModels.add(modifiableRootModel); - } else { - modifiableRootModel.dispose(); - } - } - // Commit only if there are changes. #executeProjectChangeAction acquires a write lock - if (!changedModels.isEmpty()) { - executeProjectChangeAction(synchronous, new DisposeAwareProjectChange(project) { - @Override - public void execute() { - for (ModifiableRootModel modifiableRootModel : changedModels) { - // double check - if (!modifiableRootModel.isDisposed()) { - modifiableRootModel.commit(); - } - } - } - }); - } - } - public static void executeProjectChangeAction(@NotNull final DisposeAwareProjectChange task) { executeProjectChangeAction(true, task); } @@ -600,16 +513,6 @@ public class ExternalSystemApiUtil { return true; } - /** - * @deprecated to be removed in 2018.2 - */ - @Deprecated - public static void storeLastUsedExternalProjectPath(@Nullable String path, @NotNull ProjectSystemId externalSystemId) { - if (path != null) { - PropertiesComponent.getInstance().setValue(LAST_USED_PROJECT_PATH_PREFIX + externalSystemId.getReadableName(), path); - } - } - @NotNull public static String getProjectRepresentationName(@NotNull String targetProjectPath, @Nullable String rootProjectPath) { if (rootProjectPath == null) { @@ -758,68 +661,6 @@ public class ExternalSystemApiUtil { return Registry.is(externalSystemId.getId() + ExternalSystemConstants.USE_IN_PROCESS_COMMUNICATION_REGISTRY_KEY_SUFFIX, false); } - /** - * There is a possible case that methods of particular object should be executed with classpath different from the one implied - * by the current class' class loader. External system offers {@link ParametersEnhancer#enhanceLocalProcessing(List)} method - * for defining that custom classpath. - *

- * It's also possible that particular implementation of {@link ParametersEnhancer} is compiled using dependency to classes - * which are provided by the {@link ParametersEnhancer#enhanceLocalProcessing(List) expanded classpath}. E.g. a class - * {@code 'A'} might use method of class {@code 'B'} and 'A' is located at the current (system/plugin) classpath but - * {@code 'B'} is not. We need to reload {@code 'A'} using its expanded classpath then, i.e. create new class loaded - * with that expanded classpath and load {@code 'A'} by it. - *

- * This method allows to do that. - * - * @deprecated to be removed in 2018.2 - * - * @param clazz custom classpath-aware class which instance should be created (is assumed to have a no-args constructor) - * @param target type - * @return newly created instance of the given class loaded by custom classpath-aware loader - * @throws IllegalAccessException as defined by reflection processing - * @throws InstantiationException as defined by reflection processing - * @throws NoSuchMethodException as defined by reflection processing - * @throws InvocationTargetException as defined by reflection processing - * @throws ClassNotFoundException as defined by reflection processing - */ - @Deprecated - @NotNull - public static T reloadIfNecessary(@NotNull final Class clazz) - throws IllegalAccessException, InstantiationException, NoSuchMethodException, InvocationTargetException, ClassNotFoundException - { - T instance = clazz.newInstance(); - List urls = ContainerUtilRt.newArrayList(); - instance.enhanceLocalProcessing(urls); - if (urls.isEmpty()) { - return instance; - } - - final ClassLoader baseLoader = clazz.getClassLoader(); - Method method = baseLoader.getClass().getMethod("getUrls"); - if (method != null) { - //noinspection unchecked - urls.addAll((Collection)method.invoke(baseLoader)); - } - UrlClassLoader loader = new UrlClassLoader(UrlClassLoader.build().urls(urls).parent(baseLoader.getParent())) { - @Override - protected Class loadClass(String name, boolean resolve) throws ClassNotFoundException { - if (name.equals(clazz.getName())) { - return super.loadClass(name, resolve); - } - else { - try { - return baseLoader.loadClass(name); - } - catch (ClassNotFoundException e) { - return super.loadClass(name, resolve); - } - } - } - }; - //noinspection unchecked - return (T)loader.loadClass(clazz.getName()).newInstance(); - } - public static ProjectModelExternalSource toExternalSource(@NotNull ProjectSystemId systemId) { return ExternalProjectSystemRegistry.getInstance().getSourceById(systemId.getId()); } diff --git a/platform/external-system-impl/src/com/intellij/openapi/externalSystem/util/ExternalSystemUtil.java b/platform/external-system-impl/src/com/intellij/openapi/externalSystem/util/ExternalSystemUtil.java index bba7b35cd318..3c58e427a116 100644 --- a/platform/external-system-impl/src/com/intellij/openapi/externalSystem/util/ExternalSystemUtil.java +++ b/platform/external-system-impl/src/com/intellij/openapi/externalSystem/util/ExternalSystemUtil.java @@ -717,20 +717,6 @@ public class ExternalSystemUtil { return createFailureResult(exception, externalSystemId, project, notificationManager, notificationData); } - /** - * @deprecated to be removed in 2018.2 - */ - @Deprecated - @NotNull - public static FailureResultImpl createFailureResult(@NotNull Exception exception, - @NotNull String projectName, - @NotNull ProjectSystemId externalSystemId, - @NotNull Project project) { - ExternalSystemNotificationManager notificationManager = ExternalSystemNotificationManager.getInstance(project); - NotificationData notificationData = notificationManager.createNotification(exception, projectName, externalSystemId, project); - return createFailureResult(exception, externalSystemId, project, notificationManager, notificationData); - } - @NotNull private static FailureResultImpl createFailureResult(@NotNull Exception exception, @NotNull ProjectSystemId externalSystemId, diff --git a/platform/lang-api/src/com/intellij/application/options/CodeStyleSettingsUtil.java b/platform/lang-api/src/com/intellij/application/options/CodeStyleSettingsUtil.java deleted file mode 100644 index 0e5e7bea58d3..000000000000 --- a/platform/lang-api/src/com/intellij/application/options/CodeStyleSettingsUtil.java +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright 2000-2009 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.intellij.application.options; - -import com.intellij.openapi.components.ServiceManager; -import com.intellij.openapi.project.Project; - -public abstract class CodeStyleSettingsUtil { - public static CodeStyleSettingsUtil getInstance() { - return ServiceManager.getService(CodeStyleSettingsUtil.class); - } - - /** - * @deprecated - * use CodeStyleSettingsUtil.showCodeStyleSettings (Project, String) instead - */ - @Deprecated - public abstract boolean showCodeStyleSettings(Project project, Class pageToSelect); -} \ No newline at end of file diff --git a/platform/lang-api/src/com/intellij/codeInsight/highlighting/HighlightManager.java b/platform/lang-api/src/com/intellij/codeInsight/highlighting/HighlightManager.java index e48ceae04625..f48d127203a1 100644 --- a/platform/lang-api/src/com/intellij/codeInsight/highlighting/HighlightManager.java +++ b/platform/lang-api/src/com/intellij/codeInsight/highlighting/HighlightManager.java @@ -159,14 +159,4 @@ public abstract class HighlightManager { @HideFlags int flags, @Nullable Collection outHighlighters, @Nullable Color scrollmarkColor); - - /** - * @deprecated Use {@link #addOccurrenceHighlights(com.intellij.openapi.editor.Editor, com.intellij.psi.PsiElement[], com.intellij.openapi.editor.markup.TextAttributes, boolean, java.util.Collection)} instead (it does the same thing). - */ - @Deprecated - public abstract void addElementsOccurrenceHighlights(@NotNull Editor editor, - @NotNull PsiElement[] elements, - @NotNull TextAttributes attributes, - boolean hideByTextChange, - @Nullable Collection outHighlighters); } diff --git a/platform/lang-api/src/com/intellij/ide/util/gotoByName/ChooseByNameModel.java b/platform/lang-api/src/com/intellij/ide/util/gotoByName/ChooseByNameModel.java index 466642d8a21a..5e4f0999624f 100644 --- a/platform/lang-api/src/com/intellij/ide/util/gotoByName/ChooseByNameModel.java +++ b/platform/lang-api/src/com/intellij/ide/util/gotoByName/ChooseByNameModel.java @@ -33,7 +33,7 @@ public interface ChooseByNameModel { * @deprecated Mark mnemonic char with '&' ('&&' for mac if mnemonic char is 'N') in checkbox name instead */ @Deprecated - char getCheckBoxMnemonic(); + default char getCheckBoxMnemonic() { return 0; } boolean loadInitialCheckBoxState(); diff --git a/platform/lang-api/src/com/intellij/task/ProjectTaskManager.java b/platform/lang-api/src/com/intellij/task/ProjectTaskManager.java index ba759b691f30..1d8aadf583ed 100644 --- a/platform/lang-api/src/com/intellij/task/ProjectTaskManager.java +++ b/platform/lang-api/src/com/intellij/task/ProjectTaskManager.java @@ -140,12 +140,4 @@ public abstract class ProjectTaskManager { boolean includeRuntimeDependencies); public abstract ProjectTask createBuildTask(boolean isIncrementalBuild, ProjectModelBuildableElement... artifacts); - - /** - * @deprecated use {@link #createBuildTask(boolean, ProjectModelBuildableElement...)} - */ - @Deprecated - public ProjectTask createArtifactsBuildTask(boolean isIncrementalBuild, ProjectModelBuildableElement... artifacts) { - return createBuildTask(isIncrementalBuild, artifacts); - } } diff --git a/platform/lang-impl/src/com/intellij/application/options/CodeStyleSettingsUtilImpl.java b/platform/lang-impl/src/com/intellij/application/options/CodeStyleSettingsUtilImpl.java deleted file mode 100644 index 89a8341ec05b..000000000000 --- a/platform/lang-impl/src/com/intellij/application/options/CodeStyleSettingsUtilImpl.java +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright 2000-2017 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.application.options; - -import com.intellij.openapi.options.ShowSettingsUtil; -import com.intellij.openapi.project.Project; -import com.intellij.psi.codeStyle.CodeStyleSettings; -import com.intellij.psi.codeStyle.CodeStyleSettingsManager; - -public class CodeStyleSettingsUtilImpl extends CodeStyleSettingsUtil { - /** - * Shows code style settings suitable for the project passed. I.e. it shows project code style page if one - * is configured to use own code style scheme or global one in other case. - * @param project - * @return Returns true if settings were modified during editing session. - */ - @Override - public boolean showCodeStyleSettings(Project project, final Class pageToSelect) { - CodeStyleSettingsManager settingsManager = CodeStyleSettingsManager.getInstance(project); - CodeStyleSettings savedSettings = settingsManager.getCurrentSettings().clone(); - ShowSettingsUtil.getInstance().editConfigurable(project, new CodeStyleSchemesConfigurable(project)); - return !savedSettings.equals(settingsManager.getCurrentSettings()); - } -} \ No newline at end of file diff --git a/platform/lang-impl/src/com/intellij/codeInsight/TargetElementUtilBase.java b/platform/lang-impl/src/com/intellij/codeInsight/TargetElementUtilBase.java index 0fb7eb506dec..d1e0f9d71aef 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/TargetElementUtilBase.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/TargetElementUtilBase.java @@ -29,11 +29,8 @@ import java.util.Collection; /** * @deprecated Use {@link TargetElementUtil} instead. To be removed in IntelliJ IDEA 16. */ +@Deprecated public abstract class TargetElementUtilBase { - public static final int REFERENCED_ELEMENT_ACCEPTED = 0x01; - public static final int ELEMENT_NAME_ACCEPTED = 0x02; - public static final int LOOKUP_ITEM_ACCEPTED = 0x08; - public static TargetElementUtilBase getInstance() { return TargetElementUtil.getInstance(); } diff --git a/platform/lang-impl/src/com/intellij/codeInsight/highlighting/HighlightManagerImpl.java b/platform/lang-impl/src/com/intellij/codeInsight/highlighting/HighlightManagerImpl.java index f56fb626b8b1..d25042434834 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/highlighting/HighlightManagerImpl.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/highlighting/HighlightManagerImpl.java @@ -150,15 +150,6 @@ public class HighlightManagerImpl extends HighlightManager { editor.getScrollingModel().scrollVertically(verticalScrollOffset); } - @Override - public void addElementsOccurrenceHighlights(@NotNull Editor editor, - @NotNull PsiElement[] elements, - @NotNull TextAttributes attributes, - boolean hideByTextChange, - Collection outHighlighters) { - addOccurrenceHighlights(editor, elements, attributes, hideByTextChange, outHighlighters); - } - @Override public void addOccurrenceHighlight(@NotNull Editor editor, int start, diff --git a/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupEx.java b/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupEx.java index 3e174aa0732a..cb88949114ed 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupEx.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupEx.java @@ -15,8 +15,6 @@ */ package com.intellij.codeInsight.lookup; -import com.intellij.openapi.ui.popup.JBPopup; - import java.awt.*; /** @@ -25,11 +23,6 @@ import java.awt.*; public interface LookupEx extends Lookup { void setCurrentItem(LookupElement item); - /** - * @deprecated use PopupPositionManager instead - */ - void showItemPopup(JBPopup hint); - Component getComponent(); boolean showElementActions(); diff --git a/platform/lang-impl/src/com/intellij/codeInsight/lookup/impl/LookupImpl.java b/platform/lang-impl/src/com/intellij/codeInsight/lookup/impl/LookupImpl.java index 22b32fdc9b81..d1c43f4ee66d 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/lookup/impl/LookupImpl.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/lookup/impl/LookupImpl.java @@ -1092,8 +1092,7 @@ public class LookupImpl extends LightweightHint implements LookupEx, Disposable, } } - @Override - public void showItemPopup(JBPopup hint) { + private void showItemPopup(JBPopup hint) { final Rectangle bounds = getCurrentItemBounds(); hint.show(new RelativePoint(getComponent(), new Point(bounds.x + bounds.width, bounds.y))); } diff --git a/platform/lang-impl/src/com/intellij/execution/impl/RunConfigurationBeforeRunProvider.java b/platform/lang-impl/src/com/intellij/execution/impl/RunConfigurationBeforeRunProvider.java index 53a08c1ed692..3e272253cc0d 100644 --- a/platform/lang-impl/src/com/intellij/execution/impl/RunConfigurationBeforeRunProvider.java +++ b/platform/lang-impl/src/com/intellij/execution/impl/RunConfigurationBeforeRunProvider.java @@ -162,14 +162,6 @@ extends BeforeRunTaskProvider items, final String title) { return NavigationUtil.getRelatedItemsPopup(items, title); } - - /** - * @deprecated - * @see com.intellij.codeInsight.navigation.NavigationUtil#collectRelatedItems(com.intellij.psi.PsiElement, com.intellij.openapi.actionSystem.DataContext) - */ - public static List getItems(@NotNull PsiElement contextElement, @Nullable DataContext dataContext) { - return NavigationUtil.collectRelatedItems(contextElement, dataContext); - } } diff --git a/platform/lang-impl/src/com/intellij/ide/favoritesTreeView/FavoritesManager.java b/platform/lang-impl/src/com/intellij/ide/favoritesTreeView/FavoritesManager.java index adddd0d5e689..e83751ca7442 100644 --- a/platform/lang-impl/src/com/intellij/ide/favoritesTreeView/FavoritesManager.java +++ b/platform/lang-impl/src/com/intellij/ide/favoritesTreeView/FavoritesManager.java @@ -125,31 +125,17 @@ public class FavoritesManager implements ProjectComponent, JDOMExternalizable { } } - /** - * @deprecated use {@link #addFavoritesListener(FavoritesListener, Disposable)} instead - */ - public void addFavoritesListener(FavoritesListener listener) { - myListeners.add(listener); - listener.rootsChanged(); - } public void addFavoritesListener(final FavoritesListener listener, @NotNull Disposable parent) { myListeners.add(listener); listener.rootsChanged(); Disposer.register(parent, new Disposable() { @Override public void dispose() { - removeFavoritesListener(listener); + myListeners.remove(listener); } }); } - /** - * @deprecated use {@link #addFavoritesListener(FavoritesListener, Disposable)} instead - */ - public void removeFavoritesListener(FavoritesListener listener) { - myListeners.remove(listener); - } - List createRootNodes() { List result = new ArrayList<>(); for (String listName : myFavoritesRootsOrder) { diff --git a/platform/lang-impl/src/com/intellij/ide/util/TreeFileChooserDialog.java b/platform/lang-impl/src/com/intellij/ide/util/TreeFileChooserDialog.java index 84accfac0086..6e5da37c6359 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/TreeFileChooserDialog.java +++ b/platform/lang-impl/src/com/intellij/ide/util/TreeFileChooserDialog.java @@ -370,10 +370,6 @@ public final class TreeFileChooserDialog extends DialogWrapper implements TreeFi return null; } - @Override - public char getCheckBoxMnemonic() { - return 0; - } @Override public String getNotInMessage() { diff --git a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoActionModel.java b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoActionModel.java index 931d9e0e81a1..6fe8a45fa0ca 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoActionModel.java +++ b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoActionModel.java @@ -137,10 +137,6 @@ public class GotoActionModel implements ChooseByNameModel, Comparator, D return IdeBundle.message("checkbox.disabled.included"); } - @Override - public char getCheckBoxMnemonic() { - return 'd'; - } @Override public String getNotInMessage() { diff --git a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoClassModel2.java b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoClassModel2.java index 58c4067a491e..6ecf830bc321 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoClassModel2.java +++ b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoClassModel2.java @@ -24,7 +24,6 @@ import com.intellij.navigation.ChooseByNameRegistry; import com.intellij.navigation.GotoClassContributor; import com.intellij.navigation.NavigationItem; import com.intellij.openapi.project.Project; -import com.intellij.openapi.util.SystemInfo; import com.intellij.openapi.util.text.StringUtil; import com.intellij.psi.PsiElement; import com.intellij.ui.IdeUICustomization; @@ -82,12 +81,6 @@ public class GotoClassModel2 extends FilteringGotoByModel { return IdeBundle.message("label.no.matches.found"); } - @Override - public char getCheckBoxMnemonic() { - // Some combination like Alt+N, Ant+O, etc are a dead symbols, therefore - // we have to change mnemonics for Mac users. - return SystemInfo.isMac?'P':'n'; - } @Override public boolean loadInitialCheckBoxState() { diff --git a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoFileModel.java b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoFileModel.java index e3d7a24066b5..b9df4e25262c 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoFileModel.java +++ b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoFileModel.java @@ -98,10 +98,6 @@ public class GotoFileModel extends FilteringGotoByModel implements Dum return IdeBundle.message("checkbox.include.non.project.files", IdeUICustomization.getInstance().getProjectConceptName()); } - @Override - public char getCheckBoxMnemonic() { - return SystemInfo.isMac?'P':'n'; - } @Override public String getNotInMessage() { diff --git a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoSymbolModel2.java b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoSymbolModel2.java index 6886296e0e68..17658e2e5f44 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoSymbolModel2.java +++ b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/GotoSymbolModel2.java @@ -23,7 +23,6 @@ import com.intellij.navigation.ChooseByNameRegistry; import com.intellij.navigation.GotoClassContributor; import com.intellij.navigation.NavigationItem; import com.intellij.openapi.project.Project; -import com.intellij.openapi.util.SystemInfo; import com.intellij.psi.PsiElement; import com.intellij.psi.presentation.java.SymbolPresentationUtil; import com.intellij.ui.IdeUICustomization; @@ -80,12 +79,6 @@ public class GotoSymbolModel2 extends FilteringGotoByModel { return IdeBundle.message("label.no.matches.found"); } - @Override - public char getCheckBoxMnemonic() { - // Some combination like Alt+N, Ant+O, etc are a dead symbols, therefore - // we have to change mnemonics for Mac users. - return SystemInfo.isMac?'P':'n'; - } @Override public boolean loadInitialCheckBoxState() { diff --git a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/SimpleChooseByNameModel.java b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/SimpleChooseByNameModel.java index 00f3d4cf6bd3..656cc781a126 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/gotoByName/SimpleChooseByNameModel.java +++ b/platform/lang-impl/src/com/intellij/ide/util/gotoByName/SimpleChooseByNameModel.java @@ -64,10 +64,6 @@ public abstract class SimpleChooseByNameModel implements ChooseByNameModel { return null; } - @Override - public char getCheckBoxMnemonic() { - return 0; - } @Override public boolean loadInitialCheckBoxState() { diff --git a/platform/lang-impl/src/com/intellij/openapi/fileEditor/impl/TestEditorManagerImpl.java b/platform/lang-impl/src/com/intellij/openapi/fileEditor/impl/TestEditorManagerImpl.java index 417c687b9247..2b6f9ee39cdc 100644 --- a/platform/lang-impl/src/com/intellij/openapi/fileEditor/impl/TestEditorManagerImpl.java +++ b/platform/lang-impl/src/com/intellij/openapi/fileEditor/impl/TestEditorManagerImpl.java @@ -429,14 +429,6 @@ final class TestEditorManagerImpl extends FileEditorManagerEx implements Disposa return result; } - @Override - public void showEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) { - } - - - @Override - public void removeEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) { - } @Override public Editor openTextEditor(@NotNull OpenFileDescriptor descriptor, boolean focusEditor) { diff --git a/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/CodeStyleFacadeImpl.java b/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/CodeStyleFacadeImpl.java index dc22436cfcb8..bb952cc86b5b 100644 --- a/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/CodeStyleFacadeImpl.java +++ b/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/CodeStyleFacadeImpl.java @@ -92,11 +92,6 @@ public class CodeStyleFacadeImpl extends CodeStyleFacade { return CodeStyle.getProjectOrDefaultSettings(myProject).getTabSize(fileType); } - @Override - public boolean isSmartTabs(final FileType fileType) { - return CodeStyle.getProjectOrDefaultSettings(myProject).isSmartTabs(fileType); - } - @Override public boolean useTabCharacter(final FileType fileType) { return CodeStyle.getProjectOrDefaultSettings(myProject).useTabCharacter(fileType); diff --git a/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/lineIndent/IndentCalculator.java b/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/lineIndent/IndentCalculator.java index 43d342da48a7..6d26640fd4f2 100644 --- a/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/lineIndent/IndentCalculator.java +++ b/platform/lang-impl/src/com/intellij/psi/impl/source/codeStyle/lineIndent/IndentCalculator.java @@ -31,12 +31,9 @@ import com.intellij.util.text.CharArrayUtil; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; -import java.util.Objects; - import static com.intellij.formatting.Indent.Type.CONTINUATION; import static com.intellij.formatting.Indent.Type.NORMAL; import static com.intellij.formatting.Indent.Type.SPACES; -import static com.intellij.psi.impl.source.codeStyle.lineIndent.JavaLikeLangLineIndentProvider.getDefaultIndentFromType; public class IndentCalculator { @@ -45,16 +42,6 @@ public class IndentCalculator { private @NotNull final BaseLineOffsetCalculator myBaseLineOffsetCalculator; private @NotNull final Indent myIndent; - /** - * @deprecated Please, use IndentCalculator(Project, Editor, BaseLineOffsetCalculator, Indent) instead. - */ - public IndentCalculator(@NotNull Project project, - @NotNull Editor editor, - @NotNull BaseLineOffsetCalculator baseLineOffsetCalculator, - @NotNull Indent.Type type) { - this(project, editor, baseLineOffsetCalculator, Objects.requireNonNull(getDefaultIndentFromType(type))); - } - public IndentCalculator(@NotNull Project project, @NotNull Editor editor, @NotNull BaseLineOffsetCalculator baseLineOffsetCalculator, diff --git a/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java b/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java index 2f73777cc9ad..238a509cba9d 100644 --- a/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java +++ b/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java @@ -129,14 +129,7 @@ public class RenameDialog extends RefactoringDialog { super.dispose(); } - @SuppressWarnings("deprecation") protected boolean isToSearchForTextOccurrencesForRename() { - return isToSearchForTextOccurencesForRename(); - } - - /** @deprecated use/override {@link #isToSearchForTextOccurrencesForRename()} instead (to be deleted in IDEA 2018) */ - @SuppressWarnings({"SpellCheckingInspection", "DeprecatedIsStillUsed"}) - protected boolean isToSearchForTextOccurencesForRename() { return RenamePsiElementProcessor.forElement(myPsiElement).isToSearchForTextOccurrences(myPsiElement); } diff --git a/platform/lang-impl/src/com/intellij/refactoring/rename/RenameHandlerRegistry.java b/platform/lang-impl/src/com/intellij/refactoring/rename/RenameHandlerRegistry.java index 0964ca18e683..9e6a56be5ea3 100644 --- a/platform/lang-impl/src/com/intellij/refactoring/rename/RenameHandlerRegistry.java +++ b/platform/lang-impl/src/com/intellij/refactoring/rename/RenameHandlerRegistry.java @@ -31,16 +31,12 @@ import com.intellij.refactoring.RefactoringBundle; import com.intellij.refactoring.rename.inplace.MemberInplaceRenameHandler; import com.intellij.refactoring.util.RadioUpDownListener; import com.intellij.util.ArrayUtil; -import java.util.HashSet; import org.jetbrains.annotations.Nullable; import javax.swing.*; import java.awt.event.ItemEvent; import java.awt.event.ItemListener; -import java.util.Iterator; -import java.util.Map; -import java.util.Set; -import java.util.TreeMap; +import java.util.*; /** * @author dsl @@ -109,14 +105,6 @@ public class RenameHandlerRegistry { return renameHandler instanceof TitledHandler ? StringUtil.capitalize(((TitledHandler)renameHandler).getActionTitle().toLowerCase()) : renameHandler.toString(); } - /** - * @deprecated - * @see RenameHandler#EP_NAME - */ - public void registerHandler(RenameHandler handler) { - myHandlers.add(handler); - } - private static class HandlersChooser extends DialogWrapper { private final String[] myRenamers; private String mySelection; diff --git a/platform/platform-api/src/com/intellij/codeStyle/CodeStyleFacade.java b/platform/platform-api/src/com/intellij/codeStyle/CodeStyleFacade.java index a1140ffd92ef..19770bf176c9 100644 --- a/platform/platform-api/src/com/intellij/codeStyle/CodeStyleFacade.java +++ b/platform/platform-api/src/com/intellij/codeStyle/CodeStyleFacade.java @@ -80,12 +80,6 @@ public abstract class CodeStyleFacade { @Deprecated public abstract int getIndentSize(FileType fileType); - /** - * @deprecated - */ - @Deprecated - public abstract boolean isSmartTabs(final FileType fileType); - /** * @deprecated Use {@code getRightMargin(Language)} method of {@code CodeStyle.getSettings(PsiFile)} or * {@code CodeStyle.getSettings(Project)} if there is no {@code PsiFile} diff --git a/platform/platform-api/src/com/intellij/execution/configurations/PathEnvironmentVariableUtil.java b/platform/platform-api/src/com/intellij/execution/configurations/PathEnvironmentVariableUtil.java index a15cdacb8e22..315ee911dd42 100644 --- a/platform/platform-api/src/com/intellij/execution/configurations/PathEnvironmentVariableUtil.java +++ b/platform/platform-api/src/com/intellij/execution/configurations/PathEnvironmentVariableUtil.java @@ -64,19 +64,6 @@ public class PathEnvironmentVariableUtil { return ContainerUtil.getFirstItem(exeFiles); } - /** - * Finds an executable file with the specified base name, that is located in a directory - * listed in an original PATH environment variable. - * Original PATH environment variable value is a value returned by {@code System.getenv("PATH")}. - * - * @param fileBaseName file base name - * @return {@link File} instance or null if not found - */ - private static File findInOriginalPath(@NotNull String fileBaseName) { - List exeFiles = findExeFilesInPath(true, null, System.getenv(PATH), fileBaseName); - return ContainerUtil.getFirstItem(exeFiles); - } - /** * Finds all executable files with the specified base name, that are located in directories * from PATH environment variable. @@ -128,25 +115,6 @@ public class PathEnvironmentVariableUtil { return StringUtil.split(pathEnvVarValue, File.pathSeparator, true, true); } - /** @deprecated obsolete; the behavior is incorporated in {@link GeneralCommandLine#createProcess()} (to be removed in IDEA 2019) */ - @Deprecated - @NotNull - public static String toLocatableExePath(@NotNull String exePath) { - if (SystemInfo.isMac) { - if (!StringUtil.containsChar(exePath, '/') && !StringUtil.containsChar(exePath, '\\')) { - File originalResolvedExeFile = findInOriginalPath(exePath); - // don't modify exePath if the absolute path can be found in the original PATH - if (originalResolvedExeFile == null) { - File resolvedExeFile = findInPath(exePath); - if (resolvedExeFile != null) { - exePath = resolvedExeFile.getAbsolutePath(); - } - } - } - } - return exePath; - } - @NotNull public static List getWindowsExecutableFileExtensions() { if (SystemInfo.isWindows) { diff --git a/platform/platform-api/src/com/intellij/openapi/actionSystem/DataConstants.java b/platform/platform-api/src/com/intellij/openapi/actionSystem/DataConstants.java index f1ecedd7e270..864d2cdc0355 100644 --- a/platform/platform-api/src/com/intellij/openapi/actionSystem/DataConstants.java +++ b/platform/platform-api/src/com/intellij/openapi/actionSystem/DataConstants.java @@ -23,6 +23,7 @@ import org.jetbrains.annotations.NonNls; * * @deprecated {@link DataKeys} and {@link DataKey#getData} should be used instead */ +@Deprecated @SuppressWarnings({"HardCodedStringLiteral", "JavadocReference"}) public interface DataConstants { /** @@ -30,221 +31,40 @@ public interface DataConstants { * * @deprecated use {@link PlatformDataKeys#PROJECT} instead */ - String PROJECT = CommonDataKeys.PROJECT.getName(); + @Deprecated String PROJECT = CommonDataKeys.PROJECT.getName(); /** * Returns {@link com.intellij.openapi.module.Module} * * @deprecated use {@link com.intellij.openapi.actionSystem.LangDataKeys#MODULE} instead */ - @NonNls String MODULE = "module"; + @Deprecated @NonNls String MODULE = "module"; /** * Returns {@link com.intellij.openapi.vfs.VirtualFile} * * @deprecated use {@link PlatformDataKeys#VIRTUAL_FILE} instead */ - String VIRTUAL_FILE = CommonDataKeys.VIRTUAL_FILE.getName(); + @Deprecated String VIRTUAL_FILE = CommonDataKeys.VIRTUAL_FILE.getName(); /** * Returns array of {@link com.intellij.openapi.vfs.VirtualFile} * * @deprecated use {@link PlatformDataKeys#VIRTUAL_FILE_ARRAY} instead */ - String VIRTUAL_FILE_ARRAY = CommonDataKeys.VIRTUAL_FILE_ARRAY.getName(); + @Deprecated String VIRTUAL_FILE_ARRAY = CommonDataKeys.VIRTUAL_FILE_ARRAY.getName(); /** * Returns {@link com.intellij.openapi.editor.Editor} * * @deprecated use {@link PlatformDataKeys#EDITOR} instead */ - String EDITOR = CommonDataKeys.EDITOR.getName(); + @Deprecated String EDITOR = CommonDataKeys.EDITOR.getName(); /** * Returns {@link com.intellij.openapi.fileEditor.FileEditor} * * @deprecated use {@link PlatformDataKeys#FILE_EDITOR} instead */ - String FILE_EDITOR = PlatformDataKeys.FILE_EDITOR.getName(); - - /** - * Returns {@link com.intellij.openapi.fileEditor.OpenFileDescriptor} - * - * @deprecated {@link PlatformDataKeys#NAVIGATABLE} should be used instead - */ - @NonNls String OPEN_FILE_DESCRIPTOR = "openFileDescriptor"; - - /** - * Returns the text of currently selected file/file revision - * - * @deprecated use {@link PlatformDataKeys#FILE_TEXT} instead - */ - String FILE_TEXT = PlatformDataKeys.FILE_TEXT.getName(); - - /** - * Returns Boolean.TRUE if action is executed in modal context and - * Boolean.FALSE if action is executed not in modal context. If context - * is unknown then the value of this data constant is {@code null}. - * - * @deprecated use {@link PlatformDataKeys#IS_MODAL_CONTEXT} instead - */ - String IS_MODAL_CONTEXT = PlatformDataKeys.IS_MODAL_CONTEXT.getName(); - - /** - * Returns {@link com.intellij.openapi.diff.DiffViewer} - * - * @deprecated use {@link PlatformDataKeys#DIFF_VIEWER} instead - */ - String DIFF_VIEWER = PlatformDataKeys.DIFF_VIEWER.getName(); - - /** - * Returns help id (String) - * - * @deprecated use {@link PlatformDataKeys#HELP_ID} instead - */ - String HELP_ID = PlatformDataKeys.HELP_ID.getName(); - - /** - * Returns project if project node is selected (in project view) - * - * @deprecated use {@link PlatformDataKeys#PROJECT_CONTEXT} instead - */ - String PROJECT_CONTEXT = PlatformDataKeys.PROJECT_CONTEXT.getName(); - - /** - * Returns module if module node is selected (in module view) - * - * @deprecated use {@link com.intellij.openapi.actionSystem.LangDataKeys#MODULE_CONTEXT} instead - */ - @NonNls String MODULE_CONTEXT = "context.Module"; - - /** - * @deprecated use {@link com.intellij.openapi.actionSystem.LangDataKeys#MODULE_CONTEXT_ARRAY} instead - */ - @NonNls String MODULE_CONTEXT_ARRAY = "context.Module.Array"; - - /** - * Returns {@link com.intellij.pom.Navigatable} - * - * @deprecated use {@link PlatformDataKeys#NAVIGATABLE} instead - */ - String NAVIGATABLE = CommonDataKeys.NAVIGATABLE.getName(); - - /** - * Returns an array of {@link com.intellij.pom.Navigatable} - * - * @deprecated use {@link PlatformDataKeys#NAVIGATABLE_ARRAY} instead - */ - String NAVIGATABLE_ARRAY = CommonDataKeys.NAVIGATABLE_ARRAY.getName(); - - /** - * Returns {@link com.intellij.ide.ExporterToTextFile} - * - * @deprecated use {@link PlatformDataKeys#EXPORTER_TO_TEXT_FILE} instead - */ - String EXPORTER_TO_TEXT_FILE = PlatformDataKeys.EXPORTER_TO_TEXT_FILE.getName(); - - /** - * Returns {@link com.intellij.psi.PsiElement} - * - * @deprecated use {@link CommonDataKeys#PSI_ELEMENT} instead - */ - @NonNls String PSI_ELEMENT = "psi.Element"; - - /** - * Returns {@link com.intellij.psi.PsiFile} - * - * @deprecated use {@link CommonDataKeys#PSI_FILE} instead - */ - @NonNls String PSI_FILE = "psi.File"; - - /** - * Returns {@link com.intellij.lang.Language} - * - * @deprecated use {@link com.intellij.openapi.actionSystem.LangDataKeys#LANGUAGE} instead - */ - @NonNls String LANGUAGE = "Language"; - - /** - * Returns java.awt.Component currently in focus, DataContext should be retrieved for - * - * @deprecated use {@link PlatformDataKeys#CONTEXT_COMPONENT} instead - */ - String CONTEXT_COMPONENT = PlatformDataKeys.CONTEXT_COMPONENT.getName(); - - /** - * Returns {@link com.intellij.ide.IdeView} (one of project, packages, commander or favorites view). - * - * @since 5.1 - * @deprecated use {@link com.intellij.openapi.actionSystem.LangDataKeys#IDE_VIEW} instead - */ - @NonNls String IDE_VIEW = "IDEView"; - - /** - * Returns array of selected {@link com.intellij.openapi.vcs.changes.ChangeList}s. - * - * @since 6.0 - * @deprecated use {@link com.intellij.openapi.vcs.VcsDataKeys#CHANGE_LISTS} instead - */ - @NonNls String CHANGE_LISTS = "vcs.ChangeList"; - - /** - * Returns array of selected {@link com.intellij.openapi.vcs.changes.Change}s. - * - * @since 6.0 - * @deprecated use {@link com.intellij.openapi.vcs.VcsDataKeys#CHANGES} instead - */ - @NonNls String CHANGES = "vcs.Change"; - - /** - * Returns com.intellij.psi.PsiElement[] - * - * @deprecated use {@link com.intellij.openapi.actionSystem.LangDataKeys#PSI_ELEMENT_ARRAY} instead - */ - @NonNls String PSI_ELEMENT_ARRAY = "psi.Element.array"; - - /** - * Returns com.intellij.ide.CopyProvider - * - * @deprecated use {@link PlatformDataKeys#COPY_PROVIDER} instead - */ - String COPY_PROVIDER = PlatformDataKeys.COPY_PROVIDER.getName(); - - /** - * Returns com.intellij.ide.CutProvider - * - * @deprecated use {@link PlatformDataKeys#CUT_PROVIDER} instead - */ - String CUT_PROVIDER = PlatformDataKeys.CUT_PROVIDER.getName(); - - /** - * Returns com.intellij.ide.PasteProvider - * - * @deprecated use {@link PlatformDataKeys#PASTE_PROVIDER} instead - */ - String PASTE_PROVIDER = PlatformDataKeys.PASTE_PROVIDER.getName(); - - /** - * Returns com.intellij.ide.DeleteProvider - * - * @deprecated use {@link PlatformDataKeys#DELETE_ELEMENT_PROVIDER} instead - */ - String DELETE_ELEMENT_PROVIDER = PlatformDataKeys.DELETE_ELEMENT_PROVIDER.getName(); - - /** - * Returns com.intellij.openapi.editor.Editor even if focuses currently is in find bar - * - * @deprecated use {@link PlatformDataKeys#EDITOR} instead - */ - String EDITOR_EVEN_IF_INACTIVE = CommonDataKeys.EDITOR_EVEN_IF_INACTIVE.getName(); - - /** - * @deprecated use {@link PlatformDataKeys#SELECTED_ITEM} instead - */ - String SELECTED_ITEM = PlatformDataKeys.SELECTED_ITEM.getName(); - - /** - * @deprecated use {@link PlatformDataKeys#DOMINANT_HINT_AREA_RECTANGLE} instead - */ - String DOMINANT_HINT_AREA_RECTANGLE = PlatformDataKeys.DOMINANT_HINT_AREA_RECTANGLE.getName(); + @Deprecated String FILE_EDITOR = PlatformDataKeys.FILE_EDITOR.getName(); } diff --git a/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/DataConstantsEx.java b/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/DataConstantsEx.java deleted file mode 100644 index eb9366f23ada..000000000000 --- a/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/DataConstantsEx.java +++ /dev/null @@ -1,112 +0,0 @@ -/* - * Copyright 2000-2015 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.intellij.openapi.actionSystem.ex; - -import org.jetbrains.annotations.NonNls; - - -/** - * Identifiers for data items which can be returned from {@link com.intellij.openapi.actionSystem.DataContext#getData(String)} and - * {@link com.intellij.openapi.actionSystem.DataProvider#getData(String)}. - * @deprecated {@link DataKeys} and {@link com.intellij.openapi.actionSystem.DataKey#getData} should be used instead - */ -@Deprecated -@SuppressWarnings({"HardCodedStringLiteral", "JavadocReference"}) -public interface DataConstantsEx { - /** - * Returns {@link com.intellij.psi.PsiElement} - */ - @NonNls String TARGET_PSI_ELEMENT = "psi.TargetElement"; - /** - * Returns {@link com.intellij.psi.PsiElement} - */ - @NonNls String PASTE_TARGET_PSI_ELEMENT = "psi.pasteTargetElement"; - /** - * Returns {@link com.intellij.usages.UsageView} - */ - @NonNls String USAGE_VIEW = "usageView"; - /** - * Returns {@link com.intellij.codeInspection.ui.InspectionResultsView} - */ - @NonNls String INSPECTION_VIEW = "inspectionView"; - /** - * Returns {@link com.intellij.ide.TreeExpander} - */ - @NonNls String TREE_EXPANDER = "treeExpander"; - /** - * Returns {@link com.intellij.ui.content.ContentManager} - */ - @NonNls String CONTENT_MANAGER = "contentManager"; - - @NonNls String NONEMPTY_CONTENT_MANAGER = "nonemptyContentManager"; - - /** - * Returns {@link com.intellij.execution.configurations.RuntimeConfiguration} - */ - @NonNls String RUNTIME_CONFIGURATION = "runtimeConfiguration"; - - /** - * Returns project file directory as {@link com.intellij.openapi.vfs.VirtualFile} - */ - @NonNls String PROJECT_FILE_DIRECTORY = "context.ProjectFileDirectory"; - - /** - * returns {@link com.intellij.openapi.application.ModalityState} - */ - @NonNls String MODALITY_STATE = "ModalityState"; - - /** - * returns Boolean - */ - @NonNls String SOURCE_NAVIGATION_LOCKED = "sourceNavigationLocked"; - - /** - * returns array of {@link com.intellij.ide.projectView.impl.ModuleGroup} - */ - @NonNls String MODULE_GROUP_ARRAY = "moduleGroup.array"; - - /** - * returns array of {@link com.intellij.ide.projectView.impl.nodes.LibraryGroupElement} - */ - @NonNls String LIBRARY_GROUP_ARRAY = "libraryGroup.array"; - - /** - * returns array of {@link com.intellij.ide.projectView.impl.nodes.NamedLibraryElement} - */ - @NonNls String NAMED_LIBRARY_ARRAY = "namedLibrary.array"; - - /** - * returns {@link com.intellij.openapi.fileEditor.impl.EditorWindow} - */ - @NonNls String EDITOR_WINDOW = "editorWindow"; - - /** - * returns array of {@link com.intellij.lang.properties.ResourceBundle} - */ - @NonNls String RESOURCE_BUNDLE_ARRAY = "resource.bundle.array"; - - - /** - * returns {@link com.intellij.openapi.module.ModifiableModuleModel} - */ - @NonNls String MODIFIABLE_MODULE_MODEL = "modifiable.module.model"; - - /** - * returns {@link com.intellij.ide.projectView.impl.nodes.PackageElement} - */ - @NonNls String PACKAGE_ELEMENT = "package.element"; -} diff --git a/platform/platform-api/src/com/intellij/openapi/fileEditor/FileEditorManager.java b/platform/platform-api/src/com/intellij/openapi/fileEditor/FileEditorManager.java index be47d414fbc5..c91930753fb7 100644 --- a/platform/platform-api/src/com/intellij/openapi/fileEditor/FileEditorManager.java +++ b/platform/platform-api/src/com/intellij/openapi/fileEditor/FileEditorManager.java @@ -146,12 +146,12 @@ public abstract class FileEditorManager { * @deprecated use addTopComponent */ @Deprecated - public abstract void showEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent); + public void showEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) {} /** * @deprecated use removeTopComponent */ @Deprecated - public abstract void removeEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent); + public void removeEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) {} /** * Adds the specified component above the editor and paints a separator line below it. diff --git a/platform/platform-api/src/com/intellij/openapi/vfs/LocalFileSystem.java b/platform/platform-api/src/com/intellij/openapi/vfs/LocalFileSystem.java index e2884c53dd41..8830aa7db5f3 100644 --- a/platform/platform-api/src/com/intellij/openapi/vfs/LocalFileSystem.java +++ b/platform/platform-api/src/com/intellij/openapi/vfs/LocalFileSystem.java @@ -2,7 +2,6 @@ package com.intellij.openapi.vfs; import com.intellij.openapi.vfs.newvfs.NewVirtualFileSystem; -import com.intellij.util.Processor; import org.jetbrains.annotations.NonNls; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -119,8 +118,4 @@ public abstract class LocalFileSystem extends NewVirtualFileSystem { * @param handler the handler instance. */ public abstract void unregisterAuxiliaryFileOperationsHandler(@NotNull LocalFileOperationsHandler handler); - - /** @deprecated use {@link VfsUtilCore#visitChildrenRecursively(VirtualFile, VirtualFileVisitor)} (to be removed in IDEA 2019) */ - @Deprecated - public abstract boolean processCachedFilesInSubtree(@NotNull VirtualFile file, @NotNull Processor processor); } \ No newline at end of file diff --git a/platform/platform-api/src/com/intellij/openapi/vfs/newvfs/FileAttribute.java b/platform/platform-api/src/com/intellij/openapi/vfs/newvfs/FileAttribute.java index 154f4d88b24e..7b779cadb8f5 100644 --- a/platform/platform-api/src/com/intellij/openapi/vfs/newvfs/FileAttribute.java +++ b/platform/platform-api/src/com/intellij/openapi/vfs/newvfs/FileAttribute.java @@ -42,15 +42,6 @@ public class FileAttribute { this(id, UNDEFINED_VERSION, false); } - /** - * @deprecated - * @see #FileAttribute(String, int, boolean) - */ - @Deprecated - public FileAttribute(@NonNls @NotNull String id, int version) { - this(id, version, false); - } - public FileAttribute(@NonNls @NotNull String id, int version, boolean fixedSize) { this(version, fixedSize, id); boolean added = ourRegisteredIds.add(id); diff --git a/platform/platform-api/src/com/intellij/openapi/wm/WindowManager.java b/platform/platform-api/src/com/intellij/openapi/wm/WindowManager.java index d817ca31889a..47a2cc12be4e 100644 --- a/platform/platform-api/src/com/intellij/openapi/wm/WindowManager.java +++ b/platform/platform-api/src/com/intellij/openapi/wm/WindowManager.java @@ -78,16 +78,6 @@ public abstract class WindowManager { */ public abstract StatusBar getStatusBar(Project project); - /** - * Get the status bar for the component, it may be either the main status bar or the status bar for an undocked window - * - * @param c a component - * @return status bar - * @deprecated use getStatusBar(Component, Project) - */ - @Deprecated - public abstract StatusBar getStatusBar(@NotNull Component c); - public StatusBar getStatusBar(@NotNull Component c, @Nullable Project project) { return null; } @@ -105,13 +95,6 @@ public abstract class WindowManager { */ public abstract boolean isInsideScreenBounds(int x, int y, int width); - /** - * Tests whether the specified point is inside of screen bounds. Note, that - * all parameters are in screen coordinate system. - * The method properly works in multi-monitor configuration. - */ - public abstract boolean isInsideScreenBounds(int x, int y); - @NotNull public abstract IdeFrame[] getAllProjectFrames(); diff --git a/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java b/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java index b7da4c239103..3b660232cefa 100644 --- a/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java +++ b/platform/platform-api/src/com/intellij/ui/IdeBorderFactory.java @@ -103,16 +103,6 @@ public class IdeBorderFactory { return createTitledBorder(s, true); } - @Deprecated - public static IdeaTitledBorder createTitledBorder(String title, boolean hasBoldFont, boolean hasIndent, boolean hasSmallFont) { - return createTitledBorder(title, hasIndent); - } - - @Deprecated - public static IdeaTitledBorder createTitledBorder(String title, boolean hasBoldFont, boolean hasIndent, boolean hasSmallFont, Insets insets) { - return createTitledBorder(title, hasIndent, insets); - } - public static IdeaTitledBorder createTitledBorder(String title, boolean hasIndent) { Insets insets = new Insets(TITLED_BORDER_TOP_INSET, TITLED_BORDER_LEFT_INSET, TITLED_BORDER_BOTTOM_INSET, TITLED_BORDER_RIGHT_INSET); return createTitledBorder(title, hasIndent, insets); @@ -123,12 +113,6 @@ public class IdeBorderFactory { return new IdeaTitledBorder(title, indent, insets); } - @Deprecated - // Don't remove, used in TeamCity plugin. - public static TitledBorder createTitledHeaderBorder(String title) { - return new IdeaTitledBorder(title, 10, new Insets(5, 0, 10, 0)); - } - private static Color getBorderColor() { return JBColor.border(); } diff --git a/platform/platform-api/src/com/intellij/ui/content/ContentManager.java b/platform/platform-api/src/com/intellij/ui/content/ContentManager.java index 08386ba6c5b6..cbb029915dc9 100644 --- a/platform/platform-api/src/com/intellij/ui/content/ContentManager.java +++ b/platform/platform-api/src/com/intellij/ui/content/ContentManager.java @@ -35,11 +35,6 @@ public interface ContentManager extends Disposable, BusyObject { void addContent(@NotNull Content content); void addContent(@NotNull Content content, final int order); - /** - * @deprecated use {@link #addContent(Content)} instead, {@code constraints} parameter isn't used anyway - */ - void addContent(@NotNull Content content, Object constraints); - boolean removeContent(@NotNull Content content, final boolean dispose); @NotNull ActionCallback removeContent(@NotNull Content content, final boolean dispose, boolean trackFocus, boolean forcedFocus); diff --git a/platform/platform-api/src/com/intellij/ui/treeStructure/SimpleNodeRenderer.java b/platform/platform-api/src/com/intellij/ui/treeStructure/SimpleNodeRenderer.java deleted file mode 100644 index 6b64882d98ed..000000000000 --- a/platform/platform-api/src/com/intellij/ui/treeStructure/SimpleNodeRenderer.java +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Copyright 2000-2009 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.ui.treeStructure; - -import com.intellij.ide.util.treeView.NodeRenderer; - -/** - * @deprecated Use {@link NodeRenderer} instead - */ -@Deprecated -public class SimpleNodeRenderer extends NodeRenderer { - -} diff --git a/platform/platform-api/src/com/intellij/util/ui/Timer.java b/platform/platform-api/src/com/intellij/util/ui/Timer.java index 9c7e473bac15..c5115f3a6083 100644 --- a/platform/platform-api/src/com/intellij/util/ui/Timer.java +++ b/platform/platform-api/src/com/intellij/util/ui/Timer.java @@ -26,6 +26,7 @@ import java.util.concurrent.TimeUnit; /** * @deprecated use {@link JobScheduler#getScheduler()} instead */ +@Deprecated public abstract class Timer implements Disposable, Runnable { private final int mySpan; @@ -126,14 +127,6 @@ public abstract class Timer implements Disposable, Runnable { } } - public final void delay(int length) { - synchronized (LOCK) { - if (isDisposed() || !isRunning()) return; - myState = TimerState.pausing; - queue(this, length); - } - } - public final void resume() { synchronized (LOCK) { if (isDisposed() || isRunning()) return; @@ -156,7 +149,7 @@ public abstract class Timer implements Disposable, Runnable { } } - public boolean isRunning() { + private boolean isRunning() { synchronized (LOCK) { return myState == TimerState.running || myState == TimerState.initialSleep || myState == TimerState.restarting; } @@ -177,12 +170,8 @@ public abstract class Timer implements Disposable, Runnable { myFuture = schedule; } - public ScheduledFuture getFuture() { - return myFuture; - } - private static void queue(Timer timer, int span) { - final ScheduledFuture future = timer.getFuture(); + final ScheduledFuture future = timer.myFuture; if (future != null) { future.cancel(true); } diff --git a/platform/platform-api/src/com/intellij/util/ui/tree/TreeUtil.java b/platform/platform-api/src/com/intellij/util/ui/tree/TreeUtil.java index c351b2768ffc..3e4a29f0d656 100644 --- a/platform/platform-api/src/com/intellij/util/ui/tree/TreeUtil.java +++ b/platform/platform-api/src/com/intellij/util/ui/tree/TreeUtil.java @@ -746,15 +746,6 @@ public final class TreeUtil { selectNode(tree, treeNode); } - /** - * @deprecated use {@link #listChildren(TreeNode)} instead - */ - @Deprecated - @NotNull - public static ArrayList childrenToArray(@NotNull TreeNode node) { - return (ArrayList)listChildren(node); - } - @NotNull public static List listChildren(@NotNull final TreeNode node) { //ApplicationManager.getApplication().assertIsDispatchThread(); diff --git a/platform/platform-impl/src/com/intellij/execution/impl/EditorHyperlinkSupport.java b/platform/platform-impl/src/com/intellij/execution/impl/EditorHyperlinkSupport.java index ecbe16da80fd..293d4561735a 100644 --- a/platform/platform-impl/src/com/intellij/execution/impl/EditorHyperlinkSupport.java +++ b/platform/platform-impl/src/com/intellij/execution/impl/EditorHyperlinkSupport.java @@ -188,17 +188,6 @@ public class EditorHyperlinkSupport { return getHyperlinkAt(myEditor.logicalPositionToOffset(new LogicalPosition(line, col))); } - /** - * @deprecated for binary compatibility with older plugins - * @see #createHyperlink(int, int, TextAttributes, HyperlinkInfo) - */ - public void addHyperlink(final int highlightStartOffset, - final int highlightEndOffset, - @Nullable final TextAttributes highlightAttributes, - @NotNull final HyperlinkInfo hyperlinkInfo) { - createHyperlink(highlightStartOffset, highlightEndOffset, highlightAttributes, hyperlinkInfo); - } - @NotNull public RangeHighlighter createHyperlink(int highlightStartOffset, int highlightEndOffset, diff --git a/platform/platform-impl/src/com/intellij/openapi/fileEditor/impl/FileEditorManagerImpl.java b/platform/platform-impl/src/com/intellij/openapi/fileEditor/impl/FileEditorManagerImpl.java index 26f31678d16e..b4ec2be644f9 100644 --- a/platform/platform-impl/src/com/intellij/openapi/fileEditor/impl/FileEditorManagerImpl.java +++ b/platform/platform-impl/src/com/intellij/openapi/fileEditor/impl/FileEditorManagerImpl.java @@ -1390,15 +1390,6 @@ public class FileEditorManagerImpl extends FileEditorManagerEx implements Persis return result.toArray(new FileEditor[0]); } - @Override - public void showEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) { - addTopComponent(editor, annotationComponent); - } - - @Override - public void removeEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) { - removeTopComponent(editor, annotationComponent); - } @NotNull public List getTopComponents(@NotNull FileEditor editor) { diff --git a/platform/platform-impl/src/com/intellij/openapi/vfs/impl/local/LocalFileSystemBase.java b/platform/platform-impl/src/com/intellij/openapi/vfs/impl/local/LocalFileSystemBase.java index 0bb6b4560994..2781b00bba6c 100644 --- a/platform/platform-impl/src/com/intellij/openapi/vfs/impl/local/LocalFileSystemBase.java +++ b/platform/platform-impl/src/com/intellij/openapi/vfs/impl/local/LocalFileSystemBase.java @@ -265,12 +265,6 @@ public abstract class LocalFileSystemBase extends LocalFileSystem { } } - @Override - public boolean processCachedFilesInSubtree(@NotNull VirtualFile file, @NotNull Processor processor) { - return file.getFileSystem() != this - || processFile((NewVirtualFile)file, processor); - } - private static boolean processFile(@NotNull NewVirtualFile file, @NotNull Processor processor) { if (!processor.process(file)) return false; if (file.isDirectory()) { diff --git a/platform/platform-impl/src/com/intellij/openapi/wm/impl/TestWindowManager.java b/platform/platform-impl/src/com/intellij/openapi/wm/impl/TestWindowManager.java index 352e811955f8..fe0708f4e671 100644 --- a/platform/platform-impl/src/com/intellij/openapi/wm/impl/TestWindowManager.java +++ b/platform/platform-impl/src/com/intellij/openapi/wm/impl/TestWindowManager.java @@ -57,11 +57,6 @@ public final class TestWindowManager extends WindowManagerEx { @Override public final void doNotSuggestAsParent(final Window window) { } - @Override - public StatusBar getStatusBar(@NotNull Component c) { - return null; - } - @Override public final Window suggestParentWindow(@Nullable final Project project) { return null; @@ -174,11 +169,6 @@ public final class TestWindowManager extends WindowManagerEx { throw new UnsupportedOperationException(); } - @Override - public final boolean isInsideScreenBounds(final int x, final int y) { - throw new UnsupportedOperationException(); - } - @Override public final boolean isAlphaModeSupported() { return false; diff --git a/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowHeadlessManagerImpl.java b/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowHeadlessManagerImpl.java index 2b27368fd13e..0fea0cd0f8c1 100644 --- a/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowHeadlessManagerImpl.java +++ b/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowHeadlessManagerImpl.java @@ -482,11 +482,6 @@ public class ToolWindowHeadlessManagerImpl extends ToolWindowManagerEx { if (mySelected == null) setSelectedContent(content); } - @Override - public void addContent(@NotNull final Content content, final Object constraints) { - addContent(content); - } - @Override public void addSelectedContent(@NotNull final Content content) { addContent(content); diff --git a/platform/platform-impl/src/com/intellij/openapi/wm/impl/WindowManagerImpl.java b/platform/platform-impl/src/com/intellij/openapi/wm/impl/WindowManagerImpl.java index 72c94e4706e7..d539b0372c11 100644 --- a/platform/platform-impl/src/com/intellij/openapi/wm/impl/WindowManagerImpl.java +++ b/platform/platform-impl/src/com/intellij/openapi/wm/impl/WindowManagerImpl.java @@ -178,11 +178,6 @@ public final class WindowManagerImpl extends WindowManagerEx implements NamedCom return ScreenUtil.getAllScreensShape().contains(x, y, width, 1); } - @Override - public final boolean isInsideScreenBounds(final int x, final int y) { - return ScreenUtil.getAllScreensShape().contains(x, y); - } - @Override public final boolean isAlphaModeSupported() { if (myAlphaModeSupported == null) { @@ -353,11 +348,6 @@ public final class WindowManagerImpl extends WindowManagerEx implements NamedCom return frame == null ? null : frame.getStatusBar(); } - @Override - public StatusBar getStatusBar(@NotNull Component c) { - return getStatusBar(c, null); - } - @Override public StatusBar getStatusBar(@NotNull Component c, @Nullable Project project) { Component parent = UIUtil.findUltimateParent(c); diff --git a/platform/platform-impl/src/com/intellij/ui/content/impl/ContentManagerImpl.java b/platform/platform-impl/src/com/intellij/ui/content/impl/ContentManagerImpl.java index bc320eed961f..a3ea67995109 100644 --- a/platform/platform-impl/src/com/intellij/ui/content/impl/ContentManagerImpl.java +++ b/platform/platform-impl/src/com/intellij/ui/content/impl/ContentManagerImpl.java @@ -150,11 +150,6 @@ public class ContentManagerImpl implements ContentManager, PropertyChangeListene doAddContent(content, -1); } - @Override - public void addContent(@NotNull final Content content, final Object constraints) { - doAddContent(content, -1); - } - private void doAddContent(@NotNull final Content content, final int index) { ApplicationManager.getApplication().assertIsDispatchThread(); if (myContents.contains(content)) { diff --git a/platform/platform-resources/src/META-INF/LangExtensions.xml b/platform/platform-resources/src/META-INF/LangExtensions.xml index 9645c3c74e10..1d7eaa270885 100644 --- a/platform/platform-resources/src/META-INF/LangExtensions.xml +++ b/platform/platform-resources/src/META-INF/LangExtensions.xml @@ -60,8 +60,6 @@ - diff --git a/platform/projectModel-api/src/com/intellij/openapi/module/ModuleWithNameAlreadyExists.java b/platform/projectModel-api/src/com/intellij/openapi/module/ModuleWithNameAlreadyExists.java index 400c95779d9d..7997cf8cc34e 100644 --- a/platform/projectModel-api/src/com/intellij/openapi/module/ModuleWithNameAlreadyExists.java +++ b/platform/projectModel-api/src/com/intellij/openapi/module/ModuleWithNameAlreadyExists.java @@ -18,15 +18,6 @@ package com.intellij.openapi.module; public class ModuleWithNameAlreadyExists extends Exception { private final String myModuleName; - /** - * @deprecated use constructor which allows passing of localized message - */ - public ModuleWithNameAlreadyExists(String moduleName) { - //noinspection HardCodedStringLiteral - super("Module \'" + moduleName + "\' already exists in the project."); - myModuleName = moduleName; - } - public ModuleWithNameAlreadyExists(final String message, final String moduleName) { super(message); myModuleName = moduleName; diff --git a/platform/projectModel-api/src/com/intellij/openapi/roots/ExcludedOutputFolder.java b/platform/projectModel-api/src/com/intellij/openapi/roots/ExcludedOutputFolder.java deleted file mode 100644 index 9b189251430e..000000000000 --- a/platform/projectModel-api/src/com/intellij/openapi/roots/ExcludedOutputFolder.java +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Copyright 2000-2009 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.openapi.roots; - -/** - * @author dsl - * - * @deprecated {@link ContentEntry#getExcludeFolders()} don't return synthetic entries for excluded outputs any more. - * Use {@link ContentEntry#getExcludeFolderFiles()} to get all excluded roots - */ -public interface ExcludedOutputFolder extends ExcludeFolder { -} diff --git a/platform/testFramework/src/com/intellij/mock/Mock.java b/platform/testFramework/src/com/intellij/mock/Mock.java index 394946c33d7b..14cd9d286b34 100644 --- a/platform/testFramework/src/com/intellij/mock/Mock.java +++ b/platform/testFramework/src/com/intellij/mock/Mock.java @@ -376,13 +376,7 @@ public class Mock { return new FileEditor[0]; } - @Override - public void removeEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) { - } - @Override - public void showEditorAnnotation(@NotNull FileEditor editor, @NotNull JComponent annotationComponent) { - } @Override public void addFileEditorManagerListener(@NotNull FileEditorManagerListener listener) { diff --git a/platform/testFramework/src/com/intellij/mock/MockLocalFileSystem.java b/platform/testFramework/src/com/intellij/mock/MockLocalFileSystem.java index dff92c61534c..145348816bfa 100644 --- a/platform/testFramework/src/com/intellij/mock/MockLocalFileSystem.java +++ b/platform/testFramework/src/com/intellij/mock/MockLocalFileSystem.java @@ -21,7 +21,6 @@ import com.intellij.openapi.vfs.LocalFileOperationsHandler; import com.intellij.openapi.vfs.LocalFileSystem; import com.intellij.openapi.vfs.VirtualFile; import com.intellij.util.ArrayUtil; -import com.intellij.util.Processor; import org.jetbrains.annotations.NonNls; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -84,11 +83,6 @@ public class MockLocalFileSystem extends LocalFileSystem { } - @Override - public boolean processCachedFilesInSubtree(@NotNull final VirtualFile file, @NotNull final Processor processor) { - throw new UnsupportedOperationException("'processCachedFilesInSubtree' not implemented in " + getClass().getName()); - } - @Override @NotNull public String getProtocol() { diff --git a/platform/usageView/src/com/intellij/usages/rules/UsageFilteringRuleEx.java b/platform/usageView/src/com/intellij/usages/rules/UsageFilteringRuleEx.java deleted file mode 100644 index c45059b5516b..000000000000 --- a/platform/usageView/src/com/intellij/usages/rules/UsageFilteringRuleEx.java +++ /dev/null @@ -1,27 +0,0 @@ -/* - * Copyright 2000-2011 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.usages.rules; - -import com.intellij.usages.Usage; -import com.intellij.usages.UsageTarget; -import org.jetbrains.annotations.NotNull; - -/** - * @deprecated implement {@link UsageFilteringRule#isVisible(Usage, UsageTarget[])} instead - */ -public interface UsageFilteringRuleEx extends UsageFilteringRule { - boolean isVisible(@NotNull Usage usage, @NotNull UsageTarget[] targets); -} diff --git a/platform/usageView/src/com/intellij/usages/rules/UsageGroupingRuleEx.java b/platform/usageView/src/com/intellij/usages/rules/UsageGroupingRuleEx.java deleted file mode 100644 index 9dd5818e8d7d..000000000000 --- a/platform/usageView/src/com/intellij/usages/rules/UsageGroupingRuleEx.java +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright 2000-2011 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.usages.rules; - -import com.intellij.usages.Usage; -import com.intellij.usages.UsageGroup; -import com.intellij.usages.UsageTarget; -import com.intellij.util.containers.ContainerUtil; -import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; - -import java.util.List; - -/** - * @deprecated override {@link UsageGroupingRule#getParentGroupsFor(Usage, UsageTarget[])} instead. - */ -public interface UsageGroupingRuleEx extends UsageGroupingRule { - @Nullable - UsageGroup groupUsage(@NotNull Usage usage, @NotNull UsageTarget[] targets); - - @NotNull - @Override - default List getParentGroupsFor(@NotNull Usage usage, @NotNull UsageTarget[] targets) { - return ContainerUtil.createMaybeSingletonList(groupUsage(usage, targets)); - } -} diff --git a/platform/util/src/com/intellij/openapi/util/MultiValuesMap.java b/platform/util/src/com/intellij/openapi/util/MultiValuesMap.java index e077bf846b7e..c88400260b60 100644 --- a/platform/util/src/com/intellij/openapi/util/MultiValuesMap.java +++ b/platform/util/src/com/intellij/openapi/util/MultiValuesMap.java @@ -105,20 +105,6 @@ public class MultiValuesMap{ return myBaseMap.containsKey(key); } - /** - * @deprecated this method will return unordered set for ordered map, use {@link #values()} instead - */ - @Deprecated - @NotNull - public Collection collectValues() { - Collection result = new HashSet(); - for (Collection v : myBaseMap.values()) { - result.addAll(v); - } - - return result; - } - @Nullable public V getFirst(final K key) { Collection values = myBaseMap.get(key); diff --git a/platform/util/src/com/intellij/util/containers/ByteArrayList.java b/platform/util/src/com/intellij/util/containers/ByteArrayList.java index e4b60102575b..9016131acfde 100644 --- a/platform/util/src/com/intellij/util/containers/ByteArrayList.java +++ b/platform/util/src/com/intellij/util/containers/ByteArrayList.java @@ -14,8 +14,4 @@ public class ByteArrayList extends TByteArrayList { public ByteArrayList(int capacity) { super(capacity); } - - public ByteArrayList(byte[] values) { - super(values); - } } diff --git a/platform/util/src/com/intellij/util/io/ZipUtil.java b/platform/util/src/com/intellij/util/io/ZipUtil.java index cc5663db1c33..c9d49eef9a1d 100644 --- a/platform/util/src/com/intellij/util/io/ZipUtil.java +++ b/platform/util/src/com/intellij/util/io/ZipUtil.java @@ -236,18 +236,5 @@ public class ZipUtil { } } - /** @deprecated trivial */ - @Deprecated - @ApiStatus.ScheduledForRemoval(inVersion = "2019") - public static boolean isZipContainsEntry(File zip, String relativePath) throws IOException { - ZipFile zipFile = new ZipFile(zip); - try { - return zipFile.getEntry(relativePath) != null; - } - finally { - zipFile.close(); - } - } - // } \ No newline at end of file diff --git a/platform/util/src/com/intellij/util/text/CharArrayUtil.java b/platform/util/src/com/intellij/util/text/CharArrayUtil.java index e245e806e9cc..db25e6b62007 100644 --- a/platform/util/src/com/intellij/util/text/CharArrayUtil.java +++ b/platform/util/src/com/intellij/util/text/CharArrayUtil.java @@ -101,15 +101,6 @@ public class CharArrayUtil { } } - /** - * @deprecated use {@link #fromSequence(CharSequence)} - */ - @Deprecated - @NotNull - public static char[] fromSequenceStrict(@NotNull CharSequence seq) { - return fromSequence(seq); - } - @Nullable public static char[] fromSequenceWithoutCopying(@Nullable CharSequence seq) { if (seq instanceof CharSequenceBackedByArray) { diff --git a/platform/util/src/com/intellij/util/text/SemVer.java b/platform/util/src/com/intellij/util/text/SemVer.java index a500473f6841..28188fd7cc1f 100644 --- a/platform/util/src/com/intellij/util/text/SemVer.java +++ b/platform/util/src/com/intellij/util/text/SemVer.java @@ -121,15 +121,4 @@ public final class SemVer implements Comparable { return null; } - - // - /** @deprecated use {@code ObjectUtils.notNull(SemVer.parseFromText(...), SemVer.UNKNOWN)} (to be removed in IDEA 2019) */ - @Deprecated - @SuppressWarnings("SpellCheckingInspection") - public static SemVer parseFromTextNonNullize(@Nullable final String text) { - if (text == null) return UNKNOWN; - final SemVer ver = parseFromText(text); - return ver == null ? UNKNOWN : ver; - } - // } diff --git a/platform/util/src/com/intellij/util/text/StringSearcher.java b/platform/util/src/com/intellij/util/text/StringSearcher.java index 938991947983..9c90be3aebbc 100644 --- a/platform/util/src/com/intellij/util/text/StringSearcher.java +++ b/platform/util/src/com/intellij/util/text/StringSearcher.java @@ -214,15 +214,6 @@ public class StringSearcher { return sameChar; } - /** - * @deprecated Use {@link #scan(CharSequence)} instead - */ - @Deprecated - public int scan(char[] text, int startOffset, int endOffset){ - final int res = scan(new CharArrayCharSequence(text),text, startOffset, endOffset); - return res >= 0 ? res: -1; - } - @Override public String toString() { return "pattern " + myPattern; diff --git a/platform/util/src/com/intellij/util/ui/JBUI.java b/platform/util/src/com/intellij/util/ui/JBUI.java index 4319476224d4..7ae9e6192e9c 100644 --- a/platform/util/src/com/intellij/util/ui/JBUI.java +++ b/platform/util/src/com/intellij/util/ui/JBUI.java @@ -555,15 +555,6 @@ public class JBUI { return insets(0, 0, 0, r); } - /** - * @deprecated use JBUI.scale(EmptyIcon.create(size)) instead - */ - @Deprecated - @NotNull - public static EmptyIcon emptyIcon(int size) { - return scale(EmptyIcon.create(size)); - } - @NotNull @SuppressWarnings("unchecked") public static T scale(@NotNull T icon) { diff --git a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/CommitOptionsPanel.kt b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/CommitOptionsPanel.kt index c7b49a2dbb6d..6f3d750b19d1 100644 --- a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/CommitOptionsPanel.kt +++ b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ui/CommitOptionsPanel.kt @@ -14,7 +14,6 @@ import com.intellij.openapi.vcs.checkin.CheckinChangeListSpecificComponent import com.intellij.openapi.vcs.checkin.CheckinHandler import com.intellij.openapi.vcs.ui.RefreshableOnComponent import com.intellij.openapi.vfs.VirtualFile -import com.intellij.ui.IdeBorderFactory.createTitledBorder import com.intellij.ui.ScrollPaneFactory.createScrollPane import com.intellij.util.ui.JBUI import com.intellij.util.ui.JBUI.Panels.simplePanel @@ -126,7 +125,7 @@ class CommitOptionsPanel(private val myCommitPanel: CheckinProjectPanel, companion object { fun verticalPanel(title: String) = JPanel(VerticalFlowLayout(0, 5)).apply { - border = createTitledBorder(title) + border = com.intellij.ui.IdeBorderFactory.createTitledBorder(title) } } } diff --git a/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyAnnotationAttributeInfoHandler.java b/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyAnnotationAttributeInfoHandler.java index 36fa061f5701..a2be263d3a94 100644 --- a/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyAnnotationAttributeInfoHandler.java +++ b/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyAnnotationAttributeInfoHandler.java @@ -104,12 +104,6 @@ public class GroovyAnnotationAttributeInfoHandler implements ParameterInfoHandle return PsiAnnotationMethod.EMPTY_ARRAY; } - @Nullable - @Override - public Object[] getParametersForDocumentation(PsiAnnotationMethod method, ParameterInfoContext context) { - return new PsiAnnotationMethod[]{method}; - } - @Override public GrAnnotationArgumentList findElementForParameterInfo(@NotNull CreateParameterInfoContext context) { return findAnchor(context.getEditor(), context.getFile()); @@ -168,16 +162,6 @@ public class GroovyAnnotationAttributeInfoHandler implements ParameterInfoHandle return offset1; } - @Override - public String getParameterCloseChars() { - return ParameterInfoUtils.DEFAULT_PARAMETER_CLOSE_CHARS; - } - - @Override - public boolean tracksParameterIndex() { - return true; - } - @Override public void updateUI(@NotNull PsiAnnotationMethod p, @NotNull ParameterInfoUIContext context) { @NonNls StringBuilder buffer = new StringBuilder(); diff --git a/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyParameterInfoHandler.java b/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyParameterInfoHandler.java index fd855cafc33c..4081bfe214a9 100644 --- a/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyParameterInfoHandler.java +++ b/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyParameterInfoHandler.java @@ -78,18 +78,6 @@ public class GroovyParameterInfoHandler implements ParameterInfoHandlerWithTabAc return null; } - @Override - public Object[] getParametersForDocumentation(Object resolveResult, ParameterInfoContext context) { - if (resolveResult instanceof GroovyResolveResult) { - final PsiElement element = ((GroovyResolveResult)resolveResult).getElement(); - if (element instanceof PsiMethod) { - return ((PsiMethod)element).getParameterList().getParameters(); - } - } - - return ArrayUtil.EMPTY_OBJECT_ARRAY; - } - @Override public GroovyPsiElement findElementForParameterInfo(@NotNull CreateParameterInfoContext context) { return findAnchorElement(context.getEditor().getCaretModel().getOffset(), context.getFile()); @@ -302,16 +290,6 @@ public class GroovyParameterInfoHandler implements ParameterInfoHandlerWithTabAc return element != null && element.getNode().getElementType() == GroovyTokenTypes.mCOMMA; } - @Override - public String getParameterCloseChars() { - return ",){}"; - } - - @Override - public boolean tracksParameterIndex() { - return true; - } - @Override public void updateUI(Object o, @NotNull ParameterInfoUIContext context) { CodeInsightSettings settings = CodeInsightSettings.getInstance(); diff --git a/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyTypeParameterInfoHandler.java b/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyTypeParameterInfoHandler.java index 665131f63ba9..7e917031c948 100644 --- a/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyTypeParameterInfoHandler.java +++ b/plugins/groovy/src/org/jetbrains/plugins/groovy/lang/parameterInfo/GroovyTypeParameterInfoHandler.java @@ -75,12 +75,6 @@ public class GroovyTypeParameterInfoHandler implements ParameterInfoHandlerWithT return null; } - @Nullable - @Override - public Object[] getParametersForDocumentation(PsiTypeParameter p, ParameterInfoContext context) { - return new Object[]{p}; - } - @Nullable @Override public GrTypeArgumentList findElementForParameterInfo(@NotNull CreateParameterInfoContext context) { @@ -122,12 +116,6 @@ public class GroovyTypeParameterInfoHandler implements ParameterInfoHandlerWithT context.setHighlightedParameter(index < objectsToView.length && index >= 0 ? (PsiElement)objectsToView[index] : null); } - @Nullable - @Override - public String getParameterCloseChars() { - return ",>"; - } - @Override public void updateUI(PsiTypeParameter p, @NotNull ParameterInfoUIContext context) { @NonNls StringBuilder buffer = new StringBuilder(); diff --git a/plugins/groovy/src/org/jetbrains/plugins/groovy/mvc/projectView/MvcProjectViewPane.java b/plugins/groovy/src/org/jetbrains/plugins/groovy/mvc/projectView/MvcProjectViewPane.java index 2c2fa489de0a..fa8eba4a6a8e 100644 --- a/plugins/groovy/src/org/jetbrains/plugins/groovy/mvc/projectView/MvcProjectViewPane.java +++ b/plugins/groovy/src/org/jetbrains/plugins/groovy/mvc/projectView/MvcProjectViewPane.java @@ -238,43 +238,43 @@ public class MvcProjectViewPane extends AbstractProjectViewPSIPane implements Id @Override public Object getData(String dataId) { - if (DataConstants.PSI_ELEMENT.equals(dataId)) { + if (CommonDataKeys.PSI_ELEMENT.getName().equals(dataId)) { final PsiElement[] elements = getSelectedPSIElements(); return elements.length == 1 ? elements[0] : null; } - if (DataConstants.PSI_ELEMENT_ARRAY.equals(dataId)) { + if (LangDataKeys.PSI_ELEMENT_ARRAY.getName().equals(dataId)) { return getSelectedPSIElements(); } - if (DataConstants.MODULE_CONTEXT.equals(dataId)) { + if (LangDataKeys.MODULE_CONTEXT.getName().equals(dataId)) { final Object element = getSelectedElement(); if (element instanceof Module) { return element; } return null; } - if (DataConstants.MODULE_CONTEXT_ARRAY.equals(dataId)) { + if (LangDataKeys.MODULE_CONTEXT_ARRAY.getName().equals(dataId)) { final List moduleList = ContainerUtil.findAll(getSelectedElements(), Module.class); if (!moduleList.isEmpty()) { return moduleList.toArray(Module.EMPTY_ARRAY); } return null; } - if (dataId.equals(DataConstants.IDE_VIEW)) { + if (dataId.equals(LangDataKeys.IDE_VIEW.getName())) { return this; } - if (dataId.equals(DataConstants.HELP_ID)) { + if (dataId.equals(PlatformDataKeys.HELP_ID.getName())) { return "reference.toolwindows." + myId.toLowerCase(); } - if (DataConstants.CUT_PROVIDER.equals(dataId)) { + if (PlatformDataKeys.CUT_PROVIDER.getName().equals(dataId)) { return myCopyPasteDelegator.getCutProvider(); } - if (DataConstants.COPY_PROVIDER.equals(dataId)) { + if (PlatformDataKeys.COPY_PROVIDER.getName().equals(dataId)) { return myCopyPasteDelegator.getCopyProvider(); } - if (DataConstants.PASTE_PROVIDER.equals(dataId)) { + if (PlatformDataKeys.PASTE_PROVIDER.getName().equals(dataId)) { return myCopyPasteDelegator.getPasteProvider(); } - if (DataConstants.DELETE_ELEMENT_PROVIDER.equals(dataId)) { + if (PlatformDataKeys.DELETE_ELEMENT_PROVIDER.getName().equals(dataId)) { for (final Object element : getSelectedElements()) { if (element instanceof Module) { return myDeleteModuleProvider; diff --git a/plugins/xpath/xpath-lang/src/org/intellij/lang/xpath/XPathParameterInfoHandler.java b/plugins/xpath/xpath-lang/src/org/intellij/lang/xpath/XPathParameterInfoHandler.java index 59df3329a9f4..696b9137bc69 100644 --- a/plugins/xpath/xpath-lang/src/org/intellij/lang/xpath/XPathParameterInfoHandler.java +++ b/plugins/xpath/xpath-lang/src/org/intellij/lang/xpath/XPathParameterInfoHandler.java @@ -39,10 +39,6 @@ public class XPathParameterInfoHandler implements ParameterInfoHandler