Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.mvn/extensions.xml11
-rw-r--r--Jenkinsfile70
-rw-r--r--org.eclipse.core.externaltools/.classpath2
-rw-r--r--org.eclipse.core.externaltools/.settings/org.eclipse.jdt.core.prefs37
-rw-r--r--org.eclipse.core.externaltools/.settings/org.eclipse.jdt.ui.prefs52
-rw-r--r--org.eclipse.core.externaltools/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.java2
-rw-r--r--org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.properties1
-rw-r--r--org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ProgramLaunchDelegate.java14
-rw-r--r--org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/BuilderCoreUtils.java41
-rw-r--r--org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/ExternalToolBuilder.java2
-rw-r--r--org.eclipse.core.variables/.classpath2
-rw-r--r--org.eclipse.core.variables/.settings/org.eclipse.jdt.core.prefs37
-rw-r--r--org.eclipse.core.variables/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.core.variables/src/org/eclipse/core/internal/variables/StringSubstitutionEngine.java58
-rw-r--r--org.eclipse.debug.core/.settings/.api_filters40
-rw-r--r--org.eclipse.debug.core/META-INF/MANIFEST.MF2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/core/commands/AbstractDebugCommand.java2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/core/model/IProcess.java9
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/core/model/RuntimeProcess.java85
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/BreakpointManager.java2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.java2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.properties2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/InputStreamMonitor.java29
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchConfiguration.java104
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchManager.java4
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/NullStreamsProxy.java2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/OutputStreamMonitor.java50
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/PreferredDelegateModifyListener.java2
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/RefreshScopeComparator.java30
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamDecoder.java50
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamsProxy.java11
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/XMLMemento.java47
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/sourcelookup/SourceLocatorMementoComparator.java14
-rw-r--r--org.eclipse.debug.core/plugin.properties2
-rw-r--r--org.eclipse.debug.core/plugin.xml10
-rw-r--r--org.eclipse.debug.examples.core/.classpath2
-rw-r--r--org.eclipse.debug.examples.core/.settings/org.eclipse.jdt.core.prefs38
-rw-r--r--org.eclipse.debug.examples.core/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.debug.examples.memory/.classpath2
-rw-r--r--org.eclipse.debug.examples.memory/.settings/org.eclipse.jdt.core.prefs37
-rw-r--r--org.eclipse.debug.examples.memory/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.debug.examples.memory/pom.xml4
-rwxr-xr-xorg.eclipse.debug.examples.mixedmode/.classpath2
-rw-r--r--org.eclipse.debug.examples.mixedmode/.settings/org.eclipse.jdt.core.prefs37
-rwxr-xr-xorg.eclipse.debug.examples.mixedmode/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.debug.examples.mixedmode/pom.xml4
-rw-r--r--org.eclipse.debug.examples.ui/.classpath2
-rw-r--r--org.eclipse.debug.examples.ui/.settings/org.eclipse.jdt.core.prefs37
-rw-r--r--org.eclipse.debug.examples.ui/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/adapters/PDAVirtualFindAction.java2
-rw-r--r--org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/breakpoints/PDAToggleWatchpointsTarget.java8
-rw-r--r--org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/editor/PDAScanner.java2
-rw-r--r--org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/launcher/PDAMainTab.java6
-rw-r--r--org.eclipse.debug.tests/META-INF/MANIFEST.MF3
-rwxr-xr-xorg.eclipse.debug.tests/plugin.properties1
-rw-r--r--org.eclipse.debug.tests/plugin.xml21
-rw-r--r--org.eclipse.debug.tests/pom.xml4
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/AutomatedSuite.java8
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/breakpoint/SerialExecutorTest.java163
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/IOConsoleTests.java33
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/InputStreamMonitorTests.java8
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/MockProcess.java78
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/OutputStreamMonitorTests.java3
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/RuntimeProcessTests.java36
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/StreamsProxyTests.java2
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/expressions/ExpressionManagerTests.java6
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/DebugFileStore.java10
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchConfigurationTests.java4
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchManagerTests.java114
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/RefreshTabTests.java21
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/ThrowingLaunchDelegate.java72
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/sourcelookup/SourceLookupFacilityTests.java7
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor1.java32
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor2.java32
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor3.java32
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/VariableValueEditorManagerTests.java36
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTests.java146
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTestsMemoryBlock.java173
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ColumnPresentationTests.java2
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ContentTests.java2
-rw-r--r--org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/FilterTests.java4
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.classpath11
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.project28
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.core.prefs421
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.ui.prefs115
-rw-r--r--org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.pde.prefs39
-rw-r--r--org.eclipse.debug.ui.launchview.tests/META-INF/MANIFEST.MF20
-rw-r--r--org.eclipse.debug.ui.launchview.tests/Platform Debug UI LaunchView Test Suite.launch41
-rw-r--r--org.eclipse.debug.ui.launchview.tests/about.html36
-rw-r--r--org.eclipse.debug.ui.launchview.tests/build.properties22
-rw-r--r--org.eclipse.debug.ui.launchview.tests/forceQualifierUpdate.txt1
-rwxr-xr-xorg.eclipse.debug.ui.launchview.tests/plugin.properties17
-rw-r--r--org.eclipse.debug.ui.launchview.tests/plugin.xml19
-rw-r--r--org.eclipse.debug.ui.launchview.tests/pom.xml50
-rw-r--r--org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AbstractLaunchViewTest.java169
-rw-r--r--org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AutomatedSuite.java33
-rw-r--r--org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestUtil.java303
-rw-r--r--org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestsPlugin.java110
-rw-r--r--org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/launchview/LaunchViewSmokeTest.java38
-rw-r--r--org.eclipse.debug.ui.launchview.tests/test.xml64
-rw-r--r--org.eclipse.debug.ui.launchview/.classpath7
-rw-r--r--org.eclipse.debug.ui.launchview/.project33
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.resources.prefs4
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.core.prefs439
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.ui.prefs114
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.api.tools.prefs97
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.ds.annotations.prefs6
-rw-r--r--org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.prefs36
-rw-r--r--org.eclipse.debug.ui.launchview/META-INF/MANIFEST.MF25
-rw-r--r--org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider.xml7
-rw-r--r--org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.xml9
-rw-r--r--org.eclipse.debug.ui.launchview/about.html36
-rw-r--r--org.eclipse.debug.ui.launchview/build.properties10
-rw-r--r--org.eclipse.debug.ui.launchview/icons/coverage.pngbin0 -> 599 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/debug_exc.pngbin0 -> 563 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/debug_exc@2x.pngbin0 -> 1453 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/delete_exc.pngbin0 -> 582 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/delete_exc@2x.pngbin0 -> 1296 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/edit_template.pngbin0 -> 402 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/edit_template@2x.pngbin0 -> 1187 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/favorite_star.pngbin0 -> 1249 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/profile_exc.pngbin0 -> 655 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/profile_exc@2x.pngbin0 -> 1462 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/refresh.pngbin0 -> 591 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/refresh@2x.pngbin0 -> 1330 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/run_co.pngbin0 -> 265 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/run_co@2x.pngbin0 -> 561 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/run_exc.pngbin0 -> 620 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/run_exc@2x.pngbin0 -> 1226 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/term_restart.pngbin0 -> 410 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/term_restart@2x.pngbin0 -> 948 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/terminate_all_co.pngbin0 -> 487 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/terminate_all_co@2x.pngbin0 -> 1137 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/terminate_co.pngbin0 -> 330 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/icons/terminate_co@2x.pngbin0 -> 517 bytes
-rw-r--r--org.eclipse.debug.ui.launchview/plugin.properties19
-rw-r--r--org.eclipse.debug.ui.launchview/plugin.xml14
-rw-r--r--org.eclipse.debug.ui.launchview/pom.xml28
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/IBackgroundLaunchExecutor.java46
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/LaunchConfigurationViewPlugin.java34
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/AbstractLaunchObjectProvider.java44
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/FileLogger.java60
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewBundleInfo.java21
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewMessages.java52
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/SpecificLaunchListener.java98
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/StreamHelper.java40
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreLaunchObject.java188
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreProvider.java156
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/launcher/StandaloneLaunchConfigExecutor.java220
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/messages.properties37
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/ILaunchModel.java27
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectContainerModel.java69
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectFavoriteContainerModel.java30
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectModel.java101
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchViewModel.java134
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/EditAction.java50
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchAction.java96
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewContentProvider.java45
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewImpl.java327
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewLabelProvider.java72
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/RelaunchAction.java57
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/TerminateAction.java57
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObject.java94
-rw-r--r--org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObjectProvider.java77
-rw-r--r--org.eclipse.debug.ui/.classpath2
-rw-r--r--org.eclipse.debug.ui/.settings/org.eclipse.jdt.core.prefs37
-rw-r--r--org.eclipse.debug.ui/META-INF/MANIFEST.MF8
-rw-r--r--org.eclipse.debug.ui/icons/full/obj16/launchConfiguration.pngbin0 -> 571 bytes
-rw-r--r--org.eclipse.debug.ui/icons/full/obj16/launchConfiguration@2x.pngbin0 -> 1192 bytes
-rw-r--r--org.eclipse.debug.ui/plugin.properties3
-rw-r--r--org.eclipse.debug.ui/plugin.xml25
-rw-r--r--org.eclipse.debug.ui/pom.xml6
-rw-r--r--org.eclipse.debug.ui/schema/variableValueEditors.exsd41
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/InstructionPointerManager.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/MultipleInputDialog.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/VariableValueEditorManager.java41
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/ConfigureColumnsAction.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMining.java61
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMiningProvider.java109
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/TerminateAllHandler.java (renamed from org.eclipse.ui.console/src/org/eclipse/ui/internal/console/StreamDecoder.java)21
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/contextlaunching/LaunchingResourceManager.java1
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/groups/CommonTabLite.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationManager.java5
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java5
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupWrapper.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationsMessages.properties6
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchShortcutExtension.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/SelectLaunchModesDialog.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/memory/provisional/AbstractAsyncTableRendering.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerContentProvider.java74
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/SerialExecutor.java75
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencePage.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.properties8
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchPerspectivePreferencePage.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchersPreferencePage.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/ProcessPropertyPage.java12
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/StringVariablePreferencePage.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupFacility.java524
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupResult.java103
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousModel.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousSchedulingRuleFactory.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousViewer.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/InternalTreeModelViewer.java5
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/TreeModelContentProvider.java17
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualCopyToClipboardActionDelegate.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualFindAction.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointOrganizerManager.java3
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointsView.java9
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java11
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java8
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/AddMemoryRenderingDialog.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryView.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryViewSynchronizationService.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CreateRendering.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/HexIntegerRendering.java13
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/RenderingsUtil.java195
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/SignedIntegerRendering.java23
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/UnsignedIntegerRendering.java25
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java10
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/details/DetailPaneManager.java2
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugUIConstants.java8
-rw-r--r--org.eclipse.ui.console/.classpath2
-rw-r--r--org.eclipse.ui.console/.settings/org.eclipse.jdt.core.prefs38
-rw-r--r--org.eclipse.ui.console/.settings/org.eclipse.jdt.ui.prefs52
-rw-r--r--org.eclipse.ui.console/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleInputStream.java14
-rw-r--r--org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleOutputStream.java37
-rw-r--r--org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleDocument.java6
-rw-r--r--org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsolePatternMatcher.java12
-rw-r--r--org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java188
-rw-r--r--org.eclipse.ui.externaltools/.classpath2
-rw-r--r--org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.core.prefs37
-rw-r--r--org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.ui.prefs52
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsBuildTab.java22
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsMainTab.java2
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/BuilderUtils.java33
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPlugin.java2
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPreferenceInitializer.java31
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/IPreferenceConstants.java36
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java83
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsPreferencePage.java105
-rw-r--r--org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsUIMessages.properties4
-rw-r--r--org.eclipse.ui.externaltools/META-INF/MANIFEST.MF4
-rw-r--r--org.eclipse.ui.externaltools/plugin.xml13
-rw-r--r--org.eclipse.unittest.ui/pom.xml2
-rw-r--r--org.eclipse.unittest.ui/src/org/eclipse/unittest/internal/UnitTestPreferencesConstants.java9
-rw-r--r--pom.xml6
252 files changed, 7568 insertions, 1529 deletions
diff --git a/.mvn/extensions.xml b/.mvn/extensions.xml
index cc23d13be..aa1268d82 100644
--- a/.mvn/extensions.xml
+++ b/.mvn/extensions.xml
@@ -1,8 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<extensions>
- <extension>
- <groupId>org.eclipse.tycho.extras</groupId>
- <artifactId>tycho-pomless</artifactId>
- <version>2.3.0</version>
- </extension>
+ <extension>
+ <groupId>org.eclipse.tycho</groupId>
+ <artifactId>tycho-build</artifactId>
+ <version>2.7.0</version>
+ </extension>
</extensions> \ No newline at end of file
diff --git a/Jenkinsfile b/Jenkinsfile
new file mode 100644
index 000000000..2552c33df
--- /dev/null
+++ b/Jenkinsfile
@@ -0,0 +1,70 @@
+pipeline {
+ options {
+ timeout(time: 40, unit: 'MINUTES')
+ buildDiscarder(logRotator(numToKeepStr:'5'))
+ }
+ agent {
+ label "centos-latest"
+ }
+ tools {
+ maven 'apache-maven-latest'
+ jdk 'openjdk-jdk11-latest'
+ }
+ stages {
+ stage('initialize Gerrit review') {
+ steps {
+ gerritReview labels: [Verified: 0], message: "Build started $BUILD_URL"
+ }
+ }
+ stage('Build') {
+ steps {
+ wrap([$class: 'Xvnc', useXauthority: true]) {
+ sh """
+ mvn clean verify --batch-mode --fail-at-end -Dmaven.repo.local=$WORKSPACE/.m2/repository \
+ -Pbuild-individual-bundles -Pbree-libs -Papi-check \
+ -DskipTests=false -Dcompare-version-with-baselines.skip=false \
+ -Dmaven.test.error.ignore=true -Dmaven.test.failure.ignore=true \
+ -Dmaven.compiler.failOnWarning=true -Dproject.build.sourceEncoding=UTF-8
+ """
+ }
+ }
+ post {
+ always {
+ archiveArtifacts artifacts: '.*log,*/target/work/data/.metadata/.*log,*/tests/target/work/data/.metadata/.*log,apiAnalyzer-workspace/data/.metadata/.*log'
+ junit '**/target/surefire-reports/TEST-*.xml'
+ publishIssues issues:[scanForIssues(tool: java()), scanForIssues(tool: mavenConsole())]
+ }
+ unstable {
+ gerritReview labels: [Verified: -1], message: "Build UNSTABLE (test failures) $BUILD_URL"
+ }
+ failure {
+ gerritReview labels: [Verified: -1], message: "Build FAILED $BUILD_URL"
+ }
+ }
+ }
+ stage('Check freeze period') {
+ when {
+ not {
+ branch 'master'
+ }
+ }
+ steps {
+ sh "wget https://download.eclipse.org/eclipse/relengScripts/scripts/verifyFreezePeriod.sh"
+ sh "chmod +x verifyFreezePeriod.sh"
+ withCredentials([string(credentialsId: 'google-api-key', variable: 'GOOGLE_API_KEY')]) {
+ sh './verifyFreezePeriod.sh'
+ }
+ }
+ post {
+ failure {
+ gerritReview labels: [Verified: -1], message: "Build and test are OK, but Eclipse project is currently in a code freeze period.\nPlease wait for end of code freeze period before merging.\n $BUILD_URL"
+ }
+ }
+ }
+ }
+ post {
+ success {
+ gerritReview labels: [Verified: 1], message: "Build Succcess $BUILD_URL"
+ }
+ }
+}
diff --git a/org.eclipse.core.externaltools/.classpath b/org.eclipse.core.externaltools/.classpath
index eca7bdba8..e801ebfb4 100644
--- a/org.eclipse.core.externaltools/.classpath
+++ b/org.eclipse.core.externaltools/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.core.prefs
index 59d5c902a..c14a2b56b 100644
--- a/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,11 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -145,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -239,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -273,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -297,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -350,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -386,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -414,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.ui.prefs
index 8e18452e3..ddcf96428 100644
--- a/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.ui.prefs
+++ b/org.eclipse.core.externaltools/.settings/org.eclipse.jdt.ui.prefs
@@ -1,55 +1,3 @@
-cleanup.add_default_serial_version_id=true
-cleanup.add_generated_serial_version_id=false
-cleanup.add_missing_annotations=true
-cleanup.add_missing_deprecated_annotations=true
-cleanup.add_missing_methods=false
-cleanup.add_missing_nls_tags=false
-cleanup.add_missing_override_annotations=true
-cleanup.add_missing_override_annotations_interface_methods=true
-cleanup.add_serial_version_id=false
-cleanup.always_use_blocks=true
-cleanup.always_use_parentheses_in_expressions=false
-cleanup.always_use_this_for_non_static_field_access=false
-cleanup.always_use_this_for_non_static_method_access=false
-cleanup.convert_to_enhanced_for_loop=false
-cleanup.correct_indentation=false
-cleanup.format_source_code=true
-cleanup.format_source_code_changes_only=false
-cleanup.make_local_variable_final=true
-cleanup.make_parameters_final=false
-cleanup.make_private_fields_final=true
-cleanup.make_type_abstract_if_missing_method=false
-cleanup.make_variable_declarations_final=false
-cleanup.never_use_blocks=false
-cleanup.never_use_parentheses_in_expressions=true
-cleanup.organize_imports=true
-cleanup.qualify_static_field_accesses_with_declaring_class=false
-cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-cleanup.qualify_static_member_accesses_with_declaring_class=true
-cleanup.qualify_static_method_accesses_with_declaring_class=false
-cleanup.remove_private_constructors=true
-cleanup.remove_trailing_whitespaces=true
-cleanup.remove_trailing_whitespaces_all=true
-cleanup.remove_trailing_whitespaces_ignore_empty=false
-cleanup.remove_unnecessary_casts=true
-cleanup.remove_unnecessary_nls_tags=true
-cleanup.remove_unused_imports=true
-cleanup.remove_unused_local_variables=false
-cleanup.remove_unused_private_fields=true
-cleanup.remove_unused_private_members=false
-cleanup.remove_unused_private_methods=true
-cleanup.remove_unused_private_types=true
-cleanup.sort_members=false
-cleanup.sort_members_all=false
-cleanup.use_blocks=true
-cleanup.use_blocks_only_for_return_and_throw=false
-cleanup.use_parentheses_in_expressions=false
-cleanup.use_this_for_non_static_field_access=false
-cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-cleanup.use_this_for_non_static_method_access=false
-cleanup.use_this_for_non_static_method_access_only_if_necessary=true
-cleanup_profile=_Platform Debug Cleanups
cleanup_settings_version=2
eclipse.preferences.version=1
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
diff --git a/org.eclipse.core.externaltools/META-INF/MANIFEST.MF b/org.eclipse.core.externaltools/META-INF/MANIFEST.MF
index 4f2444686..4c9f27f0a 100644
--- a/org.eclipse.core.externaltools/META-INF/MANIFEST.MF
+++ b/org.eclipse.core.externaltools/META-INF/MANIFEST.MF
@@ -3,13 +3,13 @@ Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-Localization: plugin
Bundle-SymbolicName: org.eclipse.core.externaltools;singleton:=true
-Bundle-Version: 1.1.800.qualifier
+Bundle-Version: 1.2.200.qualifier
Bundle-Activator: org.eclipse.core.externaltools.internal.ExternalToolsCore
Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.5.0,4.0.0)",
org.eclipse.debug.core;bundle-version="[3.9.0,4.0.0)",
org.eclipse.core.variables;bundle-version="[3.2.800,4.0.0)",
org.eclipse.core.resources;bundle-version="[3.5.0,4.0.0)"
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Bundle-ActivationPolicy: lazy
Bundle-Vendor: %providerName
Export-Package: org.eclipse.core.externaltools.internal;x-friends:="org.eclipse.ant.launching,org.eclipse.ui.externaltools,org.eclipse.ant.ui",
diff --git a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.java b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.java
index d75dda2ea..b733eb9ed 100644
--- a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.java
+++ b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.java
@@ -18,10 +18,12 @@ import org.eclipse.osgi.util.NLS;
public class ExternalToolsProgramMessages extends NLS {
private static final String BUNDLE_NAME = "org.eclipse.core.externaltools.internal.launchConfigurations.ExternalToolsProgramMessages";//$NON-NLS-1$
+
public static String BackgroundResourceRefresher_0;
public static String ProgramLaunchDelegate_3;
public static String ProgramLaunchDelegate_4;
+ public static String ProgramLaunchDelegate_5;
public static String ExternalToolsUtil_Location_not_specified_by__0__1;
public static String ExternalToolsUtil_invalidLocation__0_;
diff --git a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.properties b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.properties
index 78a74737d..7d9189938 100644
--- a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.properties
+++ b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ExternalToolsProgramMessages.properties
@@ -16,6 +16,7 @@ BackgroundResourceRefresher_0=Refreshing resources...
ProgramLaunchDelegate_3=Running {0}...
ProgramLaunchDelegate_4=An IProcess could not be created for the launch
+ProgramLaunchDelegate_5=[pid: {0}]
ExternalToolsUtil_Location_not_specified_by__0__1=Location not specified by {0}
ExternalToolsUtil_invalidLocation__0_ = The file does not exist for the external tool named {0}.
diff --git a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ProgramLaunchDelegate.java b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ProgramLaunchDelegate.java
index 4d599c584..f6efdb87c 100644
--- a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ProgramLaunchDelegate.java
+++ b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/launchConfigurations/ProgramLaunchDelegate.java
@@ -119,7 +119,8 @@ public class ProgramLaunchDelegate extends LaunchConfigurationDelegate {
ExternalToolsProgramMessages.ProgramLaunchDelegate_3,
new String[] { configuration.getName() }),
IProgressMonitor.UNKNOWN);
- process = DebugPlugin.newProcess(launch, p, location.toOSString(), processAttributes);
+ String label = getProcessLabel(location, p);
+ process = DebugPlugin.newProcess(launch, p, label, processAttributes);
}
if (p == null || process == null) {
if (p != null) {
@@ -158,6 +159,17 @@ public class ProgramLaunchDelegate extends LaunchConfigurationDelegate {
}
}
+ private String getProcessLabel(IPath location, Process p) {
+ String label = location.toOSString();
+ try {
+ label += " " + NLS.bind(ExternalToolsProgramMessages.ProgramLaunchDelegate_5, new Object[] { //$NON-NLS-1$
+ p.pid() });
+ } catch (UnsupportedOperationException e) {
+ // ignore, pid() is not implemented in this JVM
+ }
+ return label;
+ }
+
private String[] buildCommandLine(ILaunchConfiguration configuration, IPath location) throws CoreException {
// resolve arguments
String[] arguments = ExternalToolsCoreUtil.getArguments(configuration);
diff --git a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/BuilderCoreUtils.java b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/BuilderCoreUtils.java
index aed44a3a8..c87bac400 100644
--- a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/BuilderCoreUtils.java
+++ b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/BuilderCoreUtils.java
@@ -23,12 +23,9 @@ import org.eclipse.core.resources.ICommand;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.IncrementalProjectBuilder;
-import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.Path;
import org.eclipse.debug.core.DebugPlugin;
@@ -246,44 +243,6 @@ public class BuilderCoreUtils {
return folder;
}
- /**
- * Migrates the launch configuration working copy, which is based on an old-
- * style external tool builder, to a new, saved launch configuration. The
- * returned launch configuration will contain the same attributes as the
- * given working copy with the exception of the configuration name, which
- * may be changed during the migration. The name of the configuration will
- * only be changed if the current name is not a valid name for a saved
- * config.
- *
- * @param workingCopy
- * the launch configuration containing attributes from an
- * old-style project builder.
- * @return ILaunchConfiguration a new, saved launch configuration whose
- * attributes match those of the given working copy as well as
- * possible
- * @throws CoreException
- * if an exception occurs while attempting to save the new
- * launch configuration
- */
- public static ILaunchConfiguration migrateBuilderConfiguration(
- IProject project, ILaunchConfigurationWorkingCopy workingCopy)
- throws CoreException {
- workingCopy.setContainer(getBuilderFolder(project, true));
- // Before saving, make sure the name is valid
- String name = workingCopy.getName();
- name = name.replace('/', '.');
- if (name.charAt(0) == ('.')) {
- name = name.substring(1);
- }
- IStatus status = ResourcesPlugin.getWorkspace().validateName(name,
- IResource.FILE);
- if (!status.isOK()) {
- name = "ExternalTool"; //$NON-NLS-1$
- }
- name = DebugPlugin.getDefault().getLaunchManager().generateLaunchConfigurationName(name);
- workingCopy.rename(name);
- return workingCopy.doSave();
- }
/**
* Converts the build types string into an array of build kinds.
diff --git a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/ExternalToolBuilder.java b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/ExternalToolBuilder.java
index 16ac512a8..ee9b49517 100644
--- a/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/ExternalToolBuilder.java
+++ b/org.eclipse.core.externaltools/src/org/eclipse/core/externaltools/internal/model/ExternalToolBuilder.java
@@ -43,7 +43,7 @@ import org.osgi.framework.Bundle;
* build process.
*/
public final class ExternalToolBuilder extends IncrementalProjectBuilder {
- private final class IgnoreTeamPrivateChanges implements IResourceDeltaVisitor {
+ private static final class IgnoreTeamPrivateChanges implements IResourceDeltaVisitor {
private boolean[] fTrueChange;
private IgnoreTeamPrivateChanges(boolean[] trueChange) {
super();
diff --git a/org.eclipse.core.variables/.classpath b/org.eclipse.core.variables/.classpath
index eca7bdba8..e801ebfb4 100644
--- a/org.eclipse.core.variables/.classpath
+++ b/org.eclipse.core.variables/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.core.variables/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.core.variables/.settings/org.eclipse.jdt.core.prefs
index 59d5c902a..c14a2b56b 100644
--- a/org.eclipse.core.variables/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.core.variables/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,11 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -145,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -239,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -273,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -297,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -350,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -386,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -414,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.core.variables/META-INF/MANIFEST.MF b/org.eclipse.core.variables/META-INF/MANIFEST.MF
index 8bc67d1d5..0e99308db 100644
--- a/org.eclipse.core.variables/META-INF/MANIFEST.MF
+++ b/org.eclipse.core.variables/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.core.variables; singleton:=true
-Bundle-Version: 3.4.900.qualifier
+Bundle-Version: 3.5.100.qualifier
Bundle-Activator: org.eclipse.core.variables.VariablesPlugin
Bundle-Vendor: %providerName
Bundle-Localization: plugin
@@ -10,5 +10,5 @@ Export-Package: org.eclipse.core.internal.variables;x-internal:=true,
org.eclipse.core.variables
Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.3.0,4.0.0)"
Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Automatic-Module-Name: org.eclipse.core.variables
diff --git a/org.eclipse.core.variables/src/org/eclipse/core/internal/variables/StringSubstitutionEngine.java b/org.eclipse.core.variables/src/org/eclipse/core/internal/variables/StringSubstitutionEngine.java
index 55ac7c851..cd413883b 100644
--- a/org.eclipse.core.variables/src/org/eclipse/core/internal/variables/StringSubstitutionEngine.java
+++ b/org.eclipse.core.variables/src/org/eclipse/core/internal/variables/StringSubstitutionEngine.java
@@ -56,7 +56,7 @@ public class StringSubstitutionEngine {
*/
private Deque<VariableReference> fStack;
- class VariableReference {
+ static class VariableReference {
// the text inside the variable reference
private StringBuilder fText;
@@ -175,37 +175,35 @@ public class StringSubstitutionEngine {
VariableReference tos = fStack.peek();
tos.append(expression.substring(pos));
pos = expression.length();
+ } else if (start >= 0 && start < end) {
+ // start of a nested variable
+ int length = start - pos;
+ if (length > 0) {
+ VariableReference tos = fStack.peek();
+ tos.append(expression.substring(pos, start));
+ }
+ pos = start + 2;
+ fStack.push(new VariableReference());
} else {
- if (start >= 0 && start < end) {
- // start of a nested variable
- int length = start - pos;
- if (length > 0) {
- VariableReference tos = fStack.peek();
- tos.append(expression.substring(pos, start));
- }
- pos = start + 2;
- fStack.push(new VariableReference());
- } else {
- // end of variable reference
- VariableReference tos = fStack.pop();
- String substring = expression.substring(pos, end);
- tos.append(substring);
- resolvedVariables.add(substring);
+ // end of variable reference
+ VariableReference tos = fStack.pop();
+ String substring = expression.substring(pos, end);
+ tos.append(substring);
+ resolvedVariables.add(substring);
- pos = end + 1;
- String value= resolve(tos, reportUndefinedVariables, resolveVariables, manager);
- if (value == null) {
- value = ""; //$NON-NLS-1$
- }
- if (fStack.isEmpty()) {
- // append to result
- fResult.append(value);
- state = SCAN_FOR_START;
- } else {
- // append to previous variable
- tos = fStack.peek();
- tos.append(value);
- }
+ pos = end + 1;
+ String value= resolve(tos, reportUndefinedVariables, resolveVariables, manager);
+ if (value == null) {
+ value = ""; //$NON-NLS-1$
+ }
+ if (fStack.isEmpty()) {
+ // append to result
+ fResult.append(value);
+ state = SCAN_FOR_START;
+ } else {
+ // append to previous variable
+ tos = fStack.peek();
+ tos.append(value);
}
}
break;
diff --git a/org.eclipse.debug.core/.settings/.api_filters b/org.eclipse.debug.core/.settings/.api_filters
index c3e0e24e6..584b5ae5c 100644
--- a/org.eclipse.debug.core/.settings/.api_filters
+++ b/org.eclipse.debug.core/.settings/.api_filters
@@ -1,42 +1,18 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<component id="org.eclipse.debug.core" version="2">
- <resource path="core/org/eclipse/debug/core/sourcelookup/ISourceLookupDirector.java" type="org.eclipse.debug.core.sourcelookup.ISourceLookupDirector">
- <filter comment="565462#c15" id="404000815">
+ <resource path="META-INF/MANIFEST.MF">
+ <filter comment="See bug 574403 and bug 578358 comment 8" id="926941240">
<message_arguments>
- <message_argument value="org.eclipse.debug.core.sourcelookup.ISourceLookupDirector"/>
- <message_argument value="equalSourceElements(Object, Object)"/>
+ <message_argument value="3.19.0"/>
+ <message_argument value="3.18.300"/>
</message_arguments>
</filter>
</resource>
- <resource path="core/org/eclipse/debug/internal/core/groups/GroupLaunch.java" type="org.eclipse.debug.internal.core.groups.GroupLaunch">
- <filter comment="Bug 548841 - Mark internal package as x-internal in manifest" id="305365105">
+ <resource path="core/org/eclipse/debug/core/model/IProcess.java" type="org.eclipse.debug.core.model.IProcess">
+ <filter comment="See bug 574403 and bug 578358 comment 8" id="403767336">
<message_arguments>
- <message_argument value="org.eclipse.debug.internal.core.groups.GroupLaunch"/>
- <message_argument value="org.eclipse.debug.core_3.14.100"/>
- </message_arguments>
- </filter>
- </resource>
- <resource path="core/org/eclipse/debug/internal/core/groups/GroupLaunchConfigurationDelegate.java" type="org.eclipse.debug.internal.core.groups.GroupLaunchConfigurationDelegate">
- <filter comment="Bug 548841 - Mark internal package as x-internal in manifest" id="305365105">
- <message_arguments>
- <message_argument value="org.eclipse.debug.internal.core.groups.GroupLaunchConfigurationDelegate"/>
- <message_argument value="org.eclipse.debug.core_3.14.100"/>
- </message_arguments>
- </filter>
- </resource>
- <resource path="core/org/eclipse/debug/internal/core/groups/GroupLaunchElement.java" type="org.eclipse.debug.internal.core.groups.GroupLaunchElement">
- <filter comment="Bug 548841 - Mark internal package as x-internal in manifest" id="305365105">
- <message_arguments>
- <message_argument value="org.eclipse.debug.internal.core.groups.GroupLaunchElement"/>
- <message_argument value="org.eclipse.debug.core_3.14.100"/>
- </message_arguments>
- </filter>
- </resource>
- <resource path="core/org/eclipse/debug/internal/core/groups/GroupMemberChangeListener.java" type="org.eclipse.debug.internal.core.groups.GroupMemberChangeListener">
- <filter comment="Bug 548841 - Mark internal package as x-internal in manifest" id="305365105">
- <message_arguments>
- <message_argument value="org.eclipse.debug.internal.core.groups.GroupMemberChangeListener"/>
- <message_argument value="org.eclipse.debug.core_3.14.100"/>
+ <message_argument value="org.eclipse.debug.core.model.IProcess"/>
+ <message_argument value="ATTR_PROCESS_ID"/>
</message_arguments>
</filter>
</resource>
diff --git a/org.eclipse.debug.core/META-INF/MANIFEST.MF b/org.eclipse.debug.core/META-INF/MANIFEST.MF
index 5fab9dc69..60eb6d1db 100644
--- a/org.eclipse.debug.core/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.core/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.debug.core; singleton:=true
-Bundle-Version: 3.18.100.qualifier
+Bundle-Version: 3.19.100.qualifier
Bundle-ClassPath: .
Bundle-Activator: org.eclipse.debug.core.DebugPlugin
Bundle-Vendor: %providerName
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/core/commands/AbstractDebugCommand.java b/org.eclipse.debug.core/core/org/eclipse/debug/core/commands/AbstractDebugCommand.java
index 0471431ca..a5bcf748d 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/core/commands/AbstractDebugCommand.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/core/commands/AbstractDebugCommand.java
@@ -172,7 +172,7 @@ public abstract class AbstractDebugCommand implements IDebugCommandHandler {
/**
* Scheduling rule to serialize commands on an object
*/
- private class SerialPerObjectRule implements ISchedulingRule {
+ private static class SerialPerObjectRule implements ISchedulingRule {
private Object fObject = null;
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/core/model/IProcess.java b/org.eclipse.debug.core/core/org/eclipse/debug/core/model/IProcess.java
index e7d9aa3b2..2df9d2b2d 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/core/model/IProcess.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/core/model/IProcess.java
@@ -62,6 +62,15 @@ public interface IProcess extends IAdaptable, ITerminate {
String ATTR_PROCESS_LABEL = DebugPlugin.getUniqueIdentifier() + ".ATTR_PROCESS_LABEL"; //$NON-NLS-1$
/**
+ * Attribute key for a common, optional, process property. The value of this
+ * attribute specifies process id, displayed in the console description or
+ * in the debug view.
+ *
+ * @since 3.19
+ */
+ String ATTR_PROCESS_ID = DebugPlugin.getUniqueIdentifier() + ".ATTR_PROCESS_ID"; //$NON-NLS-1$
+
+ /**
* Returns a human-readable label for this process.
*
* @return a label for this process
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/core/model/RuntimeProcess.java b/org.eclipse.debug.core/core/org/eclipse/debug/core/model/RuntimeProcess.java
index 98122a8d6..62a4e6c5b 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/core/model/RuntimeProcess.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/core/model/RuntimeProcess.java
@@ -107,6 +107,8 @@ public class RuntimeProcess extends PlatformObject implements IProcess {
*/
private boolean fTerminateDescendants = true;
+ private final String fThreadNameSuffix;
+
/**
* Constructs a RuntimeProcess on the given system process
* with the given name, adding this process to the given
@@ -122,6 +124,11 @@ public class RuntimeProcess extends PlatformObject implements IProcess {
setLaunch(launch);
initializeAttributes(attributes);
fProcess = process;
+ try {
+ setAttribute(IProcess.ATTR_PROCESS_ID, Long.toString(process.pid()));
+ } catch (UnsupportedOperationException e) {
+ // ignore, pid() is not implemented in this JVM
+ }
fName = name;
fTerminated = true;
try {
@@ -141,14 +148,26 @@ public class RuntimeProcess extends PlatformObject implements IProcess {
} catch (CoreException e) {
DebugPlugin.log(e);
}
+ fThreadNameSuffix = getPidInfo(process, launch);
fStreamsProxy = createStreamsProxy();
- fMonitor = new ProcessMonitorThread();
+ fMonitor = new ProcessMonitorThread(fThreadNameSuffix);
fMonitor.start();
launch.addProcess(this);
fireCreationEvent();
}
+ private static String getPidInfo(Process process, ILaunch launch) {
+ String pid;
+ ILaunchConfiguration lc = launch == null ? null : launch.getLaunchConfiguration();
+ String name = lc == null ? "" : " " + lc.getName(); //$NON-NLS-1$ //$NON-NLS-2$
+ try {
+ pid = " for PID " + process.pid(); //$NON-NLS-1$
+ } catch (Exception e) {
+ pid = ""; //$NON-NLS-1$
+ }
+ return pid + name;
+ }
/**
* Initialize the attributes of this process to those in the given map.
*
@@ -216,37 +235,41 @@ public class RuntimeProcess extends PlatformObject implements IProcess {
@Override
public void terminate() throws DebugException {
if (!isTerminated()) {
- if (fStreamsProxy instanceof StreamsProxy) {
- ((StreamsProxy) fStreamsProxy).kill();
- }
- Process process = getSystemProcess();
- if (process == null) {
- return;
- }
-
- List<ProcessHandle> descendants = Collections.emptyList();
- if (fTerminateDescendants) {
- try { // List of descendants of process is only a snapshot!
- descendants = process.descendants().collect(Collectors.toList());
- } catch (UnsupportedOperationException e) {
- // JVM may not support toHandle() -> assume no descendants
+ try {
+ Process process = getSystemProcess();
+ if (process == null) {
+ return;
}
- }
- process.destroy();
- descendants.forEach(ProcessHandle::destroy);
+ List<ProcessHandle> descendants = Collections.emptyList();
+ if (fTerminateDescendants) {
+ try { // List of descendants of process is only a snapshot!
+ descendants = process.descendants().collect(Collectors.toList());
+ } catch (UnsupportedOperationException e) {
+ // JVM may not support toHandle() -> assume no
+ // descendants
+ }
+ }
- // await termination of process and descendants
- try { // (in total don't wait longer than TERMINATION_TIMEOUT)
- long waitStart = System.currentTimeMillis();
- if (process.waitFor(TERMINATION_TIMEOUT, TimeUnit.MILLISECONDS)) {
- fExitValue = process.exitValue();
- if (waitFor(descendants, waitStart)) {
- return;
+ process.destroy();
+ descendants.forEach(ProcessHandle::destroy);
+
+ // await termination of process and descendants
+ try { // (in total don't wait longer than TERMINATION_TIMEOUT)
+ long waitStart = System.currentTimeMillis();
+ if (process.waitFor(TERMINATION_TIMEOUT, TimeUnit.MILLISECONDS)) {
+ fExitValue = process.exitValue();
+ if (waitFor(descendants, waitStart)) {
+ return;
+ }
}
+ } catch (InterruptedException e) {
+ Thread.currentThread().interrupt();
+ }
+ } finally {
+ if (fStreamsProxy instanceof StreamsProxy) {
+ ((StreamsProxy) fStreamsProxy).kill();
}
- } catch (InterruptedException e) {
- Thread.currentThread().interrupt();
}
// clean-up
@@ -346,7 +369,7 @@ public class RuntimeProcess extends PlatformObject implements IProcess {
DebugPlugin.log(e);
}
}
- return new StreamsProxy(getSystemProcess(), charset);
+ return new StreamsProxy(getSystemProcess(), charset, fThreadNameSuffix);
}
/**
@@ -479,9 +502,11 @@ public class RuntimeProcess extends PlatformObject implements IProcess {
/**
* Creates a new process monitor and starts monitoring the process for
* termination.
+ *
+ * @param suffix Thread name suffix
*/
- private ProcessMonitorThread() {
- super(DebugCoreMessages.ProcessMonitorJob_0);
+ private ProcessMonitorThread(String suffix) {
+ super(DebugCoreMessages.ProcessMonitorJob_0 + suffix);
setDaemon(true);
}
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/BreakpointManager.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/BreakpointManager.java
index ae1f02c32..8725666b5 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/BreakpointManager.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/BreakpointManager.java
@@ -194,7 +194,7 @@ public class BreakpointManager implements IBreakpointManager, IResourceChangeLis
*
* @since 3.5
*/
- class DefaultImportParticipant implements IBreakpointImportParticipant {
+ static class DefaultImportParticipant implements IBreakpointImportParticipant {
@Override
public boolean matches(Map<String, Object> attributes, IBreakpoint breakpoint) throws CoreException {
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.java
index d38a64f67..d17d3fcd5 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.java
@@ -89,7 +89,6 @@ public class DebugCoreMessages extends NLS {
public static String LogicalStructureProvider_1;
public static String LogicalStructureType_1;
public static String SystemPropertyResolver_0;
- public static String InputStreamMonitor_label;
public static String Launch_terminate_failed;
public static String LaunchConfiguration_Failed_to_delete_launch_configuration__1;
public static String LaunchConfigurationDelegate_6;
@@ -115,7 +114,6 @@ public class DebugCoreMessages extends NLS {
public static String LaunchManager_invalid_config_name_char;
public static String LaunchManager_Source_locator_does_not_exist___0__13;
public static String LogicalStructureType_0;
- public static String OutputStreamMonitor_label;
public static String ProcessMonitorJob_0;
public static String RuntimeProcess_terminate_failed;
public static String RuntimeProcess_Exit_value_not_available_until_process_terminates__1;
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.properties b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.properties
index eae7e6de4..70ee71cf0 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.properties
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/DebugCoreMessages.properties
@@ -44,7 +44,6 @@ GroupLaunchConfigurationDelegate_Waiting_for_termination=Waiting for termination
GroupLaunchElement_inherit_launch_mode_label=Inherit
GroupLaunchElement_outputRegexp=Wait for console output (regexp)
SystemPropertyResolver_0=System property not specified
-InputStreamMonitor_label=Input Stream Monitor
Launch_terminate_failed=Terminate failed
LaunchConfiguration_Failed_to_delete_launch_configuration__1=Failed to delete launch configuration.
LaunchConfiguration_9=Preparing launch delegate...
@@ -114,7 +113,6 @@ LogicalStructureType_0=<Missing Description>
LogicalStructureType_1=Required attribute {0} missing for logicalStructureType extension.
LogicalStructureProvider_0=Required attribute modelIdentifier missing for logicalStructureType extension.
LogicalStructureProvider_1=Required attribute class missing for logicalStructureType extension.
-OutputStreamMonitor_label=Output Stream Monitor
ProcessMonitorJob_0=Process monitor
RuntimeProcess_terminate_failed=Terminate failed
RuntimeProcess_Exit_value_not_available_until_process_terminates__1=Exit value not available until process terminates.
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/InputStreamMonitor.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/InputStreamMonitor.java
index 7ed21a6ea..eacd9e3cb 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/InputStreamMonitor.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/InputStreamMonitor.java
@@ -127,14 +127,22 @@ public class InputStreamMonitor {
}
}
+ public void startMonitoring() {
+ startMonitoring("Input Stream Monitor"); //$NON-NLS-1$
+ }
+
/**
* Starts a thread which writes the stream.
- */
- public void startMonitoring() {
- if (fThread == null) {
- fThread = new Thread((Runnable) this::write, DebugCoreMessages.InputStreamMonitor_label);
- fThread.setDaemon(true);
- fThread.start();
+ *
+ * @param threadName Thread name
+ */
+ public void startMonitoring(String threadName) {
+ synchronized (this) {
+ if (fThread == null) {
+ fThread = new Thread((Runnable) this::write, threadName);
+ fThread.setDaemon(true);
+ fThread.start();
+ }
}
}
@@ -143,9 +151,12 @@ public class InputStreamMonitor {
* monitor and the underlying stream.
*/
public void close() {
- if (fThread != null) {
- Thread thread= fThread;
- fThread= null;
+ Thread thread = null;
+ synchronized (this) {
+ thread = fThread;
+ fThread = null;
+ }
+ if (thread != null) {
thread.interrupt();
}
}
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchConfiguration.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchConfiguration.java
index 3bc997eb0..bc9cdfea3 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchConfiguration.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchConfiguration.java
@@ -737,62 +737,62 @@ public class LaunchConfiguration extends PlatformObject implements ILaunchConfig
}
// allow the delegate to provide a launch implementation
ILaunch launch = null;
- if (delegate2 != null) {
- launch = delegate2.getLaunch(this, mode);
- }
- if (launch == null) {
- launch = new Launch(this, mode, null);
- } else // ensure the launch mode is valid
- if (!mode.equals(launch.getLaunchMode())) {
- IStatus status = new Status(IStatus.ERROR, DebugPlugin.getUniqueIdentifier(), DebugPlugin.ERROR,
- MessageFormat.format(DebugCoreMessages.LaunchConfiguration_14, mode, launch.getLaunchMode()), null);
- throw new CoreException(status);
- }
- launch.setAttribute(DebugPlugin.ATTR_LAUNCH_TIMESTAMP, Long.toString(System.currentTimeMillis()));
- boolean captureOutput = getAttribute(DebugPlugin.ATTR_CAPTURE_OUTPUT, true);
- if(!captureOutput) {
- launch.setAttribute(DebugPlugin.ATTR_CAPTURE_OUTPUT, "false"); //$NON-NLS-1$
- } else {
- launch.setAttribute(DebugPlugin.ATTR_CAPTURE_OUTPUT, null);
- }
- launch.setAttribute(DebugPlugin.ATTR_CONSOLE_ENCODING, getLaunchManager().getEncoding(this));
- if (register) {
- getLaunchManager().addLaunch(launch);
- }
- // perform initial pre-launch sanity checks
- lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_8);
-
- if (delegate2 != null) {
- if (!(delegate2.preLaunchCheck(this, mode, lmonitor.split(1)))) {
- getLaunchManager().removeLaunch(launch);
- return launch;
+ try {
+ if (delegate2 != null) {
+ launch = delegate2.getLaunch(this, mode);
}
- }
- lmonitor.setWorkRemaining(22);
- // perform pre-launch build
- if (build) {
- lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_7 + DebugCoreMessages.LaunchConfiguration_6);
- boolean tempbuild = build;
+ if (launch == null) {
+ launch = new Launch(this, mode, null);
+ } else // ensure the launch mode is valid
+ if (!mode.equals(launch.getLaunchMode())) {
+ IStatus status = new Status(IStatus.ERROR, DebugPlugin.getUniqueIdentifier(), DebugPlugin.ERROR,
+ MessageFormat.format(DebugCoreMessages.LaunchConfiguration_14, mode, launch.getLaunchMode()), null);
+ throw new CoreException(status);
+ }
+ launch.setAttribute(DebugPlugin.ATTR_LAUNCH_TIMESTAMP, Long.toString(System.currentTimeMillis()));
+ boolean captureOutput = getAttribute(DebugPlugin.ATTR_CAPTURE_OUTPUT, true);
+ if (!captureOutput) {
+ launch.setAttribute(DebugPlugin.ATTR_CAPTURE_OUTPUT, "false"); //$NON-NLS-1$
+ } else {
+ launch.setAttribute(DebugPlugin.ATTR_CAPTURE_OUTPUT, null);
+ }
+ launch.setAttribute(DebugPlugin.ATTR_CONSOLE_ENCODING, getLaunchManager().getEncoding(this));
+ if (register) {
+ getLaunchManager().addLaunch(launch);
+ }
+ // perform initial pre-launch sanity checks
+ lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_8);
+
if (delegate2 != null) {
- tempbuild = delegate2.buildForLaunch(this, mode, lmonitor.split(7));
+ if (!(delegate2.preLaunchCheck(this, mode, lmonitor.split(1)))) {
+ getLaunchManager().removeLaunch(launch);
+ return launch;
+ }
}
- if (tempbuild) {
- lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_7 + DebugCoreMessages.LaunchConfiguration_5);
- ResourcesPlugin.getWorkspace().build(IncrementalProjectBuilder.INCREMENTAL_BUILD, lmonitor.split(3));
+ lmonitor.setWorkRemaining(22);
+ // perform pre-launch build
+ if (build) {
+ lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_7 + DebugCoreMessages.LaunchConfiguration_6);
+ boolean tempbuild = build;
+ if (delegate2 != null) {
+ tempbuild = delegate2.buildForLaunch(this, mode, lmonitor.split(7));
+ }
+ if (tempbuild) {
+ lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_7 + DebugCoreMessages.LaunchConfiguration_5);
+ ResourcesPlugin.getWorkspace().build(IncrementalProjectBuilder.INCREMENTAL_BUILD, lmonitor.split(3));
+ }
}
- }
- lmonitor.setWorkRemaining(12);
- // final validation
- lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_4);
- if (delegate2 != null) {
- if (!(delegate2.finalLaunchCheck(this, mode, lmonitor.split(1)))) {
- getLaunchManager().removeLaunch(launch);
- return launch;
+ lmonitor.setWorkRemaining(12);
+ // final validation
+ lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_4);
+ if (delegate2 != null) {
+ if (!(delegate2.finalLaunchCheck(this, mode, lmonitor.split(1)))) {
+ getLaunchManager().removeLaunch(launch);
+ return launch;
+ }
}
- }
- lmonitor.setWorkRemaining(11);
+ lmonitor.setWorkRemaining(11);
- try {
//initialize the source locator
lmonitor.subTask(DebugCoreMessages.LaunchConfiguration_3);
initializeSourceLocator(launch);
@@ -803,13 +803,13 @@ public class LaunchConfiguration extends PlatformObject implements ILaunchConfig
delegate.launch(this, mode, launch, lmonitor.split(10));
} catch (CoreException e) {
// if there was an exception, and the launch is empty, remove it
- if (!launch.hasChildren()) {
+ if (launch != null && !launch.hasChildren()) {
getLaunchManager().removeLaunch(launch);
}
throw e;
} catch (RuntimeException e) {
// if there was a runtime exception, and the launch is empty, remove it
- if (!launch.hasChildren()) {
+ if (launch != null && !launch.hasChildren()) {
getLaunchManager().removeLaunch(launch);
}
throw e;
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchManager.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchManager.java
index fb9c0c749..d4689d0a6 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchManager.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchManager.java
@@ -442,7 +442,7 @@ public class LaunchManager extends PlatformObject implements ILaunchManager, IRe
* Collects files whose extension matches the launch configuration file
* extension.
*/
- class ResourceProxyVisitor implements IResourceProxyVisitor {
+ static class ResourceProxyVisitor implements IResourceProxyVisitor {
private List<IResource> fList;
@@ -467,7 +467,7 @@ public class LaunchManager extends PlatformObject implements ILaunchManager, IRe
*
* @since 3.3
*/
- class PreferredDelegate {
+ static class PreferredDelegate {
private ILaunchDelegate fDelegate = null;
private String fTypeid = null;
private Set<String> fModes = null;
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/NullStreamsProxy.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/NullStreamsProxy.java
index 494a9c297..a7ce39e00 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/NullStreamsProxy.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/NullStreamsProxy.java
@@ -64,7 +64,7 @@ public class NullStreamsProxy implements IBinaryStreamsProxy {
public void write(byte[] data, int offset, int length) throws IOException {
}
- private class NullStreamMonitor implements IBinaryStreamMonitor {
+ private static class NullStreamMonitor implements IBinaryStreamMonitor {
private InputStream fStream;
public NullStreamMonitor(InputStream stream) {
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/OutputStreamMonitor.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/OutputStreamMonitor.java
index bdc2cd539..218d87027 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/OutputStreamMonitor.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/OutputStreamMonitor.java
@@ -98,7 +98,8 @@ public class OutputStreamMonitor implements IBinaryStreamMonitor {
* unused if only the binary interface is used
*/
public OutputStreamMonitor(InputStream stream, Charset charset) {
- fStream = new BufferedInputStream(stream, 8192);
+ // java.lang.ProcessImpl returns a buffered stream anyway
+ fStream = stream instanceof BufferedInputStream ? stream : new BufferedInputStream(stream);
fCharset = charset;
fDecoder = new StreamDecoder(charset == null ? Charset.defaultCharset() : charset);
fDone = new AtomicBoolean(false);
@@ -134,15 +135,21 @@ public class OutputStreamMonitor implements IBinaryStreamMonitor {
* underlying stream by waiting for the thread to terminate.
*/
protected void close() {
- if (fThread != null) {
- Thread thread = fThread;
+ Thread thread = null;
+
+ synchronized (this) {
+ thread = fThread;
fThread = null;
+ }
+
+ if (thread != null) {
try {
thread.join();
} catch (InterruptedException ie) {
}
- fListeners = new ListenerList<>();
- fBinaryListeners = new ListenerList<>();
+
+ fListeners.clear();
+ fBinaryListeners.clear();
}
}
@@ -156,9 +163,7 @@ public class OutputStreamMonitor implements IBinaryStreamMonitor {
*/
private void fireStreamAppended(final byte[] data, int offset, int length) {
if (!fListeners.isEmpty()) {
- StringBuilder sb = new StringBuilder();
- fDecoder.decode(sb, data, offset, length);
- final String text = sb.toString();
+ String text = fDecoder.decode(data, offset, length);
for (final IStreamListener listener : fListeners) {
SafeRunner.run(new ISafeRunnable() {
@Override
@@ -205,10 +210,8 @@ public class OutputStreamMonitor implements IBinaryStreamMonitor {
if (fCachedDecodedContents != null) {
return fCachedDecodedContents;
}
- StringBuilder sb = new StringBuilder();
byte[] data = getData();
- fBufferedDecoder.decode(sb, data, 0, data.length);
- fCachedDecodedContents = sb.toString();
+ fCachedDecodedContents = fBufferedDecoder.decode(data, 0, data.length);
return fCachedDecodedContents;
}
@@ -270,11 +273,8 @@ public class OutputStreamMonitor implements IBinaryStreamMonitor {
currentTime = System.currentTimeMillis();
if (currentTime - lastSleep > 1000) {
lastSleep = currentTime;
- try {
- // just give up CPU to maintain UI responsiveness.
- Thread.sleep(1);
- } catch (InterruptedException e) {
- }
+ Thread.yield();// just give up CPU to maintain UI
+ // responsiveness.
}
}
} finally {
@@ -302,14 +302,18 @@ public class OutputStreamMonitor implements IBinaryStreamMonitor {
/**
* Starts a thread which reads from the stream
+ *
+ * @param name Thread name
*/
- protected void startMonitoring() {
- if (fThread == null) {
- fDone.set(false);
- fThread = new Thread((Runnable) this::read, DebugCoreMessages.OutputStreamMonitor_label);
- fThread.setDaemon(true);
- fThread.setPriority(Thread.MIN_PRIORITY);
- fThread.start();
+ protected void startMonitoring(String name) {
+ synchronized (this) {
+ if (fThread == null) {
+ fDone.set(false);
+ fThread = new Thread((Runnable) this::read, name);
+ fThread.setDaemon(true);
+ fThread.setPriority(Thread.MIN_PRIORITY);
+ fThread.start();
+ }
}
}
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/PreferredDelegateModifyListener.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/PreferredDelegateModifyListener.java
index fcba9059d..313392498 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/PreferredDelegateModifyListener.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/PreferredDelegateModifyListener.java
@@ -27,7 +27,7 @@ import org.osgi.service.prefs.BackingStoreException;
* @since 3.6 TODO can we roll this into general preference listening?
*/
public class PreferredDelegateModifyListener extends PreferenceModifyListener {
- class Visitor implements IPreferenceNodeVisitor {
+ static class Visitor implements IPreferenceNodeVisitor {
@Override
public boolean visit(IEclipsePreferences node) throws BackingStoreException {
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/RefreshScopeComparator.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/RefreshScopeComparator.java
index a875896d8..3a88dc34e 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/RefreshScopeComparator.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/RefreshScopeComparator.java
@@ -13,6 +13,7 @@
*******************************************************************************/
package org.eclipse.debug.internal.core;
+import java.util.Arrays;
import java.util.Comparator;
import org.eclipse.core.resources.IResource;
@@ -27,26 +28,21 @@ import org.eclipse.debug.core.RefreshUtil;
* @since 3.6
*/
public class RefreshScopeComparator implements Comparator<String> {
-
- @Override
- public int compare(String o1, String o2) {
- String m1 = o1;
- String m2 = o2;
+ private static IResource[] toResources(String memento) {
try {
- IResource[] r1 = RefreshUtil.toResources(m1);
- IResource[] r2 = RefreshUtil.toResources(m2);
- if (r1.length == r2.length) {
- for (int i = 0; i < r2.length; i++) {
- if (!r1[i].equals(r2[i])) {
- return -1;
- }
- }
- return 0;
- }
+ return RefreshUtil.toResources(memento);
} catch (CoreException e) {
- return -1;
+ return null;
}
- return -1;
+ }
+
+ private static final Comparator<IResource> RESOURCE = Comparator.nullsFirst(Comparator.comparing(r -> r.toString()));
+ private static final Comparator<IResource[]> ARRAY = Comparator.nullsFirst((IResource[] s1, IResource[] s2) -> Arrays.compare(s1, s2, RESOURCE));
+ private static final Comparator<String> MEMENTO = Comparator.nullsFirst(Comparator.comparing(m -> toResources(m), ARRAY));
+
+ @Override
+ public int compare(String o1, String o2) {
+ return MEMENTO.compare(o1, o2);
}
}
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamDecoder.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamDecoder.java
index 7cb15a736..f64d3d4d0 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamDecoder.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamDecoder.java
@@ -20,6 +20,7 @@ import java.nio.charset.Charset;
import java.nio.charset.CharsetDecoder;
import java.nio.charset.CoderResult;
import java.nio.charset.CodingErrorAction;
+import java.util.Set;
/**
* Wraps CharsetDecoder to decode a byte stream statefully to characters.
@@ -29,20 +30,30 @@ import java.nio.charset.CodingErrorAction;
public class StreamDecoder {
// For more context see https://bugs.eclipse.org/bugs/show_bug.cgi?id=507664
- static private final int BUFFER_SIZE = 4096;
+ /** size of java.io.BufferedInputStream.DEFAULT_BUFFER_SIZE **/
+ private static final int INPUT_BUFFER_SIZE = 8192;
+ private final Charset charset;
private final CharsetDecoder decoder;
private final ByteBuffer inputBuffer;
private final CharBuffer outputBuffer;
- private boolean finished;
+ private volatile boolean finished;
+
+ /**
+ * Incomplete list of known Single Byte Character Sets (see
+ * sun.nio.cs.SingleByte) which do not need a buffer
+ **/
+ Set<String> singlebyteCharsetNames = Set.of("ISO_8859_1", "US_ASCII", "windows-1250", "windows-1251", "windows-1252", "windows-1253", "windows-1254", "windows-1255", "windows-1256", "windows-1257", "windows-1258"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$ //$NON-NLS-7$ //$NON-NLS-8$ //$NON-NLS-9$ //$NON-NLS-10$ //$NON-NLS-11$
public StreamDecoder(Charset charset) {
- this.decoder = charset.newDecoder();
- this.decoder.onMalformedInput(CodingErrorAction.REPLACE);
- this.decoder.onUnmappableCharacter(CodingErrorAction.REPLACE);
- this.inputBuffer = ByteBuffer.allocate(StreamDecoder.BUFFER_SIZE);
- this.inputBuffer.flip();
- this.outputBuffer = CharBuffer.allocate(StreamDecoder.BUFFER_SIZE);
+ this.charset = charset;
+ CharsetDecoder d = charset.newDecoder();
+ d.onMalformedInput(CodingErrorAction.REPLACE);
+ d.onUnmappableCharacter(CodingErrorAction.REPLACE);
+ boolean unbuffered = singlebyteCharsetNames.contains(charset.name());
+ this.decoder = unbuffered ? null : d;
+ this.inputBuffer = unbuffered ? null : ByteBuffer.allocate(StreamDecoder.INPUT_BUFFER_SIZE).flip();
+ this.outputBuffer = unbuffered ? null : CharBuffer.allocate((int) (StreamDecoder.INPUT_BUFFER_SIZE * d.maxCharsPerByte()));
this.finished = false;
}
@@ -81,12 +92,31 @@ public class StreamDecoder {
} while (!finishedReading);
}
- public void decode(StringBuilder consumer, byte[] buffer, int offset, int length) {
+ public String decode(byte[] buffer, int offset, int length) {
+ if (this.decoder == null) {
+ // fast path for single byte encodings
+ return new String(buffer, offset, length, charset);
+ }
+ StringBuilder builder = new StringBuilder();
+ decode(builder, buffer, offset, length);
+ return builder.toString();
+ }
+
+ private void decode(StringBuilder consumer, byte[] buffer, int offset, int length) {
this.internalDecode(consumer, buffer, offset, length);
this.consume(consumer);
}
- public void finish(StringBuilder consumer) {
+ public String finish() {
+ if (this.decoder == null) {
+ return ""; //$NON-NLS-1$
+ }
+ StringBuilder builder = new StringBuilder();
+ finish(builder);
+ return builder.toString();
+ }
+
+ private void finish(StringBuilder consumer) {
if (this.finished) {
return;
}
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamsProxy.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamsProxy.java
index 0f14b7d1a..3996d9546 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamsProxy.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/StreamsProxy.java
@@ -55,18 +55,19 @@ public class StreamsProxy implements IBinaryStreamsProxy {
*
* @param process system process to create a streams proxy on
* @param charset the process's charset or <code>null</code> if default
+ * @param suffix Thread name suffix
*/
@SuppressWarnings("resource")
- public StreamsProxy(Process process, Charset charset) {
+ public StreamsProxy(Process process, Charset charset, String suffix) {
if (process == null) {
return;
}
fOutputMonitor = new OutputStreamMonitor(process.getInputStream(), charset);
fErrorMonitor = new OutputStreamMonitor(process.getErrorStream(), charset);
fInputMonitor = new InputStreamMonitor(process.getOutputStream(), charset);
- fOutputMonitor.startMonitoring();
- fErrorMonitor.startMonitoring();
- fInputMonitor.startMonitoring();
+ fOutputMonitor.startMonitoring("Output Stream Monitor" + suffix); //$NON-NLS-1$
+ fErrorMonitor.startMonitoring("Error Stream Monitor" + suffix); //$NON-NLS-1$
+ fInputMonitor.startMonitoring("Input Stream Monitor" + suffix); //$NON-NLS-1$
}
/**
@@ -83,7 +84,7 @@ public class StreamsProxy implements IBinaryStreamsProxy {
// but Bug 562653 brought up a client which use this internal class via
// reflection and breaks without this constructor. So we restored the
// old constructor for the time being.
- this(process, Charset.forName(encoding));
+ this(process, Charset.forName(encoding), ""); //$NON-NLS-1$
}
/**
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/XMLMemento.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/XMLMemento.java
index d8b6fe817..55ad375a5 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/XMLMemento.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/XMLMemento.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2018 IBM Corporation and others.
+ * Copyright (c) 2000, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -19,6 +19,7 @@ import java.io.PrintWriter;
import java.io.Reader;
import java.io.Writer;
import java.util.ArrayList;
+import java.util.Arrays;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
@@ -43,6 +44,8 @@ public final class XMLMemento {
private Element element;
+ private static String FILE_STRING = "file"; //$NON-NLS-1$
+
/**
* Creates a <code>Document</code> from the <code>Reader</code>
* and returns a memento on the first <code>Element</code> for reading
@@ -61,6 +64,27 @@ public final class XMLMemento {
}
/**
+ * Clients who need to use the "file" protocol can override this method to
+ * return the original attribute value
+ *
+ * @param attributeOldValue
+ * @return return the new attribute value after concatenating the "file"
+ * protocol restriction if does not exist already
+ */
+ private static String getAttributeNewValue(Object attributeOldValue) {
+ StringBuffer strNewValue = new StringBuffer(FILE_STRING);
+ if (attributeOldValue instanceof String && ((String) attributeOldValue).length() != 0) {
+ String strOldValue = (String) attributeOldValue;
+ boolean exists = Arrays.asList(strOldValue.split(",")).stream().anyMatch(x -> x.trim().equals(FILE_STRING)); //$NON-NLS-1$
+ if (!exists) {
+ strNewValue.append(", ").append(strOldValue); //$NON-NLS-1$
+ } else {
+ strNewValue = new StringBuffer(strOldValue);
+ }
+ }
+ return strNewValue.toString();
+ }
+ /**
* Creates a <code>Document</code> from the <code>Reader</code>
* and returns a memento on the first <code>Element</code> for reading
* the document.
@@ -78,10 +102,20 @@ public final class XMLMemento {
throws Exception {
String errorMessage = null;
Exception exception = null;
-
+ DocumentBuilderFactory factory = null;
+ Object attributeDTDOldValue = null;
+ Object attributeSchemaOldValue = null;
try {
- DocumentBuilderFactory factory = DocumentBuilderFactory
- .newInstance();
+ factory = DocumentBuilderFactory.newInstance();
+ try {
+ attributeDTDOldValue = factory.getAttribute(javax.xml.XMLConstants.ACCESS_EXTERNAL_DTD);
+ attributeSchemaOldValue = factory.getAttribute(javax.xml.XMLConstants.ACCESS_EXTERNAL_SCHEMA);
+ } catch (NullPointerException | IllegalArgumentException e) {
+ // Attributes not defined
+ }
+ factory.setAttribute(javax.xml.XMLConstants.ACCESS_EXTERNAL_DTD, getAttributeNewValue(attributeDTDOldValue));
+ factory.setAttribute(javax.xml.XMLConstants.ACCESS_EXTERNAL_SCHEMA, getAttributeNewValue(attributeSchemaOldValue));
+
DocumentBuilder parser = factory.newDocumentBuilder();
InputSource source = new InputSource(reader);
if (baseDir != null) {
@@ -104,6 +138,11 @@ public final class XMLMemento {
} catch (SAXException e) {
exception = e;
// errorMessage = WorkbenchMessages.XMLMemento_formatError;
+ } finally {
+ if (factory != null) {
+ factory.setAttribute(javax.xml.XMLConstants.ACCESS_EXTERNAL_DTD, attributeDTDOldValue);
+ factory.setAttribute(javax.xml.XMLConstants.ACCESS_EXTERNAL_SCHEMA, attributeSchemaOldValue);
+ }
}
String problemText = null;
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/sourcelookup/SourceLocatorMementoComparator.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/sourcelookup/SourceLocatorMementoComparator.java
index 1be76866d..5ec80ab85 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/sourcelookup/SourceLocatorMementoComparator.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/sourcelookup/SourceLocatorMementoComparator.java
@@ -24,6 +24,15 @@ public class SourceLocatorMementoComparator implements Comparator<String> {
@Override
public int compare(String o1, String o2) {
+ if (o1 == null && o2 == null) {
+ return 0;
+ }
+ if (o1 == null) {
+ return -1;
+ }
+ if (o2 == null) {
+ return 1;
+ }
String m1 = o1;
String m2 = o2;
int i1 = 0, i2 = 0;
@@ -32,7 +41,7 @@ public class SourceLocatorMementoComparator implements Comparator<String> {
i2 = skipWhitespace(m2, i2);
if (i1 < m1.length() && i2 < m2.length()) {
if (m1.charAt(i1) != m2.charAt(i2)) {
- return -1;
+ return m1.charAt(i1) - m2.charAt(i2);
}
i1++;
i2++;
@@ -40,6 +49,9 @@ public class SourceLocatorMementoComparator implements Comparator<String> {
if (i2 < m2.length()) {
return -1;
}
+ if (i1 < m1.length()) {
+ return 1;
+ }
return 0;
}
}
diff --git a/org.eclipse.debug.core/plugin.properties b/org.eclipse.debug.core/plugin.properties
index 886721320..aa747ccd7 100644
--- a/org.eclipse.debug.core/plugin.properties
+++ b/org.eclipse.debug.core/plugin.properties
@@ -75,3 +75,5 @@ Breakpoint.name = Breakpoint
GroupLaunch.name=Launch Group
GroupLaunch.description=Launch several other configurations sequentially
+
+LaunchConfiguration=Launch Configuration
diff --git a/org.eclipse.debug.core/plugin.xml b/org.eclipse.debug.core/plugin.xml
index 233aae3b4..13360fa45 100644
--- a/org.eclipse.debug.core/plugin.xml
+++ b/org.eclipse.debug.core/plugin.xml
@@ -280,4 +280,14 @@
public="true">
</launchConfigurationType>
</extension>
+ <extension
+ point="org.eclipse.core.contenttype.contentTypes">
+ <content-type
+ base-type="org.eclipse.core.runtime.xml"
+ file-extensions="launch"
+ id="org.eclipse.debug.core.launch"
+ name="%LaunchConfiguration"
+ priority="normal">
+ </content-type>
+ </extension>
</plugin>
diff --git a/org.eclipse.debug.examples.core/.classpath b/org.eclipse.debug.examples.core/.classpath
index 89e6e3861..53d4bb995 100644
--- a/org.eclipse.debug.examples.core/.classpath
+++ b/org.eclipse.debug.examples.core/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="src_ant"/>
diff --git a/org.eclipse.debug.examples.core/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.examples.core/.settings/org.eclipse.jdt.core.prefs
index 237d3ce90..d3220e286 100644
--- a/org.eclipse.debug.examples.core/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.debug.examples.core/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,12 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.release=disabled
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -146,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -240,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -274,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -298,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -351,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -387,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -415,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.examples.core/META-INF/MANIFEST.MF b/org.eclipse.debug.examples.core/META-INF/MANIFEST.MF
index a5f7859db..653c87811 100644
--- a/org.eclipse.debug.examples.core/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.examples.core/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-SymbolicName: org.eclipse.debug.examples.core;singleton:=true
-Bundle-Version: 1.4.800.qualifier
+Bundle-Version: 1.5.0.qualifier
Bundle-Activator: org.eclipse.debug.examples.core.pda.DebugCorePlugin
Require-Bundle: org.eclipse.core.runtime,
org.eclipse.core.resources,
@@ -19,7 +19,7 @@ Export-Package: org.eclipse.debug.examples.ant.tasks;x-friends:="org.eclipse.deb
org.eclipse.debug.examples.core.pda.protocol;x-friends:="org.eclipse.debug.examples.ui",
org.eclipse.debug.examples.core.pda.sourcelookup;x-friends:="org.eclipse.debug.examples.ui",
org.eclipse.debug.examples.pdavm;x-friends:="org.eclipse.debug.examples.ui"
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Bundle-ActivationPolicy: lazy
Bundle-Vendor: %Bundle-Vendor
Automatic-Module-Name: org.eclipse.debug.examples.core
diff --git a/org.eclipse.debug.examples.memory/.classpath b/org.eclipse.debug.examples.memory/.classpath
index eca7bdba8..e801ebfb4 100644
--- a/org.eclipse.debug.examples.memory/.classpath
+++ b/org.eclipse.debug.examples.memory/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.debug.examples.memory/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.examples.memory/.settings/org.eclipse.jdt.core.prefs
index fb248dec4..d3220e286 100644
--- a/org.eclipse.debug.examples.memory/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.debug.examples.memory/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,11 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -145,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -239,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -273,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -297,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -350,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -386,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -414,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.examples.memory/META-INF/MANIFEST.MF b/org.eclipse.debug.examples.memory/META-INF/MANIFEST.MF
index ac8629ba7..8b33f4f91 100644
--- a/org.eclipse.debug.examples.memory/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.examples.memory/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-SymbolicName: org.eclipse.debug.examples.memory;singleton:=true
-Bundle-Version: 1.102.200.qualifier
+Bundle-Version: 1.103.0.qualifier
Bundle-ClassPath: .
Bundle-Activator: org.eclipse.debug.examples.internal.memory.MemoryViewSamplePlugin
Bundle-Vendor: %Bundle-Vendor
@@ -19,5 +19,5 @@ Require-Bundle: org.eclipse.core.expressions,
org.eclipse.core.resources,
org.eclipse.jface.text
Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Automatic-Module-Name: org.eclipse.debug.examples.memory
diff --git a/org.eclipse.debug.examples.memory/pom.xml b/org.eclipse.debug.examples.memory/pom.xml
index 60e51ec07..1d5d60005 100644
--- a/org.eclipse.debug.examples.memory/pom.xml
+++ b/org.eclipse.debug.examples.memory/pom.xml
@@ -14,11 +14,11 @@
<parent>
<artifactId>eclipse.platform.debug</artifactId>
<groupId>eclipse.platform.debug</groupId>
- <version>4.20.0-SNAPSHOT</version>
+ <version>4.24.0-SNAPSHOT</version>
</parent>
<groupId>org.eclipse.debug</groupId>
<artifactId>org.eclipse.debug.examples.memory</artifactId>
- <version>1.102.200-SNAPSHOT</version>
+ <version>1.103.0-SNAPSHOT</version>
<packaging>eclipse-plugin</packaging>
<properties>
<skipAPIAnalysis>true</skipAPIAnalysis>
diff --git a/org.eclipse.debug.examples.mixedmode/.classpath b/org.eclipse.debug.examples.mixedmode/.classpath
index eca7bdba8..e801ebfb4 100755
--- a/org.eclipse.debug.examples.mixedmode/.classpath
+++ b/org.eclipse.debug.examples.mixedmode/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.debug.examples.mixedmode/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.examples.mixedmode/.settings/org.eclipse.jdt.core.prefs
index fb248dec4..d3220e286 100644
--- a/org.eclipse.debug.examples.mixedmode/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.debug.examples.mixedmode/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,11 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -145,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -239,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -273,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -297,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -350,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -386,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -414,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.examples.mixedmode/META-INF/MANIFEST.MF b/org.eclipse.debug.examples.mixedmode/META-INF/MANIFEST.MF
index 39ebef3dd..920308969 100755
--- a/org.eclipse.debug.examples.mixedmode/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.examples.mixedmode/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-SymbolicName: org.eclipse.debug.examples.mixedmode;singleton:=true
-Bundle-Version: 1.2.0.qualifier
+Bundle-Version: 1.3.0.qualifier
Bundle-Activator: org.eclipse.debug.internal.examples.mixedmode.Activator
Bundle-Vendor: %Bundle-Vendor
Require-Bundle: org.eclipse.ui,
@@ -12,5 +12,5 @@ Require-Bundle: org.eclipse.ui,
org.eclipse.ui.workbench.texteditor
Bundle-ActivationPolicy: lazy
Export-Package: org.eclipse.debug.internal.examples.mixedmode;x-internal:=true
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Automatic-Module-Name: org.eclipse.debug.examples.mixedmode
diff --git a/org.eclipse.debug.examples.mixedmode/pom.xml b/org.eclipse.debug.examples.mixedmode/pom.xml
index 6a9973430..dd8250edc 100644
--- a/org.eclipse.debug.examples.mixedmode/pom.xml
+++ b/org.eclipse.debug.examples.mixedmode/pom.xml
@@ -14,11 +14,11 @@
<parent>
<artifactId>eclipse.platform.debug</artifactId>
<groupId>eclipse.platform.debug</groupId>
- <version>4.20.0-SNAPSHOT</version>
+ <version>4.24.0-SNAPSHOT</version>
</parent>
<groupId>org.eclipse.debug</groupId>
<artifactId>org.eclipse.debug.examples.mixedmode</artifactId>
- <version>1.2.0-SNAPSHOT</version>
+ <version>1.3.0-SNAPSHOT</version>
<packaging>eclipse-plugin</packaging>
<properties>
<skipAPIAnalysis>true</skipAPIAnalysis>
diff --git a/org.eclipse.debug.examples.ui/.classpath b/org.eclipse.debug.examples.ui/.classpath
index eca7bdba8..e801ebfb4 100644
--- a/org.eclipse.debug.examples.ui/.classpath
+++ b/org.eclipse.debug.examples.ui/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.debug.examples.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.examples.ui/.settings/org.eclipse.jdt.core.prefs
index fb248dec4..d3220e286 100644
--- a/org.eclipse.debug.examples.ui/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.debug.examples.ui/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,11 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -145,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -239,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -273,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -297,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -350,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -386,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -414,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.examples.ui/META-INF/MANIFEST.MF b/org.eclipse.debug.examples.ui/META-INF/MANIFEST.MF
index 02884d10f..47d40d8f4 100644
--- a/org.eclipse.debug.examples.ui/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.examples.ui/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-SymbolicName: org.eclipse.debug.examples.ui;singleton:=true
-Bundle-Version: 1.6.400.qualifier
+Bundle-Version: 1.7.100.qualifier
Bundle-Activator: org.eclipse.debug.examples.ui.pda.DebugUIPlugin
Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.11.0,4.0.0)",
org.eclipse.core.resources,
@@ -26,7 +26,7 @@ Export-Package: org.eclipse.debug.examples.ui.midi.adapters;x-internal:=true,
org.eclipse.debug.examples.ui.pda.launcher;x-internal:=true,
org.eclipse.debug.examples.ui.pda.presentation;x-internal:=true,
org.eclipse.debug.examples.ui.pda.views;x-internal:=true
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Bundle-ActivationPolicy: lazy
Bundle-Vendor: %Bundle-Vendor
Bundle-ClassPath: .
diff --git a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/adapters/PDAVirtualFindAction.java b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/adapters/PDAVirtualFindAction.java
index 3e002de85..37d115b47 100644
--- a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/adapters/PDAVirtualFindAction.java
+++ b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/adapters/PDAVirtualFindAction.java
@@ -67,7 +67,7 @@ public class PDAVirtualFindAction extends Action implements IUpdate {
private final TreeModelViewer fClientViewer;
- protected class VirtualViewerListener implements IViewerUpdateListener, ILabelUpdateListener {
+ protected static class VirtualViewerListener implements IViewerUpdateListener, ILabelUpdateListener {
private boolean fViewerUpdatesComplete = false;
private boolean fLabelUpdatesComplete = false;
diff --git a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/breakpoints/PDAToggleWatchpointsTarget.java b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/breakpoints/PDAToggleWatchpointsTarget.java
index 0fe58af12..489f4772a 100644
--- a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/breakpoints/PDAToggleWatchpointsTarget.java
+++ b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/breakpoints/PDAToggleWatchpointsTarget.java
@@ -54,11 +54,9 @@ public class PDAToggleWatchpointsTarget extends PDABreakpointAdapter {
public boolean canToggleWatchpoints(IWorkbenchPart part, ISelection selection) {
if (super.canToggleWatchpoints(part, selection)) {
return true;
- } else {
- if (selection instanceof IStructuredSelection) {
- IStructuredSelection ss = (IStructuredSelection)selection;
- return ss.getFirstElement() instanceof PDAVariable;
- }
+ } else if (selection instanceof IStructuredSelection) {
+ IStructuredSelection ss = (IStructuredSelection)selection;
+ return ss.getFirstElement() instanceof PDAVariable;
}
return false;
}
diff --git a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/editor/PDAScanner.java b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/editor/PDAScanner.java
index aa586afe5..4de0f7c77 100644
--- a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/editor/PDAScanner.java
+++ b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/editor/PDAScanner.java
@@ -39,7 +39,7 @@ public class PDAScanner extends BufferedRuleBasedScanner {
/**
* Detects potential keywords
*/
- class PDAWordDetector implements IWordDetector {
+ static class PDAWordDetector implements IWordDetector {
@Override
public boolean isWordStart(char c) {
diff --git a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/launcher/PDAMainTab.java b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/launcher/PDAMainTab.java
index 9434e1a6b..61614a587 100644
--- a/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/launcher/PDAMainTab.java
+++ b/org.eclipse.debug.examples.ui/src/org/eclipse/debug/examples/ui/pda/launcher/PDAMainTab.java
@@ -178,10 +178,8 @@ public class PDAMainTab extends AbstractLaunchConfigurationTab {
if (member == null) {
setErrorMessage("Specified program does not exist"); //$NON-NLS-1$
return false;
- } else {
- if (member.getType() != IResource.FILE) {
- setWarningMessage("Specified program is not a file."); //$NON-NLS-1$
- }
+ } else if (member.getType() != IResource.FILE) {
+ setWarningMessage("Specified program is not a file."); //$NON-NLS-1$
}
} else {
setMessage("Specify a program"); //$NON-NLS-1$
diff --git a/org.eclipse.debug.tests/META-INF/MANIFEST.MF b/org.eclipse.debug.tests/META-INF/MANIFEST.MF
index 7695c6432..1dffc2bae 100644
--- a/org.eclipse.debug.tests/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.tests/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.debug.tests;singleton:=true
-Bundle-Version: 3.12.200.qualifier
+Bundle-Version: 3.12.700.qualifier
Bundle-Activator: org.eclipse.debug.tests.TestsPlugin
Bundle-Localization: plugin
Require-Bundle: org.eclipse.ui;bundle-version="[3.6.0,4.0.0)",
@@ -29,6 +29,7 @@ Export-Package: org.eclipse.debug.tests,
org.eclipse.debug.tests.sourcelookup,
org.eclipse.debug.tests.statushandlers,
org.eclipse.debug.tests.stepfilters,
+ org.eclipse.debug.tests.ui,
org.eclipse.debug.tests.view.memory,
org.eclipse.debug.tests.viewer.model
Eclipse-BundleShape: dir
diff --git a/org.eclipse.debug.tests/plugin.properties b/org.eclipse.debug.tests/plugin.properties
index 8fcb3b9f3..56ca2e3b1 100755
--- a/org.eclipse.debug.tests/plugin.properties
+++ b/org.eclipse.debug.tests/plugin.properties
@@ -21,4 +21,5 @@ renderingType.name.1 = Rendering Default
launchConfigurationType.name = Test Launch Type
extension.name = Debug File System
launchConfigurationType.name.0 = Cancelling Launch Type
+launchConfigurationType.name.1 = Throwing Launch Type
testBreakpoint.name = Test Breakpoint \ No newline at end of file
diff --git a/org.eclipse.debug.tests/plugin.xml b/org.eclipse.debug.tests/plugin.xml
index a350e91c8..3738652a0 100644
--- a/org.eclipse.debug.tests/plugin.xml
+++ b/org.eclipse.debug.tests/plugin.xml
@@ -71,6 +71,12 @@
modes="run"
name="%launchConfigurationType.name.0">
</launchConfigurationType>
+ <launchConfigurationType
+ delegate="org.eclipse.debug.tests.launching.ThrowingLaunchDelegate"
+ id="throwing.type"
+ modes="run"
+ name="%launchConfigurationType.name.1">
+ </launchConfigurationType>
</extension>
<extension
id="debugFS"
@@ -142,4 +148,19 @@
modelIdentifier="org.eclipse.debug.tests">
</logicalStructureType>
</extension>
+ <extension
+ point="org.eclipse.debug.ui.variableValueEditors">
+ <variableValueEditor
+ modelId="testModel"
+ priority="x"
+ class="org.eclipse.debug.tests.ui.TestVariableValueEditor1"/>
+ <variableValueEditor
+ modelId="testModel"
+ priority="10"
+ class="org.eclipse.debug.tests.ui.TestVariableValueEditor2"/>
+ <variableValueEditor
+ modelId="testModel"
+ priority="-1"
+ class="org.eclipse.debug.tests.ui.TestVariableValueEditor3"/>
+ </extension>
</plugin>
diff --git a/org.eclipse.debug.tests/pom.xml b/org.eclipse.debug.tests/pom.xml
index cd08a840c..c55bdbc41 100644
--- a/org.eclipse.debug.tests/pom.xml
+++ b/org.eclipse.debug.tests/pom.xml
@@ -14,11 +14,11 @@
<parent>
<artifactId>eclipse.platform.debug</artifactId>
<groupId>eclipse.platform.debug</groupId>
- <version>4.20.0-SNAPSHOT</version>
+ <version>4.24.0-SNAPSHOT</version>
</parent>
<groupId>org.eclipse.debug</groupId>
<artifactId>org.eclipse.debug.tests</artifactId>
- <version>3.12.200-SNAPSHOT</version>
+ <version>3.12.700-SNAPSHOT</version>
<packaging>eclipse-test-plugin</packaging>
<properties>
<code.ignoredWarnings>${tests.ignoredWarnings}</code.ignoredWarnings>
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/AutomatedSuite.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/AutomatedSuite.java
index b28236add..be2dc6124 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/AutomatedSuite.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/AutomatedSuite.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2009, 2020 IBM Corporation and others.
+ * Copyright (c) 2009, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -17,6 +17,7 @@ package org.eclipse.debug.tests;
import org.eclipse.debug.tests.breakpoint.BreakpointOrderingTests;
import org.eclipse.debug.tests.breakpoint.BreakpointTests;
+import org.eclipse.debug.tests.breakpoint.SerialExecutorTest;
import org.eclipse.debug.tests.console.ConsoleDocumentAdapterTests;
import org.eclipse.debug.tests.console.ConsoleManagerTests;
import org.eclipse.debug.tests.console.ConsoleTests;
@@ -43,7 +44,9 @@ import org.eclipse.debug.tests.logicalstructure.LogicalStructureCacheTest;
import org.eclipse.debug.tests.sourcelookup.SourceLookupFacilityTests;
import org.eclipse.debug.tests.statushandlers.StatusHandlerTests;
import org.eclipse.debug.tests.stepfilters.StepFiltersTests;
+import org.eclipse.debug.tests.ui.VariableValueEditorManagerTests;
import org.eclipse.debug.tests.view.memory.MemoryRenderingTests;
+import org.eclipse.debug.tests.view.memory.TableRenderingTests;
import org.eclipse.debug.tests.viewer.model.ChildrenUpdateTests;
import org.eclipse.debug.tests.viewer.model.FilterTransformTests;
import org.eclipse.debug.tests.viewer.model.PresentationContextTests;
@@ -69,6 +72,7 @@ import org.junit.runners.Suite;
// BP tests
BreakpointOrderingTests.class,
BreakpointTests.class,
+ SerialExecutorTest.class,
// Note: jface viewer tests were moved out of nightly tests
// due to frequent problems on nightly build machines.
// (Bug 343308).
@@ -86,9 +90,11 @@ import org.junit.runners.Suite;
FilterTransformTests.class,
ChildrenUpdateTests.class,
PresentationContextTests.class,
+ VariableValueEditorManagerTests.class,
// Memory view
MemoryRenderingTests.class,
+ TableRenderingTests.class,
// Launch framework
LaunchConfigurationTests.class,
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/breakpoint/SerialExecutorTest.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/breakpoint/SerialExecutorTest.java
new file mode 100644
index 000000000..73e63efb5
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/breakpoint/SerialExecutorTest.java
@@ -0,0 +1,163 @@
+/*******************************************************************************
+ * Copyright (c) 2021 Joerg Kubitz and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Joerg Kubitz - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.breakpoint;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import java.util.concurrent.atomic.AtomicInteger;
+import java.util.concurrent.locks.ReentrantReadWriteLock;
+import java.util.concurrent.locks.ReentrantReadWriteLock.WriteLock;
+
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.debug.internal.ui.model.elements.SerialExecutor;
+import org.eclipse.debug.tests.AbstractDebugTest;
+import org.junit.Ignore;
+import org.junit.Test;
+
+@SuppressWarnings("restriction")
+public class SerialExecutorTest extends AbstractDebugTest {
+ @Override
+ public void tearDown() throws Exception {
+ Job.getJobManager().cancel(this);
+ super.tearDown();
+ }
+
+ @Test
+ public void testSimpleExecution() throws InterruptedException {
+ SerialExecutor serialExecutor = new SerialExecutor("test", this);
+ AtomicInteger executions = new AtomicInteger(0);
+ serialExecutor.schedule(() -> executions.incrementAndGet());
+ Job.getJobManager().join(this, null);
+ assertEquals(1, executions.get());
+ serialExecutor.schedule(() -> executions.incrementAndGet());
+ Job.getJobManager().join(this, null);
+ assertEquals(2, executions.get());
+ serialExecutor.schedule(() -> executions.incrementAndGet());
+ serialExecutor.schedule(() -> executions.incrementAndGet());
+ Job.getJobManager().join(this, null);
+ assertEquals(4, executions.get());
+ }
+
+ @Test
+ public void testSerialExecution() throws InterruptedException {
+ SerialExecutor serialExecutor = new SerialExecutor("test", this);
+ AtomicInteger executions = new AtomicInteger(0);
+ AtomicInteger parallelExecutions = new AtomicInteger(0);
+ final ReentrantReadWriteLock rwl = new ReentrantReadWriteLock();
+ int RUNS = 20;
+ int WAIT_MILLIS = 2;
+ long start = System.nanoTime();
+ for (int i = 0; i < RUNS; i++) {
+ serialExecutor.schedule(() -> {
+ WriteLock writeLock = rwl.writeLock();
+ if (writeLock.tryLock()) {
+ try {
+ Thread.sleep(WAIT_MILLIS);
+ executions.incrementAndGet();
+ } catch (InterruptedException e) {
+ // interrupt should not happen -> fail test
+ parallelExecutions.incrementAndGet();
+ }
+ writeLock.unlock();
+ } else {
+ // another thread already holding the lock
+ // should not happen -> fail test
+ parallelExecutions.incrementAndGet();
+ }
+ Job[] jobs = Job.getJobManager().find(SerialExecutorTest.this);
+ if (jobs.length != 1) {
+ parallelExecutions.incrementAndGet();
+ }
+ });
+ }
+ Job.getJobManager().join(this, null);
+ Job[] jobs = Job.getJobManager().find(this);
+ assertEquals(0, jobs.length);
+ long stop = System.nanoTime();
+ long millis = (stop - start) / 1000_000;
+ assertEquals(RUNS, executions.get());
+ assertEquals(0, parallelExecutions.get());
+ long minimalMillis = RUNS * WAIT_MILLIS;
+ assertTrue("Test did finish too fast (" + millis + " ms)", millis >= minimalMillis);
+ }
+
+ @Test
+ public void testSchedulingQueue() throws InterruptedException {
+ // Executor has to execute every task. Even when they are faster
+ // scheduled then executed
+ SerialExecutor serialExecutor = new SerialExecutor("test", this);
+ AtomicInteger executions = new AtomicInteger();
+ int RUNS = 20;
+ int WAIT_MILLIS = 2;
+ for (int i = 0; i < RUNS; i++) {
+ serialExecutor.schedule(() -> {
+ try {
+ Thread.sleep(WAIT_MILLIS);
+ executions.incrementAndGet();
+ } catch (InterruptedException e) {
+ // error
+ }
+ });
+ }
+ Job.getJobManager().join(this, null);
+ Job[] jobs = Job.getJobManager().find(this);
+ assertEquals(0, jobs.length);
+ assertEquals(RUNS, executions.get());
+ }
+
+ @Test
+ @Ignore("See https://bugs.eclipse.org/bugs/show_bug.cgi?id=574883")
+ public void testHeavyScheduling() throws InterruptedException {
+ // Executor has to execute every task. Even when they are scheduled fast
+ // and execute fast
+ SerialExecutor serialExecutor = new SerialExecutor("test", this);
+ AtomicInteger executions = new AtomicInteger();
+ int RUNS = 200;
+ for (int i = 0; i < RUNS; i++) {
+ serialExecutor.schedule(() -> executions.incrementAndGet());
+ }
+ Job.getJobManager().join(this, null);
+ Job[] jobs = Job.getJobManager().find(this);
+ assertEquals(0, jobs.length);
+ assertEquals(RUNS, executions.get());
+ }
+
+ @Test
+ public void testJoin() throws InterruptedException {
+ // The last scheduled job has to be done before join() returns
+ for (int run = 0; run < 100; run++) {
+ SerialExecutor serialExecutor = new SerialExecutor("test", this);
+ AtomicInteger executions = new AtomicInteger();
+ int RUNS = 20;
+ int WAIT_MILLIS = 1;
+ for (int i = 0; i < RUNS; i++) {
+ serialExecutor.schedule(() -> {
+ try {
+ Thread.sleep(WAIT_MILLIS);
+ executions.incrementAndGet();
+ } catch (InterruptedException e) {
+ // error
+ }
+ });
+ }
+ Job.getJobManager().join(this, null);
+ Job[] jobs = Job.getJobManager().find(this);
+ assertEquals(0, jobs.length);
+ assertEquals("failed on run " + run, RUNS, executions.get());
+ // does fail on run ~ 40 if the final job.join() is removed.
+ }
+ }
+
+} \ No newline at end of file
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/IOConsoleTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/IOConsoleTests.java
index ae51f9f7f..bc1157c29 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/IOConsoleTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/IOConsoleTests.java
@@ -28,10 +28,10 @@ import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
+import java.util.Queue;
import java.util.Random;
+import java.util.concurrent.ConcurrentLinkedQueue;
import java.util.concurrent.atomic.AtomicBoolean;
-import java.util.concurrent.atomic.AtomicInteger;
-
import org.eclipse.core.runtime.ILogListener;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
@@ -78,12 +78,12 @@ public class IOConsoleTests extends AbstractDebugTest {
* Number of received log messages with severity error while running a
* single test method.
*/
- private final AtomicInteger loggedErrors = new AtomicInteger();
+ private final Queue<IStatus> loggedErrors = new ConcurrentLinkedQueue<>();
/** Listener to count error messages while testing. */
private final ILogListener errorLogListener = (IStatus status, String plugin) -> {
if (status.matches(IStatus.ERROR)) {
- loggedErrors.incrementAndGet();
+ loggedErrors.add(status);
}
};
@@ -107,7 +107,7 @@ public class IOConsoleTests extends AbstractDebugTest {
activePage.activate(consoleView);
// add error listener
- loggedErrors.set(0);
+ loggedErrors.clear();
Platform.addLogListener(errorLogListener);
}
@@ -117,7 +117,16 @@ public class IOConsoleTests extends AbstractDebugTest {
Platform.removeLogListener(errorLogListener);
super.tearDown();
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
+ }
+
+ private void assertNoError() {
+ loggedErrors.forEach(status -> {
+ if (status.getException() != null) {
+ throw new AssertionError("Test triggered errors in IOConsole", status.getException());
+ }
+ });
+ assertTrue("Test triggered errors in IOConsole: " + loggedErrors.stream().toString(), loggedErrors.isEmpty());
}
/**
@@ -309,7 +318,7 @@ public class IOConsoleTests extends AbstractDebugTest {
}
closeConsole(c);
}
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
}
/**
@@ -436,7 +445,7 @@ public class IOConsoleTests extends AbstractDebugTest {
assertEquals("Wrong number of lines.", 4, c.getDocument().getNumberOfLines());
closeConsole(c);
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
}
/**
@@ -518,7 +527,7 @@ public class IOConsoleTests extends AbstractDebugTest {
c.verifyContentByLine("1.", 0).verifyContentByLine("2.", 1).verifyPartitions();
}
closeConsole(c);
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
}
/**
@@ -564,7 +573,7 @@ public class IOConsoleTests extends AbstractDebugTest {
assertTrue("Line breaks did not overwrite text.", !c.getDocument().get().contains("err"));
}
closeConsole(c);
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
}
/**
@@ -722,7 +731,7 @@ public class IOConsoleTests extends AbstractDebugTest {
c.verifyContent("()").verifyPartitions();
closeConsole(c);
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
}
/**
@@ -844,7 +853,7 @@ public class IOConsoleTests extends AbstractDebugTest {
}
c.verifyPartitions();
closeConsole(c, "#");
- assertEquals("Test triggered errors in IOConsole.", 0, loggedErrors.get());
+ assertNoError();
}
/**
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/InputStreamMonitorTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/InputStreamMonitorTests.java
index 361995c89..45f77569d 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/InputStreamMonitorTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/InputStreamMonitorTests.java
@@ -25,7 +25,6 @@ import java.util.Set;
import java.util.function.Supplier;
import org.eclipse.core.runtime.Platform;
-import org.eclipse.debug.internal.core.DebugCoreMessages;
import org.eclipse.debug.internal.core.InputStreamMonitor;
import org.eclipse.debug.tests.AbstractDebugTest;
import org.eclipse.debug.tests.TestUtil;
@@ -96,9 +95,10 @@ public class InputStreamMonitorTests extends AbstractDebugTest {
@Test
@SuppressWarnings("resource")
public void testClose() throws Exception {
+ String threadName = "MAGICtestClose";
Supplier<Long> getInputStreamMonitorThreads = () -> {
Set<Thread> allThreads = Thread.getAllStackTraces().keySet();
- long numMonitorThreads = allThreads.stream().filter(t -> DebugCoreMessages.InputStreamMonitor_label.equals(t.getName())).count();
+ long numMonitorThreads = allThreads.stream().filter(t -> t.getName().contains(threadName)).count();
return numMonitorThreads;
};
long alreadyLeakedThreads = getInputStreamMonitorThreads.get();
@@ -117,7 +117,7 @@ public class InputStreamMonitorTests extends AbstractDebugTest {
{
ClosableTestOutputStream testStream = new ClosableTestOutputStream();
InputStreamMonitor monitor = new InputStreamMonitor(testStream);
- monitor.startMonitoring();
+ monitor.startMonitoring(threadName);
assertEquals("Stream closed to early.", 0, testStream.numClosed);
monitor.close();
TestUtil.waitWhile(() -> testStream.numClosed == 0, 200);
@@ -126,7 +126,7 @@ public class InputStreamMonitorTests extends AbstractDebugTest {
{
ClosableTestOutputStream testStream = new ClosableTestOutputStream();
InputStreamMonitor monitor = new InputStreamMonitor(testStream);
- monitor.startMonitoring();
+ monitor.startMonitoring(threadName);
assertEquals("Stream closed to early.", 0, testStream.numClosed);
monitor.closeInputStream();
monitor.close();
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/MockProcess.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/MockProcess.java
index 21f388053..c615cb40b 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/MockProcess.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/MockProcess.java
@@ -15,6 +15,7 @@ package org.eclipse.debug.tests.console;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
+import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.Map;
@@ -73,6 +74,31 @@ public class MockProcess extends Process {
private int terminationDelay = 0;
/**
+ * For mode used by constructor {@link MockProcess#MockProcess()} this
+ * indicates via stdout what the state of the process is.
+ */
+ public static enum ProcessState {
+ RUNNING('R'), DESTROYING('D'),
+ /**
+ * Last read is special as it should only be returned once to ensure
+ * that we get the last character on the stream.
+ */
+ LASTREAD('L'), TERMINATED(-1);
+
+ private int code;
+
+ ProcessState(int c) {
+ this.code = c;
+ }
+
+ public int getCode() {
+ return code;
+ }
+ }
+
+ private volatile ProcessState processState = ProcessState.RUNNING;
+
+ /**
* Create new silent mockup process which runs for a given amount of time.
* Does not read input or produce any output.
*
@@ -141,6 +167,39 @@ public class MockProcess extends Process {
}
/**
+ * Create a new mock process that the stdout stream will indicate status of
+ * the process. The codes are defined by {@link ProcessState#getCode()}
+ */
+ public MockProcess() {
+ super();
+ this.stderr = new ByteArrayInputStream(new byte[0]);
+ this.endTime = RUN_FOREVER;
+ this.stdout = new InputStream() {
+ @Override
+ public int read() throws IOException {
+ if (processState == ProcessState.LASTREAD) {
+ /*
+ * This sleep makes
+ * RuntimeProcessTests.testOutputAfterDestroy() fail because
+ * RuntimeProcess.terminate does not wait until the monitor
+ * threads completes. The sleep here just helps amplify a
+ * the thread scheduling decision that otherwise makes
+ * testOutputAfterDestroy unstable (as reported in Bug
+ * 577185)
+ */
+ try {
+ Thread.sleep(1000);
+ } catch (InterruptedException e) {
+ }
+ processState = ProcessState.TERMINATED;
+ return ProcessState.LASTREAD.getCode();
+ }
+ return processState.getCode();
+ }
+ };
+ }
+
+ /**
* Get bytes received through stdin since last invocation of this method.
* <p>
* Not thread safe. It may miss some input if new content is written while
@@ -194,7 +253,7 @@ public class MockProcess extends Process {
}
}
}
- handle.ifPresent(MockProcessHandle::setTerminated);
+ setTerminated();
return exitCode;
}
@@ -213,7 +272,7 @@ public class MockProcess extends Process {
}
}
if (isTerminated()) {
- handle.ifPresent(MockProcessHandle::setTerminated);
+ setTerminated();
}
return isTerminated();
}
@@ -239,11 +298,12 @@ public class MockProcess extends Process {
* and before the mockup process goes in terminated state
*/
public void destroy(int delay) {
+ processState = ProcessState.DESTROYING;
synchronized (waitForTerminationLock) {
endTime = System.currentTimeMillis() + delay;
waitForTerminationLock.notifyAll();
if (delay <= 0) {
- handle.ifPresent(MockProcessHandle::setTerminated);
+ setTerminated();
}
}
}
@@ -333,4 +393,16 @@ public class MockProcess extends Process {
}
return (RuntimeProcess) DebugPlugin.newProcess(new Launch(launchConfiguration, ILaunchManager.RUN_MODE, null), this, name);
}
+
+ /**
+ * Move state machines to terminated.
+ */
+ private void setTerminated() {
+ synchronized (this) {
+ if (processState != ProcessState.TERMINATED) {
+ processState = ProcessState.LASTREAD;
+ }
+ }
+ handle.ifPresent(MockProcessHandle::setTerminated);
+ }
}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/OutputStreamMonitorTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/OutputStreamMonitorTests.java
index 0d361021f..523192ae2 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/OutputStreamMonitorTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/OutputStreamMonitorTests.java
@@ -195,9 +195,8 @@ public class OutputStreamMonitorTests extends AbstractDebugTest {
super(stream, charset);
}
- @Override
public void startMonitoring() {
- super.startMonitoring();
+ super.startMonitoring("");
}
@Override
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/RuntimeProcessTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/RuntimeProcessTests.java
index bbcca06ea..df9807334 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/RuntimeProcessTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/RuntimeProcessTests.java
@@ -21,17 +21,23 @@ import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertThrows;
import static org.junit.Assert.assertTrue;
+import java.io.InputStream;
+import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.concurrent.atomic.AtomicInteger;
+import org.eclipse.core.runtime.IStatus;
import org.eclipse.debug.core.DebugEvent;
import org.eclipse.debug.core.DebugException;
import org.eclipse.debug.core.DebugPlugin;
+import org.eclipse.debug.core.model.IProcess;
import org.eclipse.debug.core.model.RuntimeProcess;
import org.eclipse.debug.internal.core.DebugCoreMessages;
import org.eclipse.debug.tests.AbstractDebugTest;
import org.eclipse.debug.tests.TestUtil;
+import org.eclipse.debug.tests.sourcelookup.TestLaunch;
+import org.junit.Ignore;
import org.junit.Test;
public class RuntimeProcessTests extends AbstractDebugTest {
@@ -206,4 +212,34 @@ public class RuntimeProcessTests extends AbstractDebugTest {
DebugException timeoutException = assertThrows(DebugException.class, runtimeProcess::terminate);
assertThat(timeoutException.getMessage(), is(DebugCoreMessages.RuntimeProcess_terminate_failed));
}
+
+ /**
+ * See comment in MockProcess.MockProcess().new InputStream() {...}.read()
+ * for why this test fails
+ */
+ @Test
+ @Ignore("See https://bugs.eclipse.org/bugs/show_bug.cgi?id=577189")
+ public void testOutputAfterDestroy() throws Exception {
+ MockProcess proc = new MockProcess();
+
+ IProcess iProc = new RuntimeProcess(new TestLaunch(), proc, "foo", Collections.emptyMap());
+ iProc.terminate();
+
+ String str = iProc.getStreamsProxy().getOutputStreamMonitor().getContents();
+ TestUtil.log(IStatus.INFO, name.getMethodName(), "Stream result: ");
+ for (int i = 0; i < str.length(); i += 100) {
+ TestUtil.log(IStatus.INFO, name.getMethodName(), str.substring(i, Math.min(i + 100, str.length())));
+ }
+ TestUtil.log(IStatus.INFO, name.getMethodName(), "Stream done.");
+ // Make sure that the inputstream (process's stdout) has been fully read
+ // and is at EOF
+ @SuppressWarnings("resource")
+ InputStream inputStream = proc.getInputStream();
+ assertEquals(-1, inputStream.read());
+ // Make sure that the last character in the stream makes it through to
+ // the monitor
+ assertTrue(str.endsWith(String.valueOf((char) MockProcess.ProcessState.LASTREAD.getCode())));
+ }
+
+
}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/StreamsProxyTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/StreamsProxyTests.java
index 71569147a..571da15c6 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/StreamsProxyTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/console/StreamsProxyTests.java
@@ -66,7 +66,7 @@ public class StreamsProxyTests extends AbstractDebugTest {
final String s = prefix + String.join("", Collections.nCopies(numTwoByteCharacters, "\u00F8"));
final ByteArrayInputStream stdout = new ByteArrayInputStream(s.getBytes(StandardCharsets.UTF_8));
final Process mockProcess = new MockProcess(stdout, null, 0);
- final StreamsProxy streamProxy = new StreamsProxy(mockProcess, StandardCharsets.UTF_8);
+ final StreamsProxy streamProxy = new StreamsProxy(mockProcess, StandardCharsets.UTF_8, "");
streamProxy.close();
final String readContent = streamProxy.getOutputStreamMonitor().getContents();
assertEquals("Process output got corrupted.", s, readContent);
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/expressions/ExpressionManagerTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/expressions/ExpressionManagerTests.java
index 616325342..64eb0fe5b 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/expressions/ExpressionManagerTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/expressions/ExpressionManagerTests.java
@@ -37,7 +37,7 @@ import org.junit.Test;
*/
public class ExpressionManagerTests extends AbstractDebugTest {
- class SinlgeListener implements IExpressionListener {
+ static class SinlgeListener implements IExpressionListener {
List<IExpression> added = new ArrayList<>();
List<IExpression> removed = new ArrayList<>();
@@ -66,7 +66,7 @@ public class ExpressionManagerTests extends AbstractDebugTest {
}
- class MultiListener implements IExpressionsListener {
+ static class MultiListener implements IExpressionsListener {
List<IExpression> added = new ArrayList<>();
List<IExpression> removed = new ArrayList<>();
@@ -95,7 +95,7 @@ public class ExpressionManagerTests extends AbstractDebugTest {
}
- class InsertMoveListener extends MultiListener implements IExpressionsListener2 {
+ static class InsertMoveListener extends MultiListener implements IExpressionsListener2 {
List<IExpression> moved = new ArrayList<>();
List<IExpression> inserted = new ArrayList<>();
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/DebugFileStore.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/DebugFileStore.java
index 4928cf0c1..63a630b1c 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/DebugFileStore.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/DebugFileStore.java
@@ -158,13 +158,11 @@ public class DebugFileStore extends FileStore {
IFileStore parent = getParent();
if (parent.fetchInfo().exists()) {
DebugFileSystem.getDefault().setContents(toURI(), DebugFileSystem.DIRECTORY_BYTES);
+ } else if ((options & EFS.SHALLOW) > 0) {
+ throw new CoreException(new Status(IStatus.ERROR, "org.eclipse.jdt.debug.tests", //$NON-NLS-1$
+ "mkdir failed - parent does not exist: " + toURI())); //$NON-NLS-1$
} else {
- if ((options & EFS.SHALLOW) > 0) {
- throw new CoreException(new Status(IStatus.ERROR, "org.eclipse.jdt.debug.tests", //$NON-NLS-1$
- "mkdir failed - parent does not exist: " + toURI())); //$NON-NLS-1$
- } else {
- parent.mkdir(EFS.NONE, null);
- }
+ parent.mkdir(EFS.NONE, null);
}
}
return this;
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchConfigurationTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchConfigurationTests.java
index 4c5b200ac..26e101ca5 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchConfigurationTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchConfigurationTests.java
@@ -101,7 +101,7 @@ public class LaunchConfigurationTests extends AbstractLaunchTest implements ILau
* Class to hold resource description infos
* @since 3.9.0
*/
- class ResourceItem {
+ static class ResourceItem {
public ResourceItem(String path, Integer type) {
this.path = path;
this.type = type;
@@ -110,7 +110,7 @@ public class LaunchConfigurationTests extends AbstractLaunchTest implements ILau
Integer type;
}
- class Listener implements ILaunchConfigurationListener {
+ static class Listener implements ILaunchConfigurationListener {
private final List<ILaunchConfiguration> addedList = new ArrayList<>();
private final List<ILaunchConfiguration> removedList = new ArrayList<>();
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchManagerTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchManagerTests.java
index 3f6160db8..0b2bc0045 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchManagerTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/LaunchManagerTests.java
@@ -16,6 +16,7 @@ package org.eclipse.debug.tests.launching;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertThrows;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
@@ -29,6 +30,8 @@ import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
import org.eclipse.debug.core.ILaunchManager;
import org.eclipse.debug.internal.core.LaunchManager;
import org.eclipse.debug.tests.launching.CancellingLaunchDelegate.CancellingLaunch;
+import org.eclipse.debug.tests.launching.ThrowingLaunchDelegate.ThrowingEnum;
+import org.eclipse.debug.tests.launching.ThrowingLaunchDelegate.ThrowingLaunch;
import org.junit.Test;
/**
@@ -255,16 +258,17 @@ public class LaunchManagerTests extends AbstractLaunchTest {
}
/**
- * Checks if the expected number of cancelled launches appear in the manager
+ * Checks if the expected number of <i>type</i> launches appear in the
+ * manager
*
* @param count the expected count
- * @since 3.9.100
+ * @param type the type of launches to count
*/
- void hasCancellingLaunches(int count) {
+ private void hasLaunches(Class<?> type, int count) {
ILaunch[] launches = getLaunchManager().getLaunches();
int num = 0;
for (ILaunch launche : launches) {
- if (launche instanceof CancellingLaunch) {
+ if (type.isInstance(launche)) {
num++;
}
}
@@ -272,6 +276,16 @@ public class LaunchManagerTests extends AbstractLaunchTest {
}
/**
+ * Checks if the expected number of cancelled launches appear in the manager
+ *
+ * @param count the expected count
+ * @since 3.9.100
+ */
+ void hasCancellingLaunches(int count) {
+ hasLaunches(CancellingLaunch.class, count);
+ }
+
+ /**
* Tests if a launch is properly removed from the launch manager when
* #preLaunchCheck is cancelled
*
@@ -400,4 +414,96 @@ public class LaunchManagerTests extends AbstractLaunchTest {
}
}
}
+
+ /**
+ * Create a new configuration that will throw exception in one of the four
+ * launch delegate methods
+ *
+ * @param throwingEnum the method that should throw exception
+ * @return the new {@link ILaunchConfiguration}
+ */
+ private ILaunchConfiguration getThrowingConfiguration(ThrowingEnum throwingEnum) throws Exception {
+ ILaunchConfigurationType type = getLaunchManager().getLaunchConfigurationType("throwing.type"); //$NON-NLS-1$
+ if (type != null) {
+ ILaunchConfigurationWorkingCopy copy = type.newInstance(null, getLaunchManager().generateLaunchConfigurationName("throwing " + throwingEnum)); //$NON-NLS-1$
+ copy.setAttribute("throw.preLaunchCheck", ThrowingEnum.preLaunchCheck.equals(throwingEnum)); //$NON-NLS-1$
+ copy.setAttribute("throw.finalLaunchCheck", ThrowingEnum.finalLaunchCheck.equals(throwingEnum)); //$NON-NLS-1$
+ copy.setAttribute("throw.buildForLaunch", ThrowingEnum.buildForLaunch.equals(throwingEnum)); //$NON-NLS-1$
+ copy.setAttribute("throw.launch", ThrowingEnum.launch.equals(throwingEnum)); //$NON-NLS-1$
+ return copy.doSave();
+ }
+ return null;
+ }
+
+ /**
+ * Tests if a launch is properly removed from the launch manager when
+ * <i>throwingEnum</i> method throws exception
+ *
+ * @throws Exception
+ * @see https://bugs.eclipse.org/bugs/show_bug.cgi?id=578302
+ */
+ private void testThrowingLaunchDelegateMethod(ThrowingEnum throwingEnum) throws Exception {
+ ILaunchConfiguration config = getThrowingConfiguration(throwingEnum);
+ assertNotNull("The throwing config should have been created", config); //$NON-NLS-1$
+ try {
+ hasLaunches(ThrowingLaunch.class, 0);
+ CoreException exception = assertThrows(CoreException.class, () -> config.launch("run", new NullProgressMonitor(), true, true)); //$NON-NLS-1$
+ assertEquals("Wrong method throwed exception", exception.getMessage(), throwingEnum.toString());
+ hasLaunches(ThrowingLaunch.class, 0);
+ } finally {
+ ILaunch[] launches = getLaunchManager().getLaunches();
+ for (ILaunch launche : launches) {
+ getLaunchManager().removeLaunch(launche);
+ }
+ config.delete();
+ }
+ }
+
+ /**
+ * Tests if a launch is properly removed from the launch manager when
+ * #preLaunchCheck throws exception
+ *
+ * @throws Exception
+ * @see https://bugs.eclipse.org/bugs/show_bug.cgi?id=578302
+ */
+ @Test
+ public void testThrowingPreLaunchCheck() throws Exception {
+ testThrowingLaunchDelegateMethod(ThrowingEnum.preLaunchCheck);
+ }
+
+ /**
+ * Tests if a launch is properly removed from the launch manager when
+ * #finalLaunchCheck throws exception
+ *
+ * @throws Exception
+ * @see https://bugs.eclipse.org/bugs/show_bug.cgi?id=578302
+ */
+ @Test
+ public void testThrowingFinalLaunchCheck() throws Exception {
+ testThrowingLaunchDelegateMethod(ThrowingEnum.finalLaunchCheck);
+ }
+
+ /**
+ * Tests if a launch is properly removed from the launch manager when
+ * #buildFoLaunch throws exception
+ *
+ * @throws Exception
+ * @see https://bugs.eclipse.org/bugs/show_bug.cgi?id=578302
+ */
+ @Test
+ public void testThrowingBuildForLaunch() throws Exception {
+ testThrowingLaunchDelegateMethod(ThrowingEnum.buildForLaunch);
+ }
+
+ /**
+ * Tests if a launch is properly removed from the launch manager when
+ * #buildFoLaunch throws exception
+ *
+ * @throws Exception
+ * @see https://bugs.eclipse.org/bugs/show_bug.cgi?id=578302
+ */
+ @Test
+ public void testThrowingLaunch() throws Exception {
+ testThrowingLaunchDelegateMethod(ThrowingEnum.launch);
+ }
}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/RefreshTabTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/RefreshTabTests.java
index 0c2c14286..669bd0aae 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/RefreshTabTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/RefreshTabTests.java
@@ -27,6 +27,7 @@ import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.debug.core.RefreshUtil;
import org.eclipse.debug.internal.core.RefreshScopeComparator;
+import org.eclipse.debug.internal.core.sourcelookup.SourceLocatorMementoComparator;
import org.eclipse.debug.tests.TestsPlugin;
import org.eclipse.debug.ui.RefreshTab;
import org.eclipse.jface.viewers.ISelectionProvider;
@@ -180,11 +181,30 @@ public class RefreshTabTests extends AbstractLaunchTest {
*
* @throws CoreException
*/
+ @SuppressWarnings("restriction")
@Test
public void testRefreshScopeComparator() throws CoreException {
String oldStyle = "${working_set:<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<launchConfigurationWorkingSet factoryID=\"org.eclipse.ui.internal.WorkingSetFactory\" name=\"workingSet\" editPageId=\"org.eclipse.ui.resourceWorkingSetPage\">\n<item factoryID=\"org.eclipse.ui.internal.model.ResourceFactory\" path=\"/RefreshTabTests/some.file\" type=\"1\"/>\n</launchConfigurationWorkingSet>}"; //$NON-NLS-1$
String newStyle = "${working_set:<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<resources>\n<item path=\"/RefreshTabTests/some.file\" type=\"1\"/>\n</resources>}"; //$NON-NLS-1$
assertEquals("Comparator should return 0", 0, new RefreshScopeComparator().compare(oldStyle, newStyle)); //$NON-NLS-1$
+ String s1 = "${working_set:<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<resources>\n<item path=\"/RefreshTabTests/some.file1\" type=\"1\"/>\n</resources>}"; //$NON-NLS-1$
+ String s2 = "${working_set:<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<resources>\n<item path=\"/RefreshTabTests/some.file2\" type=\"1\"/>\n</resources>}"; //$NON-NLS-1$
+ assertEquals("Comparator should return 0", 0, new RefreshScopeComparator().compare(s1, s1)); //$NON-NLS-1$
+ assertEquals("Comparator should return 0", 0, new RefreshScopeComparator().compare(s2, s2)); //$NON-NLS-1$
+ assertEquals("Comparator should return -1", -1, new RefreshScopeComparator().compare(s1, s2)); //$NON-NLS-1$
+ assertEquals("Comparator should return 1", 1, new RefreshScopeComparator().compare(s2, s1)); //$NON-NLS-1$
+ assertEquals("Comparator should return 1", 1, new RefreshScopeComparator().compare(s1, null)); //$NON-NLS-1$
+ assertEquals("Comparator should return -1", -1, new RefreshScopeComparator().compare(null, s1)); //$NON-NLS-1$
+ assertEquals("Comparator should return 0", 0, new RefreshScopeComparator().compare(null, null)); //$NON-NLS-1$
+ String o1 = "${working_set:<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<launchConfigurationWorkingSet factoryID=\"org.eclipse.ui.internal.WorkingSetFactory\" name=\"workingSet\" editPageId=\"org.eclipse.ui.resourceWorkingSetPage\">\n<item factoryID=\"org.eclipse.ui.internal.model.ResourceFactory\" path=\"/RefreshTabTests/some.file1\" type=\"1\"/>\n</launchConfigurationWorkingSet>}"; //$NON-NLS-1$
+ String o2 = "${working_set:<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<launchConfigurationWorkingSet factoryID=\"org.eclipse.ui.internal.WorkingSetFactory\" name=\"workingSet\" editPageId=\"org.eclipse.ui.resourceWorkingSetPage\">\n<item factoryID=\"org.eclipse.ui.internal.model.ResourceFactory\" path=\"/RefreshTabTests/some.file2\" type=\"1\"/>\n</launchConfigurationWorkingSet>}"; //$NON-NLS-1$
+ assertEquals("Comparator should return 0", 0, new SourceLocatorMementoComparator().compare(o1, o1)); //$NON-NLS-1$
+ assertEquals("Comparator should return 0", 0, new SourceLocatorMementoComparator().compare(o2, o2)); //$NON-NLS-1$
+ assertEquals("Comparator should return -1", -1, new SourceLocatorMementoComparator().compare(o1, o2)); //$NON-NLS-1$
+ assertEquals("Comparator should return 1", 1, new SourceLocatorMementoComparator().compare(o2, o1)); //$NON-NLS-1$
+ assertEquals("Comparator should return 1", 1, new SourceLocatorMementoComparator().compare(o1, null)); //$NON-NLS-1$
+ assertEquals("Comparator should return -1", -1, new SourceLocatorMementoComparator().compare(null, o1)); //$NON-NLS-1$
+ assertEquals("Comparator should return 0", 0, new SourceLocatorMementoComparator().compare(null, null)); //$NON-NLS-1$
}
/**
@@ -197,6 +217,7 @@ public class RefreshTabTests extends AbstractLaunchTest {
IResource[] resources = new IResource[] { getProject(), getProject().getFile("not.exist"), getProject().getFile("some.file") }; //$NON-NLS-1$ //$NON-NLS-2$
String memento = RefreshUtil.toMemento(resources);
IResource[] restore = RefreshUtil.toResources(memento);
+ assertNotNull(resources);
assertEquals(resources.length, restore.length);
assertEquals(resources[0], restore[0]);
assertEquals(resources[1], restore[1]);
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/ThrowingLaunchDelegate.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/ThrowingLaunchDelegate.java
new file mode 100644
index 000000000..98cfd14c1
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/launching/ThrowingLaunchDelegate.java
@@ -0,0 +1,72 @@
+/*******************************************************************************
+ * Copyright (c) 2014 IBM Corporation and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.launching;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.debug.core.Launch;
+import org.eclipse.debug.core.model.ILaunchConfigurationDelegate2;
+import org.eclipse.debug.core.model.ISourceLocator;
+
+public class ThrowingLaunchDelegate implements ILaunchConfigurationDelegate2 {
+
+ class ThrowingLaunch extends Launch {
+ public ThrowingLaunch(ILaunchConfiguration launchConfiguration, String mode, ISourceLocator locator) {
+ super(launchConfiguration, mode, locator);
+ }
+ }
+
+ enum ThrowingEnum {
+ launch, buildForLaunch, finalLaunchCheck, preLaunchCheck;
+ }
+
+ @Override
+ public void launch(ILaunchConfiguration configuration, String mode, ILaunch launch, IProgressMonitor monitor) throws CoreException {
+ if (configuration.getAttribute("throw.launch", true)) { //$NON-NLS-1$
+ throw new CoreException(Status.error(ThrowingEnum.launch.toString()));
+ }
+ }
+
+ @Override
+ public ILaunch getLaunch(ILaunchConfiguration configuration, String mode) throws CoreException {
+ return new ThrowingLaunch(configuration, "run", null); //$NON-NLS-1$
+ }
+
+ @Override
+ public boolean buildForLaunch(ILaunchConfiguration configuration, String mode, IProgressMonitor monitor) throws CoreException {
+ if (configuration.getAttribute("throw.buildForLaunch", true)) { //$NON-NLS-1$
+ throw new CoreException(Status.error(ThrowingEnum.buildForLaunch.toString()));
+ }
+ return true;
+ }
+
+ @Override
+ public boolean finalLaunchCheck(ILaunchConfiguration configuration, String mode, IProgressMonitor monitor) throws CoreException {
+ if (configuration.getAttribute("throw.finalLaunchCheck", true)) { //$NON-NLS-1$
+ throw new CoreException(Status.error(ThrowingEnum.finalLaunchCheck.toString()));
+ }
+ return true;
+ }
+
+ @Override
+ public boolean preLaunchCheck(ILaunchConfiguration configuration, String mode, IProgressMonitor monitor) throws CoreException {
+ if (configuration.getAttribute("throw.preLaunchCheck", true)) { //$NON-NLS-1$
+ throw new CoreException(Status.error(ThrowingEnum.preLaunchCheck.toString()));
+ }
+ return true;
+ }
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/sourcelookup/SourceLookupFacilityTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/sourcelookup/SourceLookupFacilityTests.java
index fd963297b..8535bd4fa 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/sourcelookup/SourceLookupFacilityTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/sourcelookup/SourceLookupFacilityTests.java
@@ -21,8 +21,9 @@ import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import java.lang.reflect.Field;
-import java.util.HashMap;
+import java.util.IdentityHashMap;
import java.util.LinkedHashMap;
+import java.util.Map;
import org.eclipse.debug.core.model.IStackFrame;
import org.eclipse.debug.internal.ui.sourcelookup.SourceLookupFacility;
@@ -317,7 +318,7 @@ public class SourceLookupFacilityTests extends AbstractDebugTest {
// Get the original map
Field field = SourceLookupFacility.class.getDeclaredField("fLookupResults"); //$NON-NLS-1$
field.setAccessible(true);
- HashMap<?, ?> map = (HashMap<?, ?>) field.get(null);
+ Map<?, ?> map = (Map<?, ?>) field.get(SourceLookupFacility.getDefault());
LinkedHashMap<String, ISourceLookupResult> cached = new LinkedHashMap<>();
// fill the LRU with one element overflow
@@ -343,7 +344,7 @@ public class SourceLookupFacilityTests extends AbstractDebugTest {
String artifact = "" + 0; //$NON-NLS-1$
SourceLookupResult result = SourceLookupFacility.getDefault().lookup(artifact, fTestLocator, false);
assertNotNull("There should be a result", result); //$NON-NLS-1$
- assertFalse(cached.containsValue(result));
+ assertFalse(new IdentityHashMap<>(cached).containsValue(result));
// Check: the LRU map size should not grow
assertEquals(MAX_LRU_SIZE, map.size());
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor1.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor1.java
new file mode 100644
index 000000000..eb2a93f82
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor1.java
@@ -0,0 +1,32 @@
+/*******************************************************************************
+ * Copyright (c) 2021 Andrey Loskutov and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Andrey Loskutov (loskutov@gmx.de) - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.ui;
+
+import org.eclipse.debug.core.model.IVariable;
+import org.eclipse.debug.ui.actions.IVariableValueEditor;
+import org.eclipse.swt.widgets.Shell;
+
+public class TestVariableValueEditor1 implements IVariableValueEditor {
+
+ @Override
+ public boolean editVariable(IVariable variable, Shell shell) {
+ return false;
+ }
+
+ @Override
+ public boolean saveVariable(IVariable variable, String expression, Shell shell) {
+ return false;
+ }
+
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor2.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor2.java
new file mode 100644
index 000000000..658968f53
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor2.java
@@ -0,0 +1,32 @@
+/*******************************************************************************
+ * Copyright (c) 2021 Andrey Loskutov and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Andrey Loskutov (loskutov@gmx.de) - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.ui;
+
+import org.eclipse.debug.core.model.IVariable;
+import org.eclipse.debug.ui.actions.IVariableValueEditor;
+import org.eclipse.swt.widgets.Shell;
+
+public class TestVariableValueEditor2 implements IVariableValueEditor {
+
+ @Override
+ public boolean editVariable(IVariable variable, Shell shell) {
+ return false;
+ }
+
+ @Override
+ public boolean saveVariable(IVariable variable, String expression, Shell shell) {
+ return false;
+ }
+
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor3.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor3.java
new file mode 100644
index 000000000..09c9cfac6
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/TestVariableValueEditor3.java
@@ -0,0 +1,32 @@
+/*******************************************************************************
+ * Copyright (c) 2021 Andrey Loskutov and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Andrey Loskutov (loskutov@gmx.de) - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.ui;
+
+import org.eclipse.debug.core.model.IVariable;
+import org.eclipse.debug.ui.actions.IVariableValueEditor;
+import org.eclipse.swt.widgets.Shell;
+
+public class TestVariableValueEditor3 implements IVariableValueEditor {
+
+ @Override
+ public boolean editVariable(IVariable variable, Shell shell) {
+ return false;
+ }
+
+ @Override
+ public boolean saveVariable(IVariable variable, String expression, Shell shell) {
+ return false;
+ }
+
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/VariableValueEditorManagerTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/VariableValueEditorManagerTests.java
new file mode 100644
index 000000000..bbb07de01
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/ui/VariableValueEditorManagerTests.java
@@ -0,0 +1,36 @@
+/*******************************************************************************
+ * Copyright (c) 2021 Andrey Loskutov and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Andrey Loskutov (loskutov@gmx.de) - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.ui;
+
+import static org.junit.Assert.assertEquals;
+
+import org.eclipse.debug.internal.ui.VariableValueEditorManager;
+import org.eclipse.debug.tests.AbstractDebugTest;
+import org.eclipse.debug.ui.actions.IVariableValueEditor;
+import org.junit.Test;
+
+/**
+ * Tests status handlers
+ */
+public class VariableValueEditorManagerTests extends AbstractDebugTest {
+
+ @Test
+ public void testHighestPriorityEditorUsed() {
+ IVariableValueEditor editor = VariableValueEditorManager.getDefault().getVariableValueEditor("testModel");
+ assertEquals("Not the editor with highest priority used by VariableValueEditorManager", TestVariableValueEditor2.class, editor.getClass());
+ }
+
+
+
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTests.java
new file mode 100644
index 000000000..ce9c2b0db
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTests.java
@@ -0,0 +1,146 @@
+/*******************************************************************************
+ * Copyright (c) 2021 John Dallaway and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * John Dallaway - initial implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.view.memory;
+
+import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
+
+import java.math.BigInteger;
+import org.eclipse.debug.core.DebugException;
+import org.eclipse.debug.core.model.IMemoryBlockExtension;
+import org.eclipse.debug.core.model.MemoryByte;
+import org.eclipse.debug.internal.ui.views.memory.renderings.AbstractIntegerRendering;
+import org.eclipse.debug.internal.ui.views.memory.renderings.HexIntegerRendering;
+import org.eclipse.debug.internal.ui.views.memory.renderings.RenderingsUtil;
+import org.eclipse.debug.internal.ui.views.memory.renderings.SignedIntegerRendering;
+import org.eclipse.debug.internal.ui.views.memory.renderings.UnsignedIntegerRendering;
+import org.junit.Test;
+
+/**
+ * Tests for translation of memory bytes between in-memory representation and UI
+ * presentation
+ */
+@SuppressWarnings("restriction")
+public class TableRenderingTests {
+
+ private static final byte[] BYTES_1 = new byte[] { (byte) 0x87 };
+ private static final byte[] BYTES_2 = new byte[] { (byte) 0x98, (byte) 0x76 };
+ private static final byte[] BYTES_4 = new byte[] { (byte) 0xba, (byte) 0x98, (byte) 0x76, (byte) 0x54 };
+ private static final byte[] BYTES_8 = new byte[] {
+ (byte) 0xfe, (byte) 0xdc, (byte) 0xba, (byte) 0x98,
+ (byte) 0x76, (byte) 0x54, (byte) 0x32, (byte) 0x10 };
+ private static final byte[] BYTES_16 = new byte[16];
+ private static final byte[] BYTES_24 = new byte[24];
+
+ static {
+ BYTES_16[0] = (byte) 0x80; // 2 ^ 127
+ BYTES_24[0] = (byte) 0x80; // 2 ^ 191
+ }
+
+ @Test
+ public void testHexIntegerRendering() throws DebugException {
+ testIntegerRendering(createHexIntegerRendering(1), BYTES_1, "87", "87"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(1), BYTES_2, "9876", "7698"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(2), BYTES_2, "9876", "9876"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(1), BYTES_4, "BA987654", "547698BA"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(2), BYTES_4, "BA987654", "7654BA98"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(4), BYTES_4, "BA987654", "BA987654"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(1), BYTES_8, "FEDCBA9876543210", "1032547698BADCFE"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(4), BYTES_8, "FEDCBA9876543210", "76543210FEDCBA98"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(4), BYTES_16, "80000000000000000000000000000000", "00000000000000000000000080000000"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createHexIntegerRendering(4), BYTES_24, "800000000000000000000000000000000000000000000000", "000000000000000000000000000000000000000080000000"); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ @Test
+ public void testSignedIntegerRendering() throws DebugException {
+ testIntegerRendering(createSignedIntegerRendering(1, BYTES_1.length), BYTES_1, "-121", "-121"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(1, BYTES_2.length), BYTES_2, "-26506", "30360"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(2, BYTES_2.length), BYTES_2, "-26506", "-26506"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(1, BYTES_4.length), BYTES_4, "-1164413356", "1417058490"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(2, BYTES_4.length), BYTES_4, "-1164413356", "1985264280"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(4, BYTES_4.length), BYTES_4, "-1164413356", "-1164413356"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(1, BYTES_8.length), BYTES_8, "-81985529216486896", "1167088121787636990"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(4, BYTES_8.length), BYTES_8, "-81985529216486896", "8526495043095935640"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(8, BYTES_8.length), BYTES_8, "-81985529216486896", "-81985529216486896"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createSignedIntegerRendering(2, BYTES_16.length), BYTES_16, BigInteger.valueOf(2).pow(127).negate().toString(), "32768"); //$NON-NLS-1$
+ testIntegerRendering(createSignedIntegerRendering(2, BYTES_24.length), BYTES_24, BigInteger.valueOf(2).pow(191).negate().toString(), "32768"); //$NON-NLS-1$
+ }
+
+ @Test
+ public void testUnsignedIntegerRendering() throws DebugException {
+ testIntegerRendering(createUnsignedIntegerRendering(1, BYTES_1.length), BYTES_1, "135", "135"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(1, BYTES_2.length), BYTES_2, "39030", "30360"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(2, BYTES_2.length), BYTES_2, "39030", "39030"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(1, BYTES_4.length), BYTES_4, "3130553940", "1417058490"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(2, BYTES_4.length), BYTES_4, "3130553940", "1985264280"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(4, BYTES_4.length), BYTES_4, "3130553940", "3130553940"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(1, BYTES_8.length), BYTES_8, "18364758544493064720", "1167088121787636990"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(4, BYTES_8.length), BYTES_8, "18364758544493064720", "8526495043095935640"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(8, BYTES_8.length), BYTES_8, "18364758544493064720", "18364758544493064720"); //$NON-NLS-1$ //$NON-NLS-2$
+ testIntegerRendering(createUnsignedIntegerRendering(2, BYTES_16.length), BYTES_16, BigInteger.valueOf(2).pow(127).toString(), "32768"); //$NON-NLS-1$
+ testIntegerRendering(createUnsignedIntegerRendering(2, BYTES_24.length), BYTES_24, BigInteger.valueOf(2).pow(191).toString(), "32768"); //$NON-NLS-1$
+ }
+
+ private void testIntegerRendering(AbstractIntegerRendering rendering, byte[] bytes, String bigEndianString, String littleEndianString) throws DebugException {
+ final IMemoryBlockExtension block = new TableRenderingTestsMemoryBlock(bytes, rendering.getAddressableSize());
+ rendering.init(null, block);
+ final MemoryByte[] memoryBytes = block.getBytesFromOffset(BigInteger.ZERO, bytes.length / rendering.getAddressableSize());
+
+ rendering.setDisplayEndianess(RenderingsUtil.BIG_ENDIAN);
+ assertEquals(bigEndianString, rendering.getString(null, null, memoryBytes));
+ assertArrayEquals(bytes, rendering.getBytes(null, null, memoryBytes, bigEndianString));
+
+ rendering.setDisplayEndianess(RenderingsUtil.LITTLE_ENDIAN);
+ assertEquals(littleEndianString, rendering.getString(null, null, memoryBytes));
+ assertArrayEquals(bytes, rendering.getBytes(null, null, memoryBytes, littleEndianString));
+ }
+
+ private HexIntegerRendering createHexIntegerRendering(int addressableSize) {
+ return new HexIntegerRendering(null) {
+ @Override
+ public int getAddressableSize() {
+ return addressableSize;
+ }
+ };
+ }
+
+ private SignedIntegerRendering createSignedIntegerRendering(int addressableSize, int bytesPerColumn) {
+ return new SignedIntegerRendering(null) {
+ @Override
+ public int getAddressableSize() {
+ return addressableSize;
+ }
+
+ @Override
+ public int getBytesPerColumn() {
+ return bytesPerColumn;
+ }
+ };
+ }
+
+ private UnsignedIntegerRendering createUnsignedIntegerRendering(int addressableSize, int bytesPerColumn) {
+ return new UnsignedIntegerRendering(null) {
+ @Override
+ public int getAddressableSize() {
+ return addressableSize;
+ }
+
+ @Override
+ public int getBytesPerColumn() {
+ return bytesPerColumn;
+ }
+ };
+ }
+
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTestsMemoryBlock.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTestsMemoryBlock.java
new file mode 100644
index 000000000..28b125be5
--- /dev/null
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/view/memory/TableRenderingTestsMemoryBlock.java
@@ -0,0 +1,173 @@
+/*******************************************************************************
+ * Copyright (c) 2021 John Dallaway and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * John Dallaway - initial implementation
+ *******************************************************************************/
+package org.eclipse.debug.tests.view.memory;
+
+import java.math.BigInteger;
+
+import org.eclipse.debug.core.DebugException;
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.model.IDebugTarget;
+import org.eclipse.debug.core.model.IMemoryBlockExtension;
+import org.eclipse.debug.core.model.IMemoryBlockRetrieval;
+import org.eclipse.debug.core.model.MemoryByte;
+
+/**
+ * Minimal memory block implementation for use with
+ * {@link org.eclipse.debug.tests.view.memory.TableRenderingTests} only
+ */
+public class TableRenderingTestsMemoryBlock implements IMemoryBlockExtension {
+
+ private int fAddressableSize;
+ private byte[] fBytes;
+
+ public TableRenderingTestsMemoryBlock(byte[] bytes, int addressableSize) {
+ fBytes = bytes;
+ fAddressableSize = addressableSize;
+ }
+
+ @Override
+ public long getStartAddress() {
+ return 0;
+ }
+
+ @Override
+ public long getLength() {
+ return fBytes.length;
+ }
+
+ @Override
+ public byte[] getBytes() throws DebugException {
+ return fBytes;
+ }
+
+ @Override
+ public boolean supportsValueModification() {
+ return false;
+ }
+
+ @Override
+ public void setValue(long offset, byte[] bytes) throws DebugException {
+ }
+
+ @Override
+ public String getModelIdentifier() {
+ return null;
+ }
+
+ @Override
+ public IDebugTarget getDebugTarget() {
+ return null;
+ }
+
+ @Override
+ public ILaunch getLaunch() {
+ return null;
+ }
+
+ @Override
+ public <T> T getAdapter(Class<T> adapter) {
+ return null;
+ }
+
+ @Override
+ public String getExpression() {
+ return null;
+ }
+
+ @Override
+ public BigInteger getBigBaseAddress() throws DebugException {
+ return null;
+ }
+
+ @Override
+ public BigInteger getMemoryBlockStartAddress() throws DebugException {
+ return null;
+ }
+
+ @Override
+ public BigInteger getMemoryBlockEndAddress() throws DebugException {
+ return null;
+ }
+
+ @Override
+ public BigInteger getBigLength() throws DebugException {
+ return null;
+ }
+
+ @Override
+ public int getAddressSize() throws DebugException {
+ return 0;
+ }
+
+ @Override
+ public boolean supportBaseAddressModification() throws DebugException {
+ return false;
+ }
+
+ @Override
+ public boolean supportsChangeManagement() {
+ return false;
+ }
+
+ @Override
+ public void setBaseAddress(BigInteger address) throws DebugException {
+ }
+
+ @Override
+ public MemoryByte[] getBytesFromOffset(BigInteger unitOffset, long addressableUnits) throws DebugException {
+ assert BigInteger.ZERO.equals(unitOffset);
+ final MemoryByte[] memoryBytes = new MemoryByte[(int) (addressableUnits * getAddressableSize())];
+ for (int n = 0; n < memoryBytes.length; n++) {
+ memoryBytes[n] = new MemoryByte(fBytes[n]);
+ }
+ return memoryBytes;
+ }
+
+ @Override
+ public MemoryByte[] getBytesFromAddress(BigInteger address, long units) throws DebugException {
+ return null;
+ }
+
+ @Override
+ public void setValue(BigInteger offset, byte[] bytes) throws DebugException {
+ }
+
+ @Override
+ public void connect(Object client) {
+ }
+
+ @Override
+ public void disconnect(Object client) {
+ }
+
+ @Override
+ public Object[] getConnections() {
+ return null;
+ }
+
+ @Override
+ public void dispose() throws DebugException {
+ }
+
+ @Override
+ public IMemoryBlockRetrieval getMemoryBlockRetrieval() {
+ return null;
+ }
+
+ @Override
+ public int getAddressableSize() throws DebugException {
+ return fAddressableSize;
+ }
+
+}
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ColumnPresentationTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ColumnPresentationTests.java
index 7654bf633..1ac5939dc 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ColumnPresentationTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ColumnPresentationTests.java
@@ -213,7 +213,7 @@ public class ColumnPresentationTests extends AbstractDebugTest implements ITestM
}
}
- class MyModel extends TestModel implements IColumnPresentationFactory {
+ static class MyModel extends TestModel implements IColumnPresentationFactory {
MyColumnPresentation colPresenation;
MyModel(MyColumnPresentation cp1) {
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ContentTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ContentTests.java
index 0c844d458..0bd96f04f 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ContentTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/ContentTests.java
@@ -95,7 +95,7 @@ abstract public class ContentTests extends AbstractViewerModelTest implements IT
* Modified test model that optionally captures (i.e. doesn't compete)
* udpates after filling in their data.
*/
- class TestModelWithCapturedUpdates extends TestModel {
+ static class TestModelWithCapturedUpdates extends TestModel {
boolean fCaptureLabelUpdates = false;
boolean fCaptureChildrenUpdates = false;
diff --git a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/FilterTests.java b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/FilterTests.java
index 1f003ab74..d4347804f 100644
--- a/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/FilterTests.java
+++ b/org.eclipse.debug.tests/src/org/eclipse/debug/tests/viewer/model/FilterTests.java
@@ -49,7 +49,7 @@ abstract public class FilterTests extends AbstractViewerModelTest implements ITe
return fViewer;
}
- class TestViewerFilter extends ViewerFilter {
+ static class TestViewerFilter extends ViewerFilter {
Pattern fPattern;
TestViewerFilter(String pattern) {
@@ -68,7 +68,7 @@ abstract public class FilterTests extends AbstractViewerModelTest implements ITe
}
}
- class TestTMVFilter extends TreeModelViewerFilter {
+ static class TestTMVFilter extends TreeModelViewerFilter {
Pattern fPattern;
Object fParentElement;
TestTMVFilter(String pattern, Object parentElement) {
diff --git a/org.eclipse.debug.ui.launchview.tests/.classpath b/org.eclipse.debug.ui.launchview.tests/.classpath
new file mode 100644
index 000000000..4a00becd8
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.classpath
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11">
+ <attributes>
+ <attribute name="module" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/org.eclipse.debug.ui.launchview.tests/.project b/org.eclipse.debug.ui.launchview.tests/.project
new file mode 100644
index 000000000..fe1510248
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.project
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.debug.ui.launchview.tests</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644
index 000000000..99f26c020
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.resources.prefs
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644
index 000000000..5a0ad22d2
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.core.runtime.prefs
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 000000000..c15cc50fd
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,421 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.builder.cleanOutputFolder=clean
+org.eclipse.jdt.core.builder.duplicateResourceTask=warning
+org.eclipse.jdt.core.builder.invalidClasspath=abort
+org.eclipse.jdt.core.builder.recreateModifiedClassFileInOutputFolder=ignore
+org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch
+org.eclipse.jdt.core.circularClasspath=error
+org.eclipse.jdt.core.classpath.exclusionPatterns=enabled
+org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled
+org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnull.secondary=
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary=
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=11
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.maxProblemPerUnit=100
+org.eclipse.jdt.core.compiler.problem.APILeak=warning
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
+org.eclipse.jdt.core.compiler.problem.deadCode=warning
+org.eclipse.jdt.core.compiler.problem.deprecation=warning
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=ignore
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=ignore
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=ignore
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=private
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=enabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=enabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=private
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=warning
+org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warning
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.terminalDeprecation=warning
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=warning
+org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=disabled
+org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=info
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unsafeTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
+org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=warning
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
+org.eclipse.jdt.core.compiler.source=11
+org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
+org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
+org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=0
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=true
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=true
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=true
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=80
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=tab
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
+org.eclipse.jdt.core.incompatibleJDKLevel=ignore
+org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644
index 000000000..4a66042a4
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.jdt.ui.prefs
@@ -0,0 +1,115 @@
+cleanup.add_default_serial_version_id=true
+cleanup.add_generated_serial_version_id=false
+cleanup.add_missing_annotations=true
+cleanup.add_missing_deprecated_annotations=true
+cleanup.add_missing_methods=false
+cleanup.add_missing_nls_tags=false
+cleanup.add_missing_override_annotations=true
+cleanup.add_missing_override_annotations_interface_methods=true
+cleanup.add_serial_version_id=false
+cleanup.always_use_blocks=true
+cleanup.always_use_parentheses_in_expressions=false
+cleanup.always_use_this_for_non_static_field_access=false
+cleanup.always_use_this_for_non_static_method_access=false
+cleanup.convert_to_enhanced_for_loop=false
+cleanup.correct_indentation=false
+cleanup.format_source_code=true
+cleanup.format_source_code_changes_only=false
+cleanup.make_local_variable_final=true
+cleanup.make_parameters_final=false
+cleanup.make_private_fields_final=true
+cleanup.make_type_abstract_if_missing_method=false
+cleanup.make_variable_declarations_final=false
+cleanup.never_use_blocks=false
+cleanup.never_use_parentheses_in_expressions=true
+cleanup.organize_imports=true
+cleanup.qualify_static_field_accesses_with_declaring_class=false
+cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+cleanup.qualify_static_member_accesses_with_declaring_class=true
+cleanup.qualify_static_method_accesses_with_declaring_class=false
+cleanup.remove_private_constructors=true
+cleanup.remove_trailing_whitespaces=true
+cleanup.remove_trailing_whitespaces_all=true
+cleanup.remove_trailing_whitespaces_ignore_empty=false
+cleanup.remove_unnecessary_casts=true
+cleanup.remove_unnecessary_nls_tags=true
+cleanup.remove_unused_imports=true
+cleanup.remove_unused_local_variables=false
+cleanup.remove_unused_private_fields=true
+cleanup.remove_unused_private_members=false
+cleanup.remove_unused_private_methods=true
+cleanup.remove_unused_private_types=true
+cleanup.sort_members=false
+cleanup.sort_members_all=false
+cleanup.use_blocks=true
+cleanup.use_blocks_only_for_return_and_throw=false
+cleanup.use_parentheses_in_expressions=false
+cleanup.use_this_for_non_static_field_access=false
+cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+cleanup.use_this_for_non_static_method_access=false
+cleanup.use_this_for_non_static_method_access_only_if_necessary=true
+cleanup_profile=_Platform Debug Cleanups
+cleanup_settings_version=2
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_Platform Debug Formatting
+formatter_settings_version=12
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=true
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_functional_interfaces=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=true
+sp_cleanup.format_source_code_changes_only=true
+sp_cleanup.insert_inferred_type_arguments=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_redundant_type_arguments=false
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=true
+sp_cleanup.remove_unnecessary_nls_tags=true
+sp_cleanup.remove_unused_imports=true
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_anonymous_class_creation=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_lambda=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
+sp_cleanup.use_type_arguments=false
diff --git a/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.pde.prefs
new file mode 100644
index 000000000..d06e3abc7
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/.settings/org.eclipse.pde.prefs
@@ -0,0 +1,39 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=1
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=2
+compilers.p.discouraged-class=1
+compilers.p.exec-env-too-low=1
+compilers.p.illegal-att-value=0
+compilers.p.internal=1
+compilers.p.matching-pom-version=0
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.no.automatic.module=1
+compilers.p.not-externalized-att=0
+compilers.p.service.component.without.lazyactivation=1
+compilers.p.unknown-attribute=0
+compilers.p.unknown-class=1
+compilers.p.unknown-element=2
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=0
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.p.unused-element-or-attribute=1
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+compilers.use-project=true
+eclipse.preferences.version=1
diff --git a/org.eclipse.debug.ui.launchview.tests/META-INF/MANIFEST.MF b/org.eclipse.debug.ui.launchview.tests/META-INF/MANIFEST.MF
new file mode 100644
index 000000000..8f8d22a55
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/META-INF/MANIFEST.MF
@@ -0,0 +1,20 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %pluginName
+Bundle-SymbolicName: org.eclipse.debug.ui.launchview.tests;singleton:=true
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.eclipse.debug.ui.launchview.tests.TestsPlugin
+Bundle-Localization: plugin
+Require-Bundle: org.eclipse.ui;bundle-version="[3.6.0,4.0.0)",
+ org.eclipse.core.runtime;bundle-version="[3.11.0,4.0.0)",
+ org.eclipse.debug.ui;bundle-version="[3.10.0,4.0.0)",
+ org.eclipse.debug.ui.launchview;bundle-version="[1.0.2,2.0.0)",
+ org.junit,
+ org.eclipse.test.performance;bundle-version="3.6.0",
+ org.eclipse.core.resources;bundle-version="[3.5.0,4.0.0)",
+ org.eclipse.debug.core;bundle-version="[3.9.0,4.0.0)"
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-11
+Bundle-Vendor: %providerName
+Eclipse-BundleShape: dir
+Automatic-Module-Name: org.eclipse.debug.ui.launchview.tests
diff --git a/org.eclipse.debug.ui.launchview.tests/Platform Debug UI LaunchView Test Suite.launch b/org.eclipse.debug.ui.launchview.tests/Platform Debug UI LaunchView Test Suite.launch
new file mode 100644
index 000000000..c972093c2
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/Platform Debug UI LaunchView Test Suite.launch
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.pde.ui.JunitLaunchConfig">
+ <booleanAttribute key="append.args" value="true"/>
+ <booleanAttribute key="askclear" value="false"/>
+ <booleanAttribute key="automaticAdd" value="true"/>
+ <booleanAttribute key="automaticValidate" value="false"/>
+ <stringAttribute key="bootstrap" value=""/>
+ <stringAttribute key="checked" value="[NONE]"/>
+ <booleanAttribute key="clearConfig" value="true"/>
+ <booleanAttribute key="clearws" value="true"/>
+ <booleanAttribute key="clearwslog" value="false"/>
+ <stringAttribute key="configLocation" value="${workspace_loc}/.metadata/.plugins/org.eclipse.pde.core/pde-junit"/>
+ <booleanAttribute key="default" value="true"/>
+ <booleanAttribute key="includeOptional" value="true"/>
+ <stringAttribute key="location" value="${workspace_loc}/../debug-junit-workspace"/>
+ <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
+ <listEntry value="/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AutomatedSuite.java"/>
+ </listAttribute>
+ <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
+ <listEntry value="1"/>
+ </listAttribute>
+ <stringAttribute key="org.eclipse.jdt.junit.CONTAINER" value=""/>
+ <booleanAttribute key="org.eclipse.jdt.junit.KEEPRUNNING_ATTR" value="false"/>
+ <stringAttribute key="org.eclipse.jdt.junit.TESTNAME" value=""/>
+ <stringAttribute key="org.eclipse.jdt.junit.TEST_KIND" value="org.eclipse.jdt.junit.loader.junit4"/>
+ <stringAttribute key="org.eclipse.jdt.launching.JRE_CONTAINER" value="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
+ <stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.debug.ui.launchview.tests.AutomatedSuite"/>
+ <stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-os ${target.os} -ws ${target.ws} -arch ${target.arch} -nl ${target.nl} -consoleLog"/>
+ <stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.eclipse.debug.ui.launchview.tests"/>
+ <stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.pde.ui.workbenchClasspathProvider"/>
+ <stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Xms40m -Xmx384m"/>
+ <stringAttribute key="pde.version" value="3.3"/>
+ <stringAttribute key="product" value="org.eclipse.sdk.ide"/>
+ <booleanAttribute key="run_in_ui_thread" value="true"/>
+ <booleanAttribute key="show_selected_only" value="false"/>
+ <booleanAttribute key="tracing" value="false"/>
+ <booleanAttribute key="useCustomFeatures" value="false"/>
+ <booleanAttribute key="useDefaultConfig" value="true"/>
+ <booleanAttribute key="useDefaultConfigArea" value="false"/>
+ <booleanAttribute key="useProduct" value="true"/>
+</launchConfiguration>
diff --git a/org.eclipse.debug.ui.launchview.tests/about.html b/org.eclipse.debug.ui.launchview.tests/about.html
new file mode 100644
index 000000000..164f781a8
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/about.html
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
+<title>About</title>
+</head>
+<body lang="EN-US">
+ <h2>About This Content</h2>
+
+ <p>November 30, 2017</p>
+ <h3>License</h3>
+
+ <p>
+ The Eclipse Foundation makes available all content in this plug-in
+ (&quot;Content&quot;). Unless otherwise indicated below, the Content
+ is provided to you under the terms and conditions of the Eclipse
+ Public License Version 2.0 (&quot;EPL&quot;). A copy of the EPL is
+ available at <a href="http://www.eclipse.org/legal/epl-2.0">http://www.eclipse.org/legal/epl-2.0</a>.
+ For purposes of the EPL, &quot;Program&quot; will mean the Content.
+ </p>
+
+ <p>
+ If you did not receive this Content directly from the Eclipse
+ Foundation, the Content is being redistributed by another party
+ (&quot;Redistributor&quot;) and different terms and conditions may
+ apply to your use of any object code in the Content. Check the
+ Redistributor's license that was provided with the Content. If no such
+ license exists, contact the Redistributor. Unless otherwise indicated
+ below, the terms and conditions of the EPL still apply to any source
+ code in the Content and such source code may be obtained at <a
+ href="http://www.eclipse.org/">http://www.eclipse.org</a>.
+ </p>
+
+</body>
+</html> \ No newline at end of file
diff --git a/org.eclipse.debug.ui.launchview.tests/build.properties b/org.eclipse.debug.ui.launchview.tests/build.properties
new file mode 100644
index 000000000..0cd83c4b0
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/build.properties
@@ -0,0 +1,22 @@
+###############################################################################
+# Copyright (c) 2009, 2012 IBM Corporation and others.
+#
+# This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License 2.0
+# which accompanies this distribution, and is available at
+# https://www.eclipse.org/legal/epl-2.0/
+#
+# SPDX-License-Identifier: EPL-2.0
+#
+# Contributors:
+# IBM Corporation - initial API and implementation
+###############################################################################
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+ .,\
+ test.xml,\
+ about.html,\
+ plugin.properties,\
+ plugin.xml
+
diff --git a/org.eclipse.debug.ui.launchview.tests/forceQualifierUpdate.txt b/org.eclipse.debug.ui.launchview.tests/forceQualifierUpdate.txt
new file mode 100644
index 000000000..350632caa
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/forceQualifierUpdate.txt
@@ -0,0 +1 @@
+# To force a version qualifier update, add the bug here
diff --git a/org.eclipse.debug.ui.launchview.tests/plugin.properties b/org.eclipse.debug.ui.launchview.tests/plugin.properties
new file mode 100755
index 000000000..454cf7829
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/plugin.properties
@@ -0,0 +1,17 @@
+###############################################################################
+# Copyright (c) 2009, 2012 IBM Corporation and others.
+#
+# This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License 2.0
+# which accompanies this distribution, and is available at
+# https://www.eclipse.org/legal/epl-2.0/
+#
+# SPDX-License-Identifier: EPL-2.0
+#
+# Contributors:
+# IBM Corporation - Initial implementation
+###############################################################################
+
+pluginName=Debug UI (LaunchView) Test Plugin
+providerName=Eclipse.org
+
diff --git a/org.eclipse.debug.ui.launchview.tests/plugin.xml b/org.eclipse.debug.ui.launchview.tests/plugin.xml
new file mode 100644
index 000000000..0e25070a3
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/plugin.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<!--
+ Copyright (c) 2009, 2020 IBM Corporation and others.
+
+ This program and the accompanying materials
+ are made available under the terms of the Eclipse Public License 2.0
+ which accompanies this distribution, and is available at
+ https://www.eclipse.org/legal/epl-2.0/
+
+ SPDX-License-Identifier: EPL-2.0
+
+ Contributors:
+ IBM Corporation - initial API and implementation
+ -->
+
+<plugin>
+
+</plugin>
diff --git a/org.eclipse.debug.ui.launchview.tests/pom.xml b/org.eclipse.debug.ui.launchview.tests/pom.xml
new file mode 100644
index 000000000..cb9b8da66
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/pom.xml
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (c) 2012, 2021 Eclipse Foundation and others.
+ All rights reserved. This program and the accompanying materials
+ are made available under the terms of the Eclipse Distribution License v1.0
+ which accompanies this distribution, and is available at
+ http://www.eclipse.org/org/documents/edl-v10.php
+
+ Contributors:
+ Igor Fedorenko - initial implementation
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <artifactId>eclipse.platform.debug</artifactId>
+ <groupId>eclipse.platform.debug</groupId>
+ <version>4.24.0-SNAPSHOT</version>
+ </parent>
+ <groupId>org.eclipse.debug</groupId>
+ <artifactId>org.eclipse.debug.ui.launchview.tests</artifactId>
+ <version>1.0.0-SNAPSHOT</version>
+ <packaging>eclipse-test-plugin</packaging>
+ <properties>
+ <skipAPIAnalysis>true</skipAPIAnalysis>
+ <code.ignoredWarnings>${tests.ignoredWarnings}</code.ignoredWarnings>
+ <testSuite>${project.artifactId}</testSuite>
+ <testClass>org.eclipse.debug.ui.launchview.tests.AutomatedSuite</testClass>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.eclipse.tycho</groupId>
+ <artifactId>tycho-surefire-plugin</artifactId>
+ <version>${tycho.version}</version>
+ <configuration>
+ <useUIHarness>true</useUIHarness>
+ <useUIThread>true</useUIThread>
+ <dependencies>
+ <dependency>
+ <!-- workaround for missing dependency in org.eclipse.e4.ui.services: https://bugs.eclipse.org/462862 -->
+ <type>eclipse-plugin</type>
+ <artifactId>org.eclipse.equinox.event</artifactId>
+ <version>0.0.0</version>
+ </dependency>
+ </dependencies>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
diff --git a/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AbstractLaunchViewTest.java b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AbstractLaunchViewTest.java
new file mode 100644
index 000000000..ac89b3e5e
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AbstractLaunchViewTest.java
@@ -0,0 +1,169 @@
+/*******************************************************************************
+ * Copyright (c) 2017 Andrey Loskutov and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Andrey Loskutov <loskutov@gmx.de> - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.tests;
+
+import java.util.function.Function;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.jface.preference.PreferenceMemento;
+import org.eclipse.swt.widgets.Display;
+import org.eclipse.ui.IWorkbench;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.intro.IIntroManager;
+import org.eclipse.ui.intro.IIntroPart;
+import org.eclipse.ui.progress.UIJob;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Rule;
+import org.junit.rules.TestName;
+
+public class AbstractLaunchViewTest {
+
+ private static boolean welcomeClosed;
+
+ /**
+ * Default timeout in milliseconds to wait on some events
+ */
+ protected long testTimeout = 30000;
+
+ /**
+ * Preference helper to restore changed preference values after test run.
+ */
+ private final PreferenceMemento prefMemento = new PreferenceMemento();
+
+ @Rule
+ public TestName name = new TestName();
+
+
+ @Before
+ public void setUp() throws Exception {
+ TestUtil.log(IStatus.INFO, name.getMethodName(), "setUp");
+ assertWelcomeScreenClosed();
+ }
+
+ @After
+ public void tearDown() throws Exception {
+ TestUtil.log(IStatus.INFO, name.getMethodName(), "tearDown");
+ TestUtil.cleanUp(name.getMethodName());
+ prefMemento.resetPreferences();
+ }
+
+ /**
+ * Ensure the welcome screen is closed because in 4.x the debug perspective
+ * opens a giant fast-view causing issues
+ *
+ * @throws Exception
+ */
+ protected final void assertWelcomeScreenClosed() throws Exception {
+ if (!welcomeClosed && PlatformUI.isWorkbenchRunning()) {
+ final IWorkbench wb = PlatformUI.getWorkbench();
+ if (wb == null) {
+ return;
+ }
+ // In UI thread we don't need to run a job
+ if (Display.getCurrent() != null) {
+ closeIntro(wb);
+ return;
+ }
+
+ UIJob job = new UIJob("close welcome screen for debug test suite") {
+ @Override
+ public IStatus runInUIThread(IProgressMonitor monitor) {
+ closeIntro(wb);
+ return Status.OK_STATUS;
+ }
+
+ };
+ job.setPriority(Job.INTERACTIVE);
+ job.setSystem(true);
+ job.schedule();
+ }
+ }
+
+ /**
+ * Waits while given condition is {@code true} for a given amount of
+ * milliseconds. If the actual wait time exceeds given timeout and condition
+ * will be still {@code true}, throws {@link AssertionFailedError} with
+ * given message.
+ * <p>
+ * Will process UI events while waiting in UI thread, if called from
+ * background thread, just waits.
+ *
+ * @param condition function which will be evaluated while waiting
+ * @param timeout max wait time in milliseconds to wait on given condition
+ * @param errorMessage message which will be used to construct the failure
+ * exception in case the condition will still return {@code true}
+ * after given timeout
+ */
+ public void waitWhile(Function<AbstractLaunchViewTest, Boolean> condition, long timeout, Function<AbstractLaunchViewTest, String> errorMessage) throws Exception {
+ TestUtil.waitWhile(condition, this, timeout, errorMessage);
+ }
+
+ /**
+ * Waits while given condition is {@code true} for some time. If the actual
+ * wait time exceeds {@link #testTimeout} and condition will be still
+ * {@code true}, throws {@link AssertionFailedError} with given message.
+ * <p>
+ * Will process UI events while waiting in UI thread, if called from
+ * background thread, just waits.
+ *
+ * @param condition function which will be evaluated while waiting
+ * @param errorMessage message which will be used to construct the failure
+ * exception in case the condition will still return {@code true}
+ * after given timeout
+ */
+ public void waitWhile(Function<AbstractLaunchViewTest, Boolean> condition, Function<AbstractLaunchViewTest, String> errorMessage) throws Exception {
+ TestUtil.waitWhile(condition, this, testTimeout, errorMessage);
+ }
+
+ private static void closeIntro(final IWorkbench wb) {
+ IWorkbenchWindow window = wb.getActiveWorkbenchWindow();
+ if (window != null) {
+ IIntroManager im = wb.getIntroManager();
+ IIntroPart intro = im.getIntro();
+ if (intro != null) {
+ welcomeClosed = im.closeIntro(intro);
+ }
+ }
+ }
+
+ /**
+ * Change a preference value for this test run. The preference will be reset
+ * to its value before test started automatically on {@link #tearDown()}.
+ *
+ * @param <T> preference value type. The type must have a corresponding
+ * {@link IPreferenceStore} setter.
+ * @param store preference store to manipulate (must not be
+ * <code>null</code>)
+ * @param name preference to change
+ * @param value new preference value
+ * @throws IllegalArgumentException when setting a type which is not
+ * supported by {@link IPreferenceStore}
+ *
+ * @see IPreferenceStore#setValue(String, double)
+ * @see IPreferenceStore#setValue(String, float)
+ * @see IPreferenceStore#setValue(String, int)
+ * @see IPreferenceStore#setValue(String, long)
+ * @see IPreferenceStore#setValue(String, boolean)
+ * @see IPreferenceStore#setValue(String, String)
+ */
+ protected <T> void setPreference(IPreferenceStore store, String name, T value) {
+ prefMemento.setValue(store, name, value);
+ }
+}
diff --git a/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AutomatedSuite.java b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AutomatedSuite.java
new file mode 100644
index 000000000..b381ac8fe
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/AutomatedSuite.java
@@ -0,0 +1,33 @@
+/*******************************************************************************
+ * Copyright (c) 2009, 2020 IBM Corporation and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ * Freescale Semiconductor - Bug 293618, Breakpoints view sorts up to first colon only
+ * Anton Kosyakov (Itemis AG) - Bug 438621 - [step filtering] Provide an extension point to enhance methods step filtering.
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.tests;
+
+import org.eclipse.debug.ui.launchview.tests.launchview.LaunchViewSmokeTest;
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Tests for integration and nightly builds.
+ *
+ * @since 1.0
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+ // Launch Configuration View
+ LaunchViewSmokeTest.class,
+})
+public class AutomatedSuite {
+}
diff --git a/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestUtil.java b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestUtil.java
new file mode 100644
index 000000000..8251f1767
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestUtil.java
@@ -0,0 +1,303 @@
+/*******************************************************************************
+ * Copyright (c) 2017 Google, Inc and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Stefan Xenos (Google) - Initial implementation
+ * Andrey Loskutov (loskutov@gmx.de) - many different extensions
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.tests;
+
+import static org.junit.Assert.fail;
+
+import java.lang.management.ManagementFactory;
+import java.lang.management.ThreadInfo;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.LinkedHashSet;
+import java.util.List;
+import java.util.Set;
+import java.util.function.Function;
+import java.util.function.Supplier;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.swt.widgets.Display;
+import org.junit.Assert;
+
+
+public class TestUtil {
+
+ /**
+ * Call this in the tearDown method of every test to clean up state that can
+ * otherwise leak through SWT between tests.
+ */
+ public static void cleanUp(String owner) {
+ // Ensure that the Thread.interrupted() flag didn't leak.
+ Assert.assertFalse("The main thread should not be interrupted at the end of a test", Thread.interrupted());
+
+ // Wait for any outstanding jobs to finish. Protect against deadlock by
+ // terminating the wait after a timeout.
+ boolean timedOut = waitForJobs(owner, 5, 5000);
+ if (timedOut) {
+ // We don't expect any extra jobs run during the test: try to cancel them
+ log(IStatus.INFO, owner, "Trying to cancel running jobs: " + getRunningOrWaitingJobs(null));
+ getRunningOrWaitingJobs(null).forEach(Job::cancel);
+ waitForJobs(owner, 5, 1000);
+ }
+
+ // Ensure that the Thread.interrupted() flag didn't leak.
+ Assert.assertFalse("The main thread should not be interrupted at the end of a test", Thread.interrupted());
+ }
+
+ public static void log(int severity, String owner, String message, Throwable... optionalError) {
+ message = "[" + owner + "] " + message;
+ Throwable error = null;
+ if (optionalError != null && optionalError.length > 0) {
+ error = optionalError[0];
+ }
+ Status status = new Status(severity, TestsPlugin.getDefault().getBundle().getSymbolicName(), message, error);
+ TestsPlugin.getDefault().getLog().log(status);
+ }
+
+ /**
+ * Process all queued UI events. If called from background thread, does
+ * nothing.
+ */
+ public static void processUIEvents() {
+ Display display = Display.getCurrent();
+ if (display != null && !display.isDisposed()) {
+ while (display.readAndDispatch()) {
+ // Keep pumping events until the queue is empty
+ }
+ }
+ }
+
+ /**
+ * Process all queued UI events. If called from background thread, just
+ * waits
+ *
+ * @param millis max wait time to process events
+ */
+ public static void processUIEvents(final long millis) throws Exception {
+ long start = System.currentTimeMillis();
+ while (System.currentTimeMillis() - start < millis) {
+ Display display = Display.getCurrent();
+ if (display != null && !display.isDisposed()) {
+ while (display.readAndDispatch()) {
+ // loop until the queue is empty
+ }
+ } else {
+ Thread.sleep(10);
+ }
+ }
+ }
+
+ /**
+ * Waits while given condition is {@code true} for a given amount of
+ * milliseconds. If the actual wait time exceeds given timeout and condition
+ * will be still {@code true}, throws {@link AssertionFailedError} with
+ * given message.
+ * <p>
+ * Will process UI events while waiting in UI thread, if called from
+ * background thread, just waits.
+ *
+ * @param <T> type of the context
+ * @param condition function which will be evaluated while waiting
+ * @param context test context
+ * @param timeout max wait time in milliseconds to wait on given condition
+ * @param errorMessage message which will be used to construct the failure
+ * exception in case the condition will still return {@code true}
+ * after given timeout
+ */
+ public static <T> void waitWhile(Function<T, Boolean> condition, T context, long timeout, Function<T, String> errorMessage) throws Exception {
+ long start = System.currentTimeMillis();
+ Display display = Display.getCurrent();
+ while (System.currentTimeMillis() - start < timeout && condition.apply(context)) {
+ if (display != null && !display.isDisposed()) {
+ if (!display.readAndDispatch()) {
+ Thread.sleep(0);
+ }
+ } else {
+ Thread.sleep(5);
+ }
+ }
+ Boolean stillTrue = condition.apply(context);
+ if (stillTrue) {
+ fail(errorMessage.apply(context));
+ }
+ }
+
+ /**
+ * A simplified variant of
+ * {@link #waitWhile(Function, Object, long, Function)}.
+ * <p>
+ * Waits while given condition is {@code true} for a given amount of
+ * milliseconds.
+ * <p>
+ * Will process UI events while waiting in UI thread, if called from
+ * background thread, just waits.
+ *
+ * @param condition function which will be evaluated while waiting
+ * @param timeout max wait time in milliseconds to wait on given condition
+ * @return value of condition when method returned
+ */
+ public static boolean waitWhile(Supplier<Boolean> condition, long timeout) throws Exception {
+ if (condition == null) {
+ condition = () -> true;
+ }
+ long start = System.currentTimeMillis();
+ Display display = Display.getCurrent();
+ while (System.currentTimeMillis() - start < timeout && condition.get()) {
+ Thread.yield();
+ if (display != null && !display.isDisposed()) {
+ if (!display.readAndDispatch()) {
+ Thread.sleep(1);
+ }
+ } else {
+ Thread.sleep(5);
+ }
+ }
+ return condition.get();
+ }
+
+ /**
+ * Utility for waiting until the execution of jobs of any family has
+ * finished or timeout is reached. If no jobs are running, the method waits
+ * given minimum wait time. While this method is waiting for jobs, UI events
+ * are processed.
+ *
+ * @param owner name of the caller which will be logged as prefix if the
+ * wait times out
+ * @param minTimeMs minimum wait time in milliseconds
+ * @param maxTimeMs maximum wait time in milliseconds
+ * @return true if the method timed out, false if all the jobs terminated
+ * before the timeout
+ */
+ public static boolean waitForJobs(String owner, long minTimeMs, long maxTimeMs) {
+ return waitForJobs(owner, minTimeMs, maxTimeMs, (Object[]) null);
+ }
+
+ /**
+ * Utility for waiting until the execution of jobs of any family has finished or timeout is reached. If no jobs are running, the method waits
+ * given minimum wait time. While this method is waiting for jobs, UI events are processed.
+ *
+ * @param owner
+ * name of the caller which will be logged as prefix if the wait times out
+ * @param minTimeMs
+ * minimum wait time in milliseconds
+ * @param maxTimeMs
+ * maximum wait time in milliseconds
+ * @param excludedFamilies
+ * optional list of job families to NOT wait for
+ *
+ * @return true if the method timed out, false if all the jobs terminated before the timeout
+ */
+ public static boolean waitForJobs(String owner, long minTimeMs, long maxTimeMs, Object... excludedFamilies) {
+ if (maxTimeMs < minTimeMs) {
+ throw new IllegalArgumentException("Max time is smaller as min time!");
+ }
+ final long start = System.currentTimeMillis();
+ while (System.currentTimeMillis() - start < minTimeMs) {
+ processUIEvents();
+ try {
+ Thread.sleep(Math.min(10, minTimeMs));
+ } catch (InterruptedException e) {
+ // Uninterruptable
+ }
+ }
+ while (!Job.getJobManager().isIdle()) {
+ List<Job> jobs = getRunningOrWaitingJobs(null, excludedFamilies);
+ if (jobs.isEmpty()) {
+ // only uninteresting jobs running
+ break;
+ }
+
+ if (!Collections.disjoint(runningJobs, jobs)) {
+ // There is a job which runs already quite some time, don't wait for it to avoid test timeouts
+ dumpRunningOrWaitingJobs(owner, jobs);
+ return true;
+ }
+
+ if (System.currentTimeMillis() - start >= maxTimeMs) {
+ dumpRunningOrWaitingJobs(owner, jobs);
+ return true;
+ }
+ processUIEvents();
+ try {
+ Thread.sleep(10);
+ } catch (InterruptedException e) {
+ // Uninterruptable
+ }
+ }
+ runningJobs.clear();
+ return false;
+ }
+
+ static Set<Job> runningJobs = new LinkedHashSet<>();
+
+ private static void dumpRunningOrWaitingJobs(String owner, List<Job> jobs) {
+ String message = "Some job is still running or waiting to run: " + dumpRunningOrWaitingJobs(jobs);
+ log(IStatus.ERROR, owner, message);
+ }
+
+ private static String dumpRunningOrWaitingJobs(List<Job> jobs) {
+ if (jobs.isEmpty()) {
+ return "";
+ }
+ // clear "old" running jobs, we only remember most recent
+ runningJobs.clear();
+ StringBuilder sb = new StringBuilder();
+ for (Job job : jobs) {
+ runningJobs.add(job);
+ sb.append("\n'").append(job.toString()).append("'/");
+ sb.append(job.getClass().getName());
+ Thread thread = job.getThread();
+ if (thread != null) {
+ ThreadInfo[] threadInfos = ManagementFactory.getThreadMXBean().getThreadInfo(new long[] { thread.getId() }, true, true);
+ if (threadInfos[0] != null) {
+ sb.append("\nthread info: ").append(threadInfos[0]);
+ }
+ }
+ sb.append(", ");
+ }
+ sb.setLength(sb.length() - 2);
+ return sb.toString();
+ }
+
+ public static List<Job> getRunningOrWaitingJobs(Object jobFamily, Object... excludedFamilies) {
+ List<Job> running = new ArrayList<>();
+ Job[] jobs = Job.getJobManager().find(jobFamily);
+ for (Job job : jobs) {
+ if (isRunningOrWaitingJob(job) && !belongsToFamilies(job, excludedFamilies)) {
+ running.add(job);
+ }
+ }
+ return running;
+ }
+
+ private static boolean isRunningOrWaitingJob(Job job) {
+ int state = job.getState();
+ return (state == Job.RUNNING || state == Job.WAITING);
+ }
+
+ private static boolean belongsToFamilies(Job job, Object... excludedFamilies) {
+ if (excludedFamilies == null || excludedFamilies.length == 0) {
+ return false;
+ }
+ for (Object family : excludedFamilies) {
+ if (job.belongsTo(family)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestsPlugin.java b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestsPlugin.java
new file mode 100644
index 000000000..2fdc87d80
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/TestsPlugin.java
@@ -0,0 +1,110 @@
+/*******************************************************************************
+ * Copyright (c) 2009, 2013 Wind River Systems and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Wind River Systems - initial API and implementation
+ * IBM - ongoing enhancements
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.tests;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.resources.IWorkspaceRoot;
+import org.eclipse.core.resources.ResourcesPlugin;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.Bundle;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ *
+ * @since 1.0
+ */
+public class TestsPlugin extends AbstractUIPlugin {
+
+ // The plug-in ID
+ public static final String PLUGIN_ID = "org.eclipse.debug.ui.launchview.tests"; //$NON-NLS-1$
+
+ // The shared instance
+ private static TestsPlugin plugin;
+
+ /**
+ * The constructor
+ */
+ public TestsPlugin() {
+ }
+
+ @Override
+ public void start(BundleContext context) throws Exception {
+ super.start(context);
+ plugin = this;
+ }
+
+ @Override
+ public void stop(BundleContext context) throws Exception {
+ plugin = null;
+ super.stop(context);
+ }
+
+ /**
+ * Returns the shared instance
+ *
+ * @return the shared instance
+ */
+ public static TestsPlugin getDefault() {
+ return plugin;
+ }
+
+ /**
+ * Returns the file corresponding to the specified path from within this bundle
+ * @param path
+ * @return the file corresponding to the specified path from within this bundle, or
+ * <code>null</code> if not found
+ */
+ public File getFileInPlugin(IPath path) {
+ try {
+ Bundle bundle = getDefault().getBundle();
+ URL installURL = new URL(bundle.getEntry("/"), path.toString()); //$NON-NLS-1$
+ URL localURL= FileLocator.toFileURL(installURL);//Platform.asLocalURL(installURL);
+ return new File(localURL.getFile());
+ } catch (IOException e) {
+ return null;
+ }
+ }
+
+ /**
+ * Creates a new project with the specified name
+ * @param projectName
+ * @return a new project with the specified name
+ * @throws CoreException
+ */
+ public static IProject createProject(String projectName) throws CoreException {
+ IWorkspaceRoot root= ResourcesPlugin.getWorkspace().getRoot();
+ IProject project= root.getProject(projectName);
+ if (!project.exists()) {
+ project.create(null);
+ } else {
+ project.refreshLocal(IResource.DEPTH_INFINITE, null);
+ }
+
+ if (!project.isOpen()) {
+ project.open(null);
+ }
+ return project;
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/launchview/LaunchViewSmokeTest.java b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/launchview/LaunchViewSmokeTest.java
new file mode 100644
index 000000000..28d532c97
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/src/org/eclipse/debug/ui/launchview/tests/launchview/LaunchViewSmokeTest.java
@@ -0,0 +1,38 @@
+/*******************************************************************************
+ * Copyright (c) 2021 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.tests.launchview;
+
+import static org.junit.Assert.assertNotNull;
+
+import org.eclipse.debug.ui.launchview.tests.AbstractLaunchViewTest;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.PartInitException;
+import org.eclipse.ui.PlatformUI;
+import org.junit.Test;
+
+public class LaunchViewSmokeTest extends AbstractLaunchViewTest {
+
+ @Test
+ public void testOpenView() {
+ IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
+ assertNotNull("The active workbench page should not be null", page); //$NON-NLS-1$
+ try {
+ page.showView("org.eclipse.debug.ui.launchView"); //$NON-NLS-1$
+ } catch (PartInitException e) {
+ assertNotNull("Failed to open launch configuration view", null); //$NON-NLS-1$
+ }
+
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview.tests/test.xml b/org.eclipse.debug.ui.launchview.tests/test.xml
new file mode 100644
index 000000000..04badcb24
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview.tests/test.xml
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (c) 2009, 2011 IBM Corporation and others.
+
+ This program and the accompanying materials
+ are made available under the terms of the Eclipse Public License 2.0
+ which accompanies this distribution, and is available at
+ https://www.eclipse.org/legal/epl-2.0/
+
+ SPDX-License-Identifier: EPL-2.0
+
+ Contributors:
+ IBM Corporation - initial API and implementation
+ -->
+
+<project name="testsuite" default="run" basedir=".">
+ <!-- The property ${eclipse-home} should be passed into this script -->
+ <!-- Set a meaningful default value for when it is not. -->
+ <property name="eclipse-home" value="${basedir}\..\.."/>
+
+ <!-- sets the properties eclipse-home, and library-file -->
+ <property name="plugin-name" value="org.eclipse.debug.ui.launchview.tests"/>
+ <property name="library-file"
+ value="${eclipse-home}/plugins/org.eclipse.test/library.xml"/>
+
+ <!-- This target holds all initialization code that needs to be done for -->
+ <!-- all tests that are to be run. Initialization for individual tests -->
+ <!-- should be done within the body of the suite target. -->
+ <target name="init">
+ <tstamp/>
+ <delete>
+ <fileset dir="${eclipse-home}" includes="org*.xml"/>
+ </delete>
+ </target>
+
+ <!-- This target defines the regression tests that need to be run. -->
+ <target name="suite">
+ <property name="platform-debug-folder"
+ value="${eclipse-home}/platform_debug_folder"/>
+ <delete dir="${platform-debug-folder}" quiet="true"/>
+ <ant target="ui-test" antfile="${library-file}" dir="${eclipse-home}">
+ <property name="data-dir" value="${platform-debug-folder}"/>
+ <property name="plugin-name" value="${plugin-name}"/>
+ <property name="classname"
+ value="org.eclipse.debug.ui.launchview.tests.AutomatedSuite"/>
+ </ant>
+ </target>
+
+ <!-- This target holds code to cleanup the testing environment after -->
+ <!-- after all of the tests have been run. You can use this target to -->
+ <!-- delete temporary files that have been created. -->
+ <target name="cleanup">
+ </target>
+
+ <!-- This target runs the test suite. Any actions that need to happen -->
+ <!-- after all the tests have been run should go here. -->
+ <target name="run" depends="init,suite,cleanup">
+ <ant target="collect" antfile="${library-file}" dir="${eclipse-home}">
+ <property name="includes" value="org*.xml"/>
+ <property name="output-file" value="${plugin-name}.xml"/>
+ </ant>
+ </target>
+
+</project>
diff --git a/org.eclipse.debug.ui.launchview/.classpath b/org.eclipse.debug.ui.launchview/.classpath
new file mode 100644
index 000000000..e801ebfb4
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.classpath
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/org.eclipse.debug.ui.launchview/.project b/org.eclipse.debug.ui.launchview/.project
new file mode 100644
index 000000000..e0baa5074
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.project
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.debug.ui.launchview</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ds.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ </natures>
+</projectDescription>
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.resources.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.resources.prefs
new file mode 100644
index 000000000..b7aa6e61b
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.resources.prefs
@@ -0,0 +1,4 @@
+eclipse.preferences.version=1
+encoding//ui/org/eclipse/debug/internal/ui/elements/adapters/Messages.properties=8859_1
+encoding//ui/org/eclipse/debug/internal/ui/importexport/breakpoints/BreakpointImportExport.properties=8859_1
+encoding/<project>=UTF-8
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.runtime.prefs
new file mode 100644
index 000000000..5a0ad22d2
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.core.runtime.prefs
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 000000000..2d85a380f
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,439 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.builder.cleanOutputFolder=clean
+org.eclipse.jdt.core.builder.duplicateResourceTask=warning
+org.eclipse.jdt.core.builder.invalidClasspath=abort
+org.eclipse.jdt.core.builder.recreateModifiedClassFileInOutputFolder=ignore
+org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch
+org.eclipse.jdt.core.circularClasspath=error
+org.eclipse.jdt.core.classpath.exclusionPatterns=enabled
+org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled
+org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnull.secondary=
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary=
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=11
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.maxProblemPerUnit=100
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
+org.eclipse.jdt.core.compiler.problem.deadCode=warning
+org.eclipse.jdt.core.compiler.problem.deprecation=warning
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=ignore
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=ignore
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=ignore
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=private
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=enabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=enabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=private
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=error
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=warning
+org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unsafeTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
+org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=warning
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
+org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
+org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
+org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=0
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=true
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=true
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=true
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=80
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=tab
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
+org.eclipse.jdt.core.incompatibleJDKLevel=ignore
+org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644
index 000000000..c0ff1c129
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.jdt.ui.prefs
@@ -0,0 +1,114 @@
+cleanup.add_default_serial_version_id=true
+cleanup.add_generated_serial_version_id=false
+cleanup.add_missing_annotations=true
+cleanup.add_missing_deprecated_annotations=true
+cleanup.add_missing_methods=false
+cleanup.add_missing_nls_tags=false
+cleanup.add_missing_override_annotations=true
+cleanup.add_missing_override_annotations_interface_methods=true
+cleanup.add_serial_version_id=false
+cleanup.always_use_blocks=true
+cleanup.always_use_parentheses_in_expressions=false
+cleanup.always_use_this_for_non_static_field_access=false
+cleanup.always_use_this_for_non_static_method_access=false
+cleanup.convert_to_enhanced_for_loop=false
+cleanup.correct_indentation=false
+cleanup.format_source_code=true
+cleanup.format_source_code_changes_only=false
+cleanup.make_local_variable_final=true
+cleanup.make_parameters_final=false
+cleanup.make_private_fields_final=true
+cleanup.make_type_abstract_if_missing_method=false
+cleanup.make_variable_declarations_final=false
+cleanup.never_use_blocks=false
+cleanup.never_use_parentheses_in_expressions=true
+cleanup.organize_imports=true
+cleanup.qualify_static_field_accesses_with_declaring_class=false
+cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+cleanup.qualify_static_member_accesses_with_declaring_class=true
+cleanup.qualify_static_method_accesses_with_declaring_class=false
+cleanup.remove_private_constructors=true
+cleanup.remove_trailing_whitespaces=true
+cleanup.remove_trailing_whitespaces_all=true
+cleanup.remove_trailing_whitespaces_ignore_empty=false
+cleanup.remove_unnecessary_casts=true
+cleanup.remove_unnecessary_nls_tags=true
+cleanup.remove_unused_imports=true
+cleanup.remove_unused_local_variables=false
+cleanup.remove_unused_private_fields=true
+cleanup.remove_unused_private_members=false
+cleanup.remove_unused_private_methods=true
+cleanup.remove_unused_private_types=true
+cleanup.sort_members=false
+cleanup.sort_members_all=false
+cleanup.use_blocks=true
+cleanup.use_blocks_only_for_return_and_throw=false
+cleanup.use_parentheses_in_expressions=false
+cleanup.use_this_for_non_static_field_access=false
+cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+cleanup.use_this_for_non_static_method_access=false
+cleanup.use_this_for_non_static_method_access_only_if_necessary=true
+cleanup_profile=_Platform Debug Cleanups
+cleanup_settings_version=2
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_Platform Debug Formatting
+formatter_settings_version=12
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=true
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_functional_interfaces=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=true
+sp_cleanup.format_source_code_changes_only=true
+sp_cleanup.insert_inferred_type_arguments=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=true
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_redundant_type_arguments=false
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=true
+sp_cleanup.remove_unnecessary_nls_tags=true
+sp_cleanup.remove_unused_imports=true
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_anonymous_class_creation=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_lambda=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644
index 000000000..3cf0ccb6b
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.api.tools.prefs
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Warning
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.ds.annotations.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.ds.annotations.prefs
new file mode 100644
index 000000000..960a807c0
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.ds.annotations.prefs
@@ -0,0 +1,6 @@
+eclipse.preferences.version=1
+enabled=true
+generateBundleActivationPolicyLazy=true
+path=OSGI-INF
+validationErrorLevel=error
+validationErrorLevel.missingImplicitUnbindMethod=error
diff --git a/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.prefs b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.prefs
new file mode 100644
index 000000000..56e42fa48
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/.settings/org.eclipse.pde.prefs
@@ -0,0 +1,36 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=1
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=2
+compilers.p.discouraged-class=1
+compilers.p.illegal-att-value=0
+compilers.p.internal=1
+compilers.p.matching-pom-version=0
+compilers.p.missing-packages=0
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=0
+compilers.p.unknown-attribute=0
+compilers.p.unknown-class=1
+compilers.p.unknown-element=2
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=0
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.p.unused-element-or-attribute=1
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+compilers.use-project=true
+eclipse.preferences.version=1
diff --git a/org.eclipse.debug.ui.launchview/META-INF/MANIFEST.MF b/org.eclipse.debug.ui.launchview/META-INF/MANIFEST.MF
new file mode 100644
index 000000000..1afe723f9
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/META-INF/MANIFEST.MF
@@ -0,0 +1,25 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %pluginName
+Bundle-SymbolicName: org.eclipse.debug.ui.launchview;singleton:=true
+Bundle-Version: 1.0.200.qualifier
+Bundle-Vendor: %providerName
+Bundle-Localization: plugin
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.core.runtime,
+ org.eclipse.e4.ui.model.workbench,
+ org.eclipse.debug.core,
+ org.eclipse.debug.ui,
+ org.eclipse.osgi.services,
+ org.eclipse.e4.core.di.annotations,
+ org.eclipse.e4.ui.di,
+ org.eclipse.e4.ui.services
+Bundle-RequiredExecutionEnvironment: JavaSE-11
+Import-Package: javax.annotation;version="1.0.0";resolution:=optional,
+ javax.inject;version="1.0.0"
+Bundle-ActivationPolicy: lazy
+Service-Component: OSGI-INF/org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.xml,
+ OSGI-INF/org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider.xml
+Export-Package: org.eclipse.debug.ui.launchview;x-internal:=true,
+ org.eclipse.debug.ui.launchview.services;x-internal:=true
+Automatic-Module-Name: org.eclipse.debug.ui.launchview
diff --git a/org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider.xml b/org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider.xml
new file mode 100644
index 000000000..cf17032a3
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" activate="createService" deactivate="destroyService" name="org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider">
+ <service>
+ <provide interface="org.eclipse.debug.ui.launchview.services.ILaunchObjectProvider"/>
+ </service>
+ <implementation class="org.eclipse.debug.ui.launchview.internal.impl.DebugCoreProvider"/>
+</scr:component> \ No newline at end of file
diff --git a/org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.xml b/org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.xml
new file mode 100644
index 000000000..0eb619af3
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/OSGI-INF/org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.2.0" activate="activate" deactivate="deactivate" immediate="true" name="org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel">
+ <service>
+ <provide interface="org.eclipse.debug.ui.launchview.internal.model.ILaunchModel"/>
+ </service>
+ <reference bind="addLaunchObjectProvider" cardinality="0..n" interface="org.eclipse.debug.ui.launchview.services.ILaunchObjectProvider" name="LaunchObjectProvider" policy="dynamic" policy-option="greedy" unbind="removeLaunchObjectProvider"/>
+ <reference bind="setWorkbench" cardinality="1..1" interface="org.eclipse.ui.IWorkbench" name="Workbench" policy="static" unbind="unsetWorkbench"/>
+ <implementation class="org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel"/>
+</scr:component> \ No newline at end of file
diff --git a/org.eclipse.debug.ui.launchview/about.html b/org.eclipse.debug.ui.launchview/about.html
new file mode 100644
index 000000000..164f781a8
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/about.html
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
+<title>About</title>
+</head>
+<body lang="EN-US">
+ <h2>About This Content</h2>
+
+ <p>November 30, 2017</p>
+ <h3>License</h3>
+
+ <p>
+ The Eclipse Foundation makes available all content in this plug-in
+ (&quot;Content&quot;). Unless otherwise indicated below, the Content
+ is provided to you under the terms and conditions of the Eclipse
+ Public License Version 2.0 (&quot;EPL&quot;). A copy of the EPL is
+ available at <a href="http://www.eclipse.org/legal/epl-2.0">http://www.eclipse.org/legal/epl-2.0</a>.
+ For purposes of the EPL, &quot;Program&quot; will mean the Content.
+ </p>
+
+ <p>
+ If you did not receive this Content directly from the Eclipse
+ Foundation, the Content is being redistributed by another party
+ (&quot;Redistributor&quot;) and different terms and conditions may
+ apply to your use of any object code in the Content. Check the
+ Redistributor's license that was provided with the Content. If no such
+ license exists, contact the Redistributor. Unless otherwise indicated
+ below, the terms and conditions of the EPL still apply to any source
+ code in the Content and such source code may be obtained at <a
+ href="http://www.eclipse.org/">http://www.eclipse.org</a>.
+ </p>
+
+</body>
+</html> \ No newline at end of file
diff --git a/org.eclipse.debug.ui.launchview/build.properties b/org.eclipse.debug.ui.launchview/build.properties
new file mode 100644
index 000000000..1c7a06420
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/build.properties
@@ -0,0 +1,10 @@
+output.. = bin/
+bin.includes = META-INF/,\
+ .,\
+ plugin.xml,\
+ OSGI-INF/,\
+ icons/,\
+ plugin.properties,\
+ about.html
+source.. = src/
+src.includes = about.html
diff --git a/org.eclipse.debug.ui.launchview/icons/coverage.png b/org.eclipse.debug.ui.launchview/icons/coverage.png
new file mode 100644
index 000000000..503c96ab8
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/coverage.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/debug_exc.png b/org.eclipse.debug.ui.launchview/icons/debug_exc.png
new file mode 100644
index 000000000..6bd3c425f
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/debug_exc.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/debug_exc@2x.png b/org.eclipse.debug.ui.launchview/icons/debug_exc@2x.png
new file mode 100644
index 000000000..2a3ccdca5
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/debug_exc@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/delete_exc.png b/org.eclipse.debug.ui.launchview/icons/delete_exc.png
new file mode 100644
index 000000000..5f0038585
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/delete_exc.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/delete_exc@2x.png b/org.eclipse.debug.ui.launchview/icons/delete_exc@2x.png
new file mode 100644
index 000000000..eb2fc720b
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/delete_exc@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/edit_template.png b/org.eclipse.debug.ui.launchview/icons/edit_template.png
new file mode 100644
index 000000000..d87238840
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/edit_template.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/edit_template@2x.png b/org.eclipse.debug.ui.launchview/icons/edit_template@2x.png
new file mode 100644
index 000000000..b1c1d8501
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/edit_template@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/favorite_star.png b/org.eclipse.debug.ui.launchview/icons/favorite_star.png
new file mode 100644
index 000000000..75c9d4a1b
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/favorite_star.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/profile_exc.png b/org.eclipse.debug.ui.launchview/icons/profile_exc.png
new file mode 100644
index 000000000..d2971fac4
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/profile_exc.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/profile_exc@2x.png b/org.eclipse.debug.ui.launchview/icons/profile_exc@2x.png
new file mode 100644
index 000000000..8a6257ced
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/profile_exc@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/refresh.png b/org.eclipse.debug.ui.launchview/icons/refresh.png
new file mode 100644
index 000000000..d608a5587
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/refresh.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/refresh@2x.png b/org.eclipse.debug.ui.launchview/icons/refresh@2x.png
new file mode 100644
index 000000000..e81514787
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/refresh@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/run_co.png b/org.eclipse.debug.ui.launchview/icons/run_co.png
new file mode 100644
index 000000000..18fdb33bd
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/run_co.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/run_co@2x.png b/org.eclipse.debug.ui.launchview/icons/run_co@2x.png
new file mode 100644
index 000000000..2caa8c083
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/run_co@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/run_exc.png b/org.eclipse.debug.ui.launchview/icons/run_exc.png
new file mode 100644
index 000000000..08571c1f2
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/run_exc.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/run_exc@2x.png b/org.eclipse.debug.ui.launchview/icons/run_exc@2x.png
new file mode 100644
index 000000000..156df21c3
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/run_exc@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/term_restart.png b/org.eclipse.debug.ui.launchview/icons/term_restart.png
new file mode 100644
index 000000000..08917c61a
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/term_restart.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/term_restart@2x.png b/org.eclipse.debug.ui.launchview/icons/term_restart@2x.png
new file mode 100644
index 000000000..ae6f399d7
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/term_restart@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/terminate_all_co.png b/org.eclipse.debug.ui.launchview/icons/terminate_all_co.png
new file mode 100644
index 000000000..6e8acdcb0
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/terminate_all_co.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/terminate_all_co@2x.png b/org.eclipse.debug.ui.launchview/icons/terminate_all_co@2x.png
new file mode 100644
index 000000000..ee6373a66
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/terminate_all_co@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/terminate_co.png b/org.eclipse.debug.ui.launchview/icons/terminate_co.png
new file mode 100644
index 000000000..3544673b6
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/terminate_co.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/icons/terminate_co@2x.png b/org.eclipse.debug.ui.launchview/icons/terminate_co@2x.png
new file mode 100644
index 000000000..b605e00f4
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/icons/terminate_co@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui.launchview/plugin.properties b/org.eclipse.debug.ui.launchview/plugin.properties
new file mode 100644
index 000000000..33d856aac
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/plugin.properties
@@ -0,0 +1,19 @@
+###############################################################################
+# Copyright (c) 2000, 2019 SSI Schaefer IT Solutions GmbH and others.
+#
+# This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License 2.0
+# which accompanies this distribution, and is available at
+# https://www.eclipse.org/legal/epl-2.0/
+#
+# SPDX-License-Identifier: EPL-2.0
+#
+# Contributors:
+# SSI Schaefer IT Solutions GmbH - initial API and implementation
+###############################################################################
+
+
+pluginName=Debug UI Launch Configuration View
+providerName=Eclipse.org
+
+LaunchView.name=Launch Configurations
diff --git a/org.eclipse.debug.ui.launchview/plugin.xml b/org.eclipse.debug.ui.launchview/plugin.xml
new file mode 100644
index 000000000..4ea04991b
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/plugin.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<plugin>
+ <extension
+ point="org.eclipse.ui.views">
+ <e4view
+ category="org.eclipse.debug.ui"
+ class="org.eclipse.debug.ui.launchview.internal.view.LaunchViewImpl"
+ icon="$nl$/icons/run_exc.png"
+ id="org.eclipse.debug.ui.launchView"
+ name="%LaunchView.name"
+ restorable="true">
+ </e4view>
+ </extension>
+</plugin>
diff --git a/org.eclipse.debug.ui.launchview/pom.xml b/org.eclipse.debug.ui.launchview/pom.xml
new file mode 100644
index 000000000..b46647c5e
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/pom.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (c) 2012, 2022 SSI Schaefer IT Solutions GmbH and others.
+ All rights reserved. This program and the accompanying materials
+ are made available under the terms of the Eclipse Distribution License v1.0
+ which accompanies this distribution, and is available at
+ http://www.eclipse.org/org/documents/edl-v10.php
+
+ Contributors:
+ Markus Duft - initial implementation
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <artifactId>eclipse.platform.debug</artifactId>
+ <groupId>eclipse.platform.debug</groupId>
+ <version>4.24.0-SNAPSHOT</version>
+ </parent>
+
+ <properties>
+ <code.ignoredWarnings>-warn:+resource,-deprecation,unavoidableGenericProblems</code.ignoredWarnings>
+ </properties>
+
+ <groupId>org.eclipse.debug</groupId>
+ <artifactId>org.eclipse.debug.ui.launchview</artifactId>
+ <version>1.0.200-SNAPSHOT</version>
+ <packaging>eclipse-plugin</packaging>
+</project>
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/IBackgroundLaunchExecutor.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/IBackgroundLaunchExecutor.java
new file mode 100644
index 000000000..f08d92540
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/IBackgroundLaunchExecutor.java
@@ -0,0 +1,46 @@
+/*******************************************************************************
+ * Copyright (c) 2021 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview;
+
+import java.io.File;
+
+import org.eclipse.debug.core.ILaunchConfiguration;
+
+/**
+ * Allows to execute a specified launch configuration in the background, i.e.
+ * non-blocking.
+ * <p>
+ * The launch configuration is started as a background job.
+ *
+ * @since 1.0.2
+ */
+public interface IBackgroundLaunchExecutor {
+
+ /**
+ * Starts a launch configuration. The return value is only valid if wait is
+ * <code>true</code>. Otherwise the launch is not awaited and the method
+ * returns immediately.
+ *
+ * @param launchConf the launch configuration
+ * @param mode the launch mode to use.
+ * @param build whether to perform a build before launch
+ * @param wait whether to wait for completion
+ * @param logFile an optional {@link File} to write console output to. May
+ * be <code>null</code>.
+ * @return process exit value if wait is <code>true</code>, always 0 if wait
+ * is <code>false</code>. -1 in case waiting was interrupted.
+ */
+ int launchProcess(ILaunchConfiguration launchConf, String mode, boolean build, boolean wait, File logFile);
+
+} \ No newline at end of file
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/LaunchConfigurationViewPlugin.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/LaunchConfigurationViewPlugin.java
new file mode 100644
index 000000000..3af0316c1
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/LaunchConfigurationViewPlugin.java
@@ -0,0 +1,34 @@
+/*******************************************************************************
+ * Copyright (c) 2021 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview;
+
+import org.eclipse.debug.ui.launchview.internal.launcher.StandaloneLaunchConfigExecutor;
+
+/**
+ * Static Helper which provides access to internal implementations of externally
+ * available API.
+ *
+ * @since 1.0.2
+ */
+public class LaunchConfigurationViewPlugin {
+
+ /**
+ * @return an {@link IBackgroundLaunchExecutor} which can be used to launch
+ * launch configurations as background jobs.
+ */
+ public static IBackgroundLaunchExecutor getExecutor() {
+ return new StandaloneLaunchConfigExecutor();
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/AbstractLaunchObjectProvider.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/AbstractLaunchObjectProvider.java
new file mode 100644
index 000000000..0311fbd85
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/AbstractLaunchObjectProvider.java
@@ -0,0 +1,44 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.debug.ui.launchview.services.ILaunchObjectProvider;
+
+/**
+ * Base class for {@link ILaunchObjectProvider} implementations which require
+ * listeners to be notified on updates.
+ */
+public abstract class AbstractLaunchObjectProvider implements ILaunchObjectProvider {
+
+ private final List<Runnable> updateListeners = new ArrayList<>();
+
+ @Override
+ public void addUpdateListener(Runnable r) {
+ updateListeners.add(r);
+ }
+
+ @Override
+ public void removeUpdateListener(Runnable r) {
+ updateListeners.remove(r);
+ }
+
+ protected void fireUpdate() {
+ // prevent multiple updates in short row somehow?
+ updateListeners.forEach(Runnable::run);
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/FileLogger.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/FileLogger.java
new file mode 100644
index 000000000..36ae0c538
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/FileLogger.java
@@ -0,0 +1,60 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal;
+
+import java.io.BufferedWriter;
+import java.io.Closeable;
+import java.io.File;
+import java.io.FileWriter;
+import java.io.IOException;
+
+import org.eclipse.core.runtime.Platform;
+import org.eclipse.debug.core.IStreamListener;
+import org.eclipse.debug.core.model.IProcess;
+import org.eclipse.debug.core.model.IStreamMonitor;
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Logger that can be attached to a {@linkplain IProcess} and that writes the
+ * output to a file.
+ * <p>
+ * Please note that it is the responsibility of the caller to close the logger
+ * if it is not used any more.
+ * </p>
+ */
+public class FileLogger implements IStreamListener, Closeable {
+
+ private final BufferedWriter writer;
+
+ /** Creates a new logger that writes to the given file */
+ public FileLogger(File file) throws IOException {
+ writer = new BufferedWriter(new FileWriter(file));
+ }
+
+ @Override
+ public void streamAppended(String text, IStreamMonitor monitor) {
+ try {
+ writer.write(text);
+ writer.flush();
+ } catch (Exception ex) {
+ Platform.getLog(this.getClass()).warn(NLS.bind(LaunchViewMessages.FileLogger_FailedAppend, text), ex);
+ }
+ }
+
+ @Override
+ public void close() throws IOException {
+ writer.close();
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewBundleInfo.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewBundleInfo.java
new file mode 100644
index 000000000..c12a4c421
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewBundleInfo.java
@@ -0,0 +1,21 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal;
+
+public interface LaunchViewBundleInfo {
+
+ // The plug-in ID
+ static final String PLUGIN_ID = "org.eclipse.debug.ui.launchview"; //$NON-NLS-1$
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewMessages.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewMessages.java
new file mode 100644
index 000000000..60c0a3637
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/LaunchViewMessages.java
@@ -0,0 +1,52 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal;
+
+import org.eclipse.osgi.util.NLS;
+
+public class LaunchViewMessages extends NLS {
+ private static final String BUNDLE_NAME = "org.eclipse.debug.ui.launchview.internal.messages"; //$NON-NLS-1$
+
+ public static String DebugCoreLaunchObject_CannotGetType;
+ public static String DebugCoreLaunchObject_CannotRelaunch;
+ public static String DebugCoreLaunchObject_CannotTerminate;
+ public static String DebugCoreLaunchObject_Terminate;
+ public static String DebugCoreProvider_cannotFetchError;
+ public static String DebugCoreProvider_delete;
+ public static String DebugCoreProvider_deleteHint;
+ public static String DebugCoreProvider_FailedLookup;
+ public static String EditAction_Edit;
+ public static String FileLogger_FailedAppend;
+ public static String LaunchAction_FailedFetchLaunchDelegates;
+ public static String LaunchObject_ErrorNoId;
+ public static String LaunchObjectFavoriteContainerModel_Favorites;
+ public static String LaunchView_Refresh;
+ public static String LaunchView_Reset;
+ public static String LaunchView_TerminateAll;
+ public static String RelaunchAction_TerminateRelaunch;
+ public static String StandaloneLaunchConfigExecutor_FailedLaunching;
+ public static String StandaloneLaunchConfigExecutor_Launch;
+ public static String StandaloneLaunchConfigExecutor_Launching;
+ public static String StandaloneLaunchConfigExecutor_Timeout;
+ public static String StandaloneLaunchConfigExecutor_Waiting;
+ public static String TerminateAction_Terminate;
+
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, LaunchViewMessages.class);
+ }
+
+ private LaunchViewMessages() {
+ }
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/SpecificLaunchListener.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/SpecificLaunchListener.java
new file mode 100644
index 000000000..20d9cf695
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/SpecificLaunchListener.java
@@ -0,0 +1,98 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal;
+
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.debug.core.ILaunchesListener2;
+import org.eclipse.debug.core.model.IProcess;
+
+/**
+ * Wrapper around {@link ILaunchesListener2} which unwraps to a single specific
+ * {@link ILaunch} matching the given {@link ILaunchConfiguration}
+ */
+public abstract class SpecificLaunchListener implements ILaunchesListener2 {
+
+ private interface ILaunchMethod {
+
+ public void theMethod(ILaunch launch);
+ }
+
+ private final ILaunchConfiguration config;
+
+ public SpecificLaunchListener(ILaunchConfiguration config) {
+ this.config = config;
+ }
+
+ private boolean matches(ILaunch launch) {
+ // this can happen if re-generating a running launch configuration
+ if (launch == null || launch.getLaunchConfiguration() == null) {
+ return false;
+ }
+
+ return launch.getLaunchConfiguration().contentsEqual(this.config);
+ }
+
+ private void runIfMatches(ILaunch[] launches, ILaunchMethod handle) {
+ for (ILaunch l : launches) {
+ if (matches(l)) {
+ handle.theMethod(l);
+ }
+ }
+ }
+
+ @Override
+ public void launchesRemoved(ILaunch[] launches) {
+ runIfMatches(launches, this::launchRemoved);
+ }
+
+ @Override
+ public void launchesAdded(ILaunch[] launches) {
+ runIfMatches(launches, this::launchAdded);
+ }
+
+ @Override
+ public void launchesChanged(ILaunch[] launches) {
+ runIfMatches(launches, this::launchChanged);
+ }
+
+ @Override
+ public void launchesTerminated(ILaunch[] launches) {
+ runIfMatches(launches, this::launchTerminated);
+ }
+
+ public void launchRemoved(@SuppressWarnings("unused") ILaunch launch) {
+ // default: nothing
+ }
+
+ public void launchAdded(@SuppressWarnings("unused") ILaunch launch) {
+ // default: nothing
+ }
+
+ /**
+ * Called whenever a launch changes. Adding an {@link IProcess} to the
+ * {@link ILaunch} is a change.
+ */
+ public void launchChanged(@SuppressWarnings("unused") ILaunch launch) {
+ // default: nothing
+ }
+
+ /**
+ * Called whenever the launch is terminated.
+ */
+ public void launchTerminated(@SuppressWarnings("unused") ILaunch launch) {
+ // default: nothing
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/StreamHelper.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/StreamHelper.java
new file mode 100644
index 000000000..8adc1749b
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/StreamHelper.java
@@ -0,0 +1,40 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal;
+
+import java.io.Closeable;
+
+/**
+ * Provides static helpers to work with streams
+ */
+public class StreamHelper {
+
+ /**
+ * Unconditionally close a <code>Closeable</code> without throwing any
+ * exception.
+ *
+ * @param closeable the object to close, may be null or already closed
+ */
+ public static void closeQuietly(Closeable closeable) {
+ if (closeable == null) {
+ return;
+ }
+ try {
+ closeable.close();
+ } catch (Exception e) {
+ // ignore
+ }
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreLaunchObject.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreLaunchObject.java
new file mode 100644
index 000000000..5c02a2523
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreLaunchObject.java
@@ -0,0 +1,188 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2021 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ * IBM Corporation - Bug fixes
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.impl;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Platform;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.debug.core.DebugException;
+import org.eclipse.debug.core.DebugPlugin;
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.debug.core.ILaunchConfigurationType;
+import org.eclipse.debug.core.ILaunchMode;
+import org.eclipse.debug.ui.DebugUITools;
+import org.eclipse.debug.ui.IDebugUIConstants;
+import org.eclipse.debug.ui.ILaunchGroup;
+import org.eclipse.debug.ui.launchview.LaunchConfigurationViewPlugin;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.jface.viewers.StyledString;
+import org.eclipse.osgi.util.NLS;
+import org.eclipse.ui.PlatformUI;
+
+public class DebugCoreLaunchObject implements ILaunchObject, Comparable<ILaunchObject> {
+
+ private final ILaunchConfiguration config;
+
+ public DebugCoreLaunchObject(ILaunchConfiguration config) {
+ this.config = config;
+ }
+
+ @Override
+ public String getId() {
+ return config.getName();
+ }
+
+ @Override
+ public StyledString getLabel() {
+ return new StyledString(config.getName());
+ }
+
+ @Override
+ public ILaunchConfigurationType getType() {
+ try {
+ return config.getType();
+ } catch (CoreException e) {
+ Platform.getLog(this.getClass()).error(NLS.bind(LaunchViewMessages.DebugCoreLaunchObject_CannotGetType, config.getName()), e);
+ }
+ return null;
+ }
+
+ @Override
+ public void launch(ILaunchMode mode) {
+ LaunchConfigurationViewPlugin.getExecutor().launchProcess(config, mode.getIdentifier(), true, false, null);
+ }
+
+ @Override
+ public boolean canTerminate() {
+ return !findTerminateableLaunches(config.getName()).isEmpty();
+ }
+
+ @Override
+ public void terminate() {
+ // DON'T use Eclipse' mechanism - it's a little broken if shutdown of
+ // the processes takes longer than a few seconds.
+ // Instead we start a job that tries to terminate processes. If the job
+ // itself is stopped, we give up like Eclipse does.
+ Collection<ILaunch> launches = findTerminateableLaunches(config.getName());
+ for (ILaunch launch: launches) {
+ Job terminateJob = new Job(NLS.bind(LaunchViewMessages.DebugCoreLaunchObject_Terminate, config.getName())) {
+
+ @Override
+ protected IStatus run(IProgressMonitor monitor) {
+ if (!launch.isTerminated()) {
+ try {
+ launch.terminate();
+ } catch (DebugException e) {
+ // could not terminate - but we cannot do anything
+ // anyway... :(
+ return new Status(IStatus.WARNING, LaunchViewBundleInfo.PLUGIN_ID, NLS.bind(LaunchViewMessages.DebugCoreLaunchObject_CannotTerminate, config.getName()));
+ }
+ }
+ return Status.OK_STATUS;
+ }
+ };
+
+ terminateJob.setUser(true);
+ terminateJob.schedule();
+ }
+ }
+
+ @Override
+ public void relaunch() {
+ ILaunch launch = findLaunch(getId());
+ String launchMode = launch.getLaunchMode();
+ try {
+ launch.terminate();
+ LaunchConfigurationViewPlugin.getExecutor().launchProcess(config, launchMode, true, false, null);
+ } catch (Exception e) {
+ throw new RuntimeException(NLS.bind(LaunchViewMessages.DebugCoreLaunchObject_CannotRelaunch, config.getName()), e);
+ }
+ }
+
+ private static ILaunch findLaunch(String name) {
+ for (ILaunch l : DebugPlugin.getDefault().getLaunchManager().getLaunches()) {
+ if (l.getLaunchConfiguration() == null || l.isTerminated()) {
+ continue;
+ }
+ if (l.getLaunchConfiguration().getName().equals(name)) {
+ return l;
+ }
+ }
+ return null;
+ }
+
+ private static Collection<ILaunch> findTerminateableLaunches(String name) {
+ Collection<ILaunch> result = new ArrayList<>();
+ for (ILaunch l : DebugPlugin.getDefault().getLaunchManager().getLaunches()) {
+ if (l.getLaunchConfiguration() == null || l.isTerminated()) {
+ continue;
+ }
+ if (l.getLaunchConfiguration().getName().equals(name) && l.canTerminate()) {
+ result.add(l);
+ }
+ }
+ return result;
+ }
+
+ @Override
+ public void edit() {
+ // This prefers "debug" mode as the Eclipse infrastructure
+ // requires a group to be given. This covers most launch configurations
+ // as most of them support debug, whereas e.g. "Remote Java Application"
+ // does not support "run". Ant launch configurations in turn do not
+ // support debug...
+ ILaunchGroup group = DebugUITools.getLaunchGroup(config, "debug"); //$NON-NLS-1$
+ if (group == null) {
+ group = DebugUITools.getLaunchGroup(config, "run"); //$NON-NLS-1$
+ }
+ if (group != null) { // Id Debug & run both not supported and only
+ // profile is supported
+ DebugUITools.openLaunchConfigurationDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), config, group.getIdentifier(), null);
+ }
+ }
+
+ @Override
+ public boolean isFavorite() {
+ try {
+ return !config.getAttribute(IDebugUIConstants.ATTR_FAVORITE_GROUPS, Collections.emptyList()).isEmpty();
+ } catch (CoreException e) {
+ return false; // oups
+ }
+ }
+
+ @Override
+ public int compareTo(ILaunchObject o) {
+ if (getId() == null) {
+ Platform.getLog(this.getClass()).warn(NLS.bind(LaunchViewMessages.LaunchObject_ErrorNoId, this), null);
+ if (o.getId() == null) {
+ return 0;
+ }
+ return 1;
+ }
+
+ return getId().compareTo(o.getId());
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreProvider.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreProvider.java
new file mode 100644
index 000000000..67123d023
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/impl/DebugCoreProvider.java
@@ -0,0 +1,156 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.impl;
+
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.function.Supplier;
+import java.util.stream.Collectors;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.debug.core.DebugPlugin;
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.debug.core.ILaunchConfigurationListener;
+import org.eclipse.debug.core.ILaunchConfigurationType;
+import org.eclipse.debug.core.ILaunchManager;
+import org.eclipse.debug.core.ILaunchesListener2;
+import org.eclipse.debug.ui.launchview.internal.AbstractLaunchObjectProvider;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.debug.ui.launchview.services.ILaunchObjectProvider;
+import org.eclipse.e4.core.di.annotations.CanExecute;
+import org.eclipse.e4.core.di.annotations.Execute;
+import org.eclipse.e4.ui.model.application.ui.menu.MDirectMenuItem;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenu;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuFactory;
+import org.osgi.service.component.annotations.Activate;
+import org.osgi.service.component.annotations.Component;
+import org.osgi.service.component.annotations.Deactivate;
+
+@Component(service = ILaunchObjectProvider.class)
+public class DebugCoreProvider extends AbstractLaunchObjectProvider implements ILaunchObjectProvider, ILaunchConfigurationListener, ILaunchesListener2 {
+
+ private final ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager();
+
+ @Activate
+ public void createService() {
+ DebugPlugin.getDefault().getLaunchManager().addLaunchConfigurationListener(this);
+ DebugPlugin.getDefault().getLaunchManager().addLaunchListener(this);
+ }
+
+ @Deactivate
+ public void destroyService() {
+ DebugPlugin.getDefault().getLaunchManager().removeLaunchConfigurationListener(this);
+ DebugPlugin.getDefault().getLaunchManager().removeLaunchListener(this);
+ }
+
+ @Override
+ public Set<ILaunchObject> getLaunchObjects() {
+ try {
+ return Arrays.stream(DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurations()).map(DebugCoreLaunchObject::new).collect(Collectors.toCollection(TreeSet::new));
+ } catch (CoreException e) {
+ org.eclipse.core.runtime.Platform.getLog(this.getClass()).error(LaunchViewMessages.DebugCoreProvider_FailedLookup, e);
+ return Collections.emptySet();
+ }
+ }
+
+ @Override
+ public void launchConfigurationAdded(ILaunchConfiguration configuration) {
+ fireUpdate();
+ }
+
+ @Override
+ public void launchConfigurationChanged(ILaunchConfiguration configuration) {
+ fireUpdate();
+ }
+
+ @Override
+ public void launchConfigurationRemoved(ILaunchConfiguration configuration) {
+ fireUpdate();
+ }
+
+ @Override
+ public int getPriority() {
+ return 0;
+ }
+
+ @Override
+ public void launchesRemoved(ILaunch[] launches) {
+ }
+
+ @Override
+ public void launchesAdded(ILaunch[] launches) {
+ }
+
+ @Override
+ public void launchesChanged(ILaunch[] launches) {
+ fireUpdate(); // process added, thus can terminate
+ }
+
+ @Override
+ public void launchesTerminated(ILaunch[] launches) {
+ fireUpdate();
+ }
+
+ @Override
+ public void contributeViewMenu(Supplier<Set<ILaunchObject>> selected, MMenu menu) {
+ // nothing to contribute for now...
+ }
+
+ @Override
+ public void contributeContextMenu(Supplier<Set<ILaunchObject>> selected, MMenu menu) {
+ MDirectMenuItem delete = MMenuFactory.INSTANCE.createDirectMenuItem();
+ delete.setLabel(LaunchViewMessages.DebugCoreProvider_delete);
+ delete.setTooltip(LaunchViewMessages.DebugCoreProvider_deleteHint);
+ delete.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/icons/delete_exc.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ delete.setObject(new Object() {
+
+ @Execute
+ public void delete() throws CoreException {
+ for (ILaunchObject e : selected.get()) {
+ findLaunchConfiguration(e.getType(), e.getId()).delete();
+ }
+
+ fireUpdate();
+ }
+
+ @CanExecute
+ public boolean isEnabled() {
+ Set<ILaunchObject> elements = selected.get();
+ return !elements.isEmpty() && elements.stream().allMatch(e -> e instanceof DebugCoreLaunchObject && findLaunchConfiguration(e.getType(), e.getId()) != null);
+ }
+ });
+
+ menu.getChildren().add(MMenuFactory.INSTANCE.createMenuSeparator());
+ menu.getChildren().add(delete);
+ }
+
+ ILaunchConfiguration findLaunchConfiguration(ILaunchConfigurationType type, String name) {
+ try {
+ for (ILaunchConfiguration config : manager.getLaunchConfigurations(type)) {
+ if (config.getName().equals(name)) {
+ return config;
+ }
+ }
+ return null;
+ } catch (Exception e) {
+ throw new RuntimeException(LaunchViewMessages.DebugCoreProvider_cannotFetchError, e);
+ }
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/launcher/StandaloneLaunchConfigExecutor.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/launcher/StandaloneLaunchConfigExecutor.java
new file mode 100644
index 000000000..4f76c74f0
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/launcher/StandaloneLaunchConfigExecutor.java
@@ -0,0 +1,220 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.launcher;
+
+import java.io.File;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Platform;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.debug.core.DebugPlugin;
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.debug.core.ILaunchManager;
+import org.eclipse.debug.core.model.IProcess;
+import org.eclipse.debug.ui.launchview.IBackgroundLaunchExecutor;
+import org.eclipse.debug.ui.launchview.internal.FileLogger;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.internal.SpecificLaunchListener;
+import org.eclipse.debug.ui.launchview.internal.StreamHelper;
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Wraps launching a certain ILaunchConfiguration into a job
+ */
+public class StandaloneLaunchConfigExecutor implements IBackgroundLaunchExecutor {
+
+ /**
+ * Starts a launch configuration. The return value is only valid if wait is
+ * <code>true</code>
+ *
+ * @param launchConf the launch configuration
+ * @param mode the launch mode to use.
+ * @param build whether to perform a build before launch
+ * @param wait whether to wait for completion
+ * @param logFile an optional {@link File} to write console output to. May
+ * be <code>null</code>.
+ * @return process exit value if wait is <code>true</code>, always 0 if wait
+ * is <code>false</code>. -1 in case waiting was interrupted.
+ */
+ @Override
+ public int launchProcess(ILaunchConfiguration launchConf, String mode, boolean build, boolean wait, File logFile) {
+ StandaloneLauncherJob launch = new StandaloneLauncherJob(launchConf, mode, build, wait, logFile);
+
+ launch.setPriority(Job.SHORT);
+ launch.schedule();
+ if (wait) {
+ try {
+ launch.join();
+ } catch (InterruptedException e) {
+ return -1;
+ }
+ }
+
+ // when waiting this is the real result, when not it's initialized to 0
+ return launch.getProcessResult();
+ }
+
+ /**
+ * Launches the specified configuration and optionally waits until the end
+ * of execution.
+ *
+ * @param launchConfig launch configuration
+ * @param mode the mode in which to launch
+ * @param monitor progress monitor (only for cancellation)
+ * @param timeout timeout in milliseconds (optional; {@code <=0} means no
+ * timeout)
+ * @param logFile log file where console output is redirected (optional;
+ * {@code null} means no log file)
+ * @return the resulting launch
+ */
+ @SuppressWarnings("resource")
+ private static ILaunch launch(final ILaunchConfiguration launchConfig, final String mode, final IProgressMonitor monitor, final long timeout, final File logFile, boolean build, boolean wait) throws Exception {
+ final FileLogger logger;
+ if (logFile != null) {
+ logger = new FileLogger(logFile);
+ } else {
+ logger = null;
+ }
+
+ Object lock = new Object();
+ ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
+ launchManager.addLaunchListener(new SpecificLaunchListener(launchConfig) {
+
+ private final Set<IProcess> attached = new HashSet<>();
+
+ @Override
+ public void launchChanged(ILaunch launch) {
+ if (logger == null) {
+ return;
+ }
+
+ for (IProcess p : launch.getProcesses()) {
+ if (!attached.contains(p)) {
+ p.getStreamsProxy().getOutputStreamMonitor().addListener(logger);
+ p.getStreamsProxy().getErrorStreamMonitor().addListener(logger);
+
+ attached.add(p);
+ }
+ }
+ }
+
+ @Override
+ public void launchTerminated(ILaunch l) {
+ // found it. make sure that the streams are closed.
+ StreamHelper.closeQuietly(logger);
+ launchManager.removeLaunchListener(this);
+
+ synchronized (lock) {
+ lock.notifyAll();
+ }
+ }
+ });
+
+ final ILaunch launch = launchConfig.launch(mode, monitor, build, true);
+ monitor.subTask(LaunchViewMessages.StandaloneLaunchConfigExecutor_Waiting);
+
+ if (wait) {
+ long timeRunning = 0;
+ while (launch.hasChildren() && !launch.isTerminated()) {
+ if (monitor.isCanceled()) {
+ launch.terminate();
+ }
+ if (timeout > 0 && timeRunning > timeout) {
+ launch.terminate();
+ StreamHelper.closeQuietly(logger);
+ throw new InterruptedException(NLS.bind(LaunchViewMessages.StandaloneLaunchConfigExecutor_Timeout, timeout));
+ }
+ synchronized (lock) {
+ lock.wait(500);
+ }
+ timeRunning += 500;
+ }
+ }
+ return launch;
+ }
+
+ /**
+ * Job that launches a {@link LaunchConfig} in the background.
+ */
+ private static class StandaloneLauncherJob extends Job {
+
+ private final ILaunchConfiguration config;
+
+ private int result = 0;
+ private final String mode;
+ private final boolean build;
+ private final boolean wait;
+
+ private final File logFile;
+
+ /**
+ * Creates a new {@link StandaloneLauncherJob} to monitor an await
+ * launching of {@link ILaunchConfiguration}s
+ *
+ * @param config the {@link ILaunchConfiguration} to start
+ * @param mode the mode in which to launch
+ * @param build whether to build before launch
+ * @param wait whether to keep the job alive until the associated
+ * {@link ILaunch} terminates.
+ * @param logFile an optional {@link File} to write console output to.
+ * May be <code>null</code>.
+ */
+ StandaloneLauncherJob(ILaunchConfiguration config, String mode, boolean build, boolean wait, File logFile) {
+ super(NLS.bind(LaunchViewMessages.StandaloneLaunchConfigExecutor_Launch, config.getName()));
+ this.config = config;
+ this.build = build;
+ this.wait = wait;
+ this.logFile = logFile;
+ this.mode = mode;
+ }
+
+ int getProcessResult() {
+ return result;
+ }
+
+ @Override
+ protected IStatus run(IProgressMonitor monitor) {
+ try {
+ monitor.beginTask(NLS.bind(LaunchViewMessages.StandaloneLaunchConfigExecutor_Launching, config.getName()), IProgressMonitor.UNKNOWN);
+
+ ILaunch launch = launch(config, mode, monitor, 0, logFile, build, wait);
+
+ if (wait) {
+ IProcess[] ps = launch.getProcesses();
+
+ // in our scenarios it NEVER happens that there is more than
+ // one process
+ for (IProcess p : ps) {
+ if (p.getExitValue() != 0) {
+ result = p.getExitValue();
+ }
+ }
+ }
+ } catch (Exception e) {
+ Platform.getLog(this.getClass()).error(NLS.bind(LaunchViewMessages.StandaloneLaunchConfigExecutor_FailedLaunching, config.getName()), e);
+ } finally {
+ monitor.done();
+ }
+
+ // always return OK, to avoid error messages
+ return Status.OK_STATUS;
+ }
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/messages.properties b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/messages.properties
new file mode 100644
index 000000000..e2112f50a
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/messages.properties
@@ -0,0 +1,37 @@
+###############################################################################
+# Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+#
+# This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License 2.0
+# which accompanies this distribution, and is available at
+# https://www.eclipse.org/legal/epl-2.0/
+#
+# SPDX-License-Identifier: EPL-2.0
+#
+# Contributors:
+# SSI Schaefer IT Solutions GmbH
+###############################################################################
+
+DebugCoreLaunchObject_CannotGetType=Cannot get type of {0}
+DebugCoreLaunchObject_CannotRelaunch=Cannot relaunch {0}
+DebugCoreLaunchObject_CannotTerminate=Cannot terminate {0}
+DebugCoreLaunchObject_Terminate=Terminate {0}
+DebugCoreProvider_cannotFetchError=Cannot fetch existing launch configurations
+DebugCoreProvider_delete=De&lete
+DebugCoreProvider_deleteHint=Deletes the selected launch configuration
+DebugCoreProvider_FailedLookup=Cannot fetch launch configurations from Eclipse.
+EditAction_Edit=&Edit...
+FileLogger_FailedAppend=Failed to append '{0}' to log file.
+LaunchAction_FailedFetchLaunchDelegates=Problem retreiving launch delegates
+LaunchObject_ErrorNoId=LaunchObject with null id: {0}
+LaunchObjectFavoriteContainerModel_Favorites=Favorites
+LaunchView_Refresh=Refresh
+LaunchView_Reset=Reset
+LaunchView_TerminateAll=Terminate All
+RelaunchAction_TerminateRelaunch=Terminate && Relaun&ch
+StandaloneLaunchConfigExecutor_FailedLaunching=Failed launching {0}
+StandaloneLaunchConfigExecutor_Launch=Launch {0}
+StandaloneLaunchConfigExecutor_Launching=Launching {0}
+StandaloneLaunchConfigExecutor_Timeout=execution exceeded maximum time of {0} ms
+StandaloneLaunchConfigExecutor_Waiting=waiting for processes...
+TerminateAction_Terminate=&Terminate
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/ILaunchModel.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/ILaunchModel.java
new file mode 100644
index 000000000..3acfa28c9
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/ILaunchModel.java
@@ -0,0 +1,27 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.model;
+
+/**
+ * Service which controls the lifecycle of the model which the view is based on.
+ */
+public interface ILaunchModel {
+
+ /**
+ * @return the current model. Never <code>null</code>. Always created from
+ * the current state.
+ */
+ public LaunchObjectContainerModel getModel();
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectContainerModel.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectContainerModel.java
new file mode 100644
index 000000000..ce419c510
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectContainerModel.java
@@ -0,0 +1,69 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.model;
+
+import java.util.Set;
+import java.util.TreeSet;
+
+import org.eclipse.debug.core.ILaunchConfigurationType;
+import org.eclipse.debug.internal.ui.DebugPluginImages;
+import org.eclipse.swt.graphics.Image;
+
+public class LaunchObjectContainerModel extends LaunchObjectModel {
+
+ private final Set<LaunchObjectModel> children = new TreeSet<>((a, b) -> {
+ if (a instanceof LaunchObjectFavoriteContainerModel) {
+ return -1;
+ } else if (b instanceof LaunchObjectFavoriteContainerModel) {
+ return 1;
+ }
+
+ return a.getLabel().getString().compareTo(b.getLabel().getString());
+ });
+ private final ILaunchConfigurationType type;
+
+ LaunchObjectContainerModel() {
+ this(null, null);
+ }
+
+ LaunchObjectContainerModel(ILaunchConfigurationType type) {
+ super(type.getName(), type.getIdentifier(), DebugPluginImages.getImage(type.getIdentifier()));
+ this.type = type;
+ }
+
+ protected LaunchObjectContainerModel(String id, Image image) {
+ super(id, null, image);
+ this.type = null;
+ }
+
+ public void addChild(LaunchObjectModel model) {
+ children.add(model);
+ }
+
+ public Set<LaunchObjectModel> getChildren() {
+ return children;
+ }
+
+ public LaunchObjectContainerModel getContainerFor(LaunchObjectModel m) {
+ for (LaunchObjectModel child : children) {
+ if (child instanceof LaunchObjectContainerModel) {
+ if (m.getObject().getType().equals(((LaunchObjectContainerModel) child).type)) {
+ return (LaunchObjectContainerModel) child;
+ }
+ }
+ }
+ return null;
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectFavoriteContainerModel.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectFavoriteContainerModel.java
new file mode 100644
index 000000000..a62cb06b1
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectFavoriteContainerModel.java
@@ -0,0 +1,30 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.model;
+
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+
+public class LaunchObjectFavoriteContainerModel extends LaunchObjectContainerModel {
+
+ private static final Image FAV_ICON = AbstractUIPlugin.imageDescriptorFromPlugin(LaunchViewBundleInfo.PLUGIN_ID, "icons/favorite_star.png") //$NON-NLS-1$
+ .createImage();
+
+ public LaunchObjectFavoriteContainerModel() {
+ super(LaunchViewMessages.LaunchObjectFavoriteContainerModel_Favorites, FAV_ICON);
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectModel.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectModel.java
new file mode 100644
index 000000000..298f5c361
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchObjectModel.java
@@ -0,0 +1,101 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.model;
+
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.jface.viewers.StyledString;
+import org.eclipse.swt.graphics.Image;
+
+public class LaunchObjectModel implements Comparable<LaunchObjectModel> {
+
+ private final String id;
+ private final Image image;
+
+ private final ILaunchObject object;
+ private final String internalId;
+
+ LaunchObjectModel(ILaunchObject obj) {
+ this.id = obj.getId();
+ this.internalId = obj.getId();
+ this.image = obj.getImage();
+ this.object = obj;
+ }
+
+ LaunchObjectModel(String id, String internalId, Image image) {
+ this.id = id;
+ this.internalId = internalId;
+ this.image = image;
+ this.object = null;
+ }
+
+ public StyledString getLabel() {
+ if (object == null) {
+ return new StyledString(id);
+ }
+ return object.getLabel();
+ }
+
+ public Image getImage() {
+ return image;
+ }
+
+ public ILaunchObject getObject() {
+ return object;
+ }
+
+ @Override
+ public String toString() {
+ return uniqueId() + "(" + getObject() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ @Override
+ public int compareTo(LaunchObjectModel o) {
+ return uniqueId().compareTo(o.uniqueId());
+ }
+
+ public String uniqueId() {
+ if (id == null && internalId == null) {
+ return "root"; //$NON-NLS-1$
+ } else if (internalId != null) {
+ return internalId;
+ } else if (object == null || object.getType() == null) {
+ return id;
+ }
+ return object.getType().getIdentifier() + "." + id; //$NON-NLS-1$
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + (uniqueId().hashCode());
+ return result;
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj) {
+ return true;
+ }
+ if (obj == null) {
+ return false;
+ }
+ if (getClass() != obj.getClass()) {
+ return false;
+ }
+ LaunchObjectModel other = (LaunchObjectModel) obj;
+ return uniqueId().equals(other.uniqueId());
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchViewModel.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchViewModel.java
new file mode 100644
index 000000000..a017d99c1
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/model/LaunchViewModel.java
@@ -0,0 +1,134 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.model;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.stream.Collectors;
+
+import org.eclipse.debug.ui.launchview.services.ILaunchObjectProvider;
+import org.eclipse.ui.IWorkbench;
+import org.osgi.service.component.annotations.Activate;
+import org.osgi.service.component.annotations.Component;
+import org.osgi.service.component.annotations.Deactivate;
+import org.osgi.service.component.annotations.Reference;
+import org.osgi.service.component.annotations.ReferenceCardinality;
+import org.osgi.service.component.annotations.ReferencePolicy;
+import org.osgi.service.component.annotations.ReferencePolicyOption;
+
+@Component(immediate = true)
+public class LaunchViewModel implements ILaunchModel {
+
+ public Set<ILaunchObjectProvider> providers = new TreeSet<>((a, b) -> {
+ int x = Integer.compare(b.getPriority(), a.getPriority());
+ if (x == 0) {
+ x = a.getClass().getName().compareTo(b.getClass().getName());
+ }
+ return x;
+ });
+ private static LaunchViewModel service;
+
+ private final List<Runnable> updateListeners = new ArrayList<>();
+ private final Runnable providerUpdateListener = () -> fireUpdate();
+
+ public Set<ILaunchObjectProvider> getProviders() {
+ return providers;
+ }
+
+ @Override
+ public LaunchObjectContainerModel getModel() {
+ LaunchObjectContainerModel root = new LaunchObjectContainerModel();
+
+ // find all objects from services, sorted by prio (highest prio first).
+ Set<LaunchObjectModel> allObjects = providers.stream().map(p -> p.getLaunchObjects()).flatMap(o -> o.stream().map(LaunchObjectModel::new)).collect(Collectors.toCollection(TreeSet::new));
+
+ // create favorite container
+ LaunchObjectFavoriteContainerModel favorites = new LaunchObjectFavoriteContainerModel();
+ root.addChild(favorites);
+
+ // create all required type containers
+ allObjects.stream().map(o -> o.getObject().getType()).distinct().map(LaunchObjectContainerModel::new).forEach(root::addChild);
+
+ // create all nodes
+ allObjects.stream().forEach(m -> {
+ LaunchObjectContainerModel container = root.getContainerFor(m);
+ if (container == null) {
+ return;
+ }
+ container.addChild(m);
+ if (m.getObject() != null && m.getObject().isFavorite()) {
+ favorites.addChild(m);
+ }
+ });
+
+ // this is the root :)
+ return root;
+ }
+
+ @Reference(service = ILaunchObjectProvider.class, cardinality = ReferenceCardinality.MULTIPLE, policy = ReferencePolicy.DYNAMIC, policyOption = ReferencePolicyOption.GREEDY)
+ public void addLaunchObjectProvider(ILaunchObjectProvider svc) {
+ providers.add(svc);
+ svc.addUpdateListener(providerUpdateListener);
+
+ fireUpdate();
+ }
+
+ public void removeLaunchObjectProvider(ILaunchObjectProvider svc) {
+ providers.remove(svc);
+ svc.removeUpdateListener(providerUpdateListener);
+
+ fireUpdate();
+ }
+
+ @Reference(service = IWorkbench.class, cardinality = ReferenceCardinality.MANDATORY, policy = ReferencePolicy.STATIC, unbind = "unsetWorkbench")
+ public void setWorkbench(@SuppressWarnings("unused") IWorkbench svc) {
+ // this reference is just a marker to control startup order.
+ // this is required, otherwise this service activates so early, that the
+ // prompt for the workspace location is no longer shown (as the location
+ // is accessed indirectly before the prompt, which initializes it to a
+ // default).
+ }
+
+ public void unsetWorkbench(@SuppressWarnings("unused") IWorkbench svc) {
+ }
+
+ @Activate
+ public void activate() {
+ service = this;
+ }
+
+ @Deactivate
+ public void deactivate() {
+ service = null;
+ }
+
+ public void addUpdateListener(Runnable r) {
+ updateListeners.add(r);
+ }
+
+ public void removeUpdateListener(Runnable r) {
+ updateListeners.remove(r);
+ }
+
+ private void fireUpdate() {
+ updateListeners.forEach(Runnable::run);
+ }
+
+ public static LaunchViewModel getService() {
+ return service;
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/EditAction.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/EditAction.java
new file mode 100644
index 000000000..3b08bd01a
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/EditAction.java
@@ -0,0 +1,50 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.e4.core.di.annotations.CanExecute;
+import org.eclipse.e4.core.di.annotations.Execute;
+import org.eclipse.e4.ui.model.application.ui.menu.MDirectMenuItem;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuFactory;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuItem;
+
+public class EditAction {
+
+ private LaunchViewImpl view;
+
+ public EditAction(LaunchViewImpl view) {
+ this.view = view;
+ }
+
+ public MMenuItem asMMenuItem() {
+ MDirectMenuItem item = MMenuFactory.INSTANCE.createDirectMenuItem();
+ item.setLabel(LaunchViewMessages.EditAction_Edit);
+ item.setObject(this);
+ item.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/icons/edit_template.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ return item;
+ }
+
+ @CanExecute
+ public boolean isEnabled() {
+ return view.get().size() == 1;
+ }
+
+ @Execute
+ public void run() {
+ view.get().iterator().next().edit();
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchAction.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchAction.java
new file mode 100644
index 000000000..df92b38b6
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchAction.java
@@ -0,0 +1,96 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import java.util.Collections;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeMap;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.Platform;
+import org.eclipse.debug.core.ILaunchMode;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.e4.core.di.annotations.CanExecute;
+import org.eclipse.e4.core.di.annotations.Execute;
+import org.eclipse.e4.ui.model.application.ui.menu.MDirectMenuItem;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuFactory;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuItem;
+
+public class LaunchAction {
+
+ private static final Map<String, String> COMMON_MODE_ICONS;
+
+ static {
+ COMMON_MODE_ICONS = new TreeMap<>();
+ COMMON_MODE_ICONS.put("run", "icons/run_exc.png"); //$NON-NLS-1$//$NON-NLS-2$
+ COMMON_MODE_ICONS.put("debug", "icons/debug_exc.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ COMMON_MODE_ICONS.put("profile", "icons/profile_exc.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ COMMON_MODE_ICONS.put("coverage", "icons/coverage.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ private final ILaunchMode mode;
+ private LaunchViewImpl view;
+
+ public LaunchAction(ILaunchMode mode, LaunchViewImpl view) {
+ this.mode = mode;
+ this.view = view;
+ }
+
+ public MMenuItem asMMenuItem() {
+ MDirectMenuItem item = MMenuFactory.INSTANCE.createDirectMenuItem();
+ item.setLabel(mode.getLabel());
+ item.setObject(this);
+
+ if (COMMON_MODE_ICONS.containsKey(mode.getIdentifier())) {
+ item.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/" + COMMON_MODE_ICONS.get(mode.getIdentifier())); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ return item;
+ }
+
+ @CanExecute
+ public boolean isEnabled() {
+ Set<ILaunchObject> elements = view.get();
+ return !elements.isEmpty() && elements.stream().allMatch((m) -> {
+ try {
+ return m.getType().getDelegates(Collections.singleton(mode.getIdentifier())).length > 0;
+ } catch (CoreException e) {
+ Platform.getLog(this.getClass()).warn(LaunchViewMessages.LaunchAction_FailedFetchLaunchDelegates, e);
+ return false;
+ }
+ });
+ }
+
+ @Execute
+ public void run() {
+ Set<ILaunchObject> objects = view.get();
+ for (ILaunchObject m : objects) {
+ m.launch(mode);
+
+ if (objects.size() > 1) {
+ // PDE has a nasty bug. If launching too fast, it tries to
+ // overwrite the last configurations platform.xml
+ try {
+ Thread.sleep(2_000);
+ } catch (InterruptedException ie) {
+ // ignored
+ }
+ }
+ }
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewContentProvider.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewContentProvider.java
new file mode 100644
index 000000000..d426a71ae
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewContentProvider.java
@@ -0,0 +1,45 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import org.eclipse.debug.ui.launchview.internal.model.LaunchObjectContainerModel;
+import org.eclipse.jface.viewers.ITreeContentProvider;
+
+public class LaunchViewContentProvider implements ITreeContentProvider {
+
+ @Override
+ public Object[] getElements(Object inputElement) {
+ return getChildren(inputElement);
+ }
+
+ @Override
+ public Object[] getChildren(Object parentElement) {
+ if (parentElement instanceof LaunchObjectContainerModel) {
+ return ((LaunchObjectContainerModel) parentElement).getChildren().toArray();
+ }
+
+ return null;
+ }
+
+ @Override
+ public Object getParent(Object element) {
+ return null;
+ }
+
+ @Override
+ public boolean hasChildren(Object element) {
+ return (element instanceof LaunchObjectContainerModel && !((LaunchObjectContainerModel) element).getChildren().isEmpty());
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewImpl.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewImpl.java
new file mode 100644
index 000000000..e50e3d356
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewImpl.java
@@ -0,0 +1,327 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2022 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ * IBM Corporation - bug fixes
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Objects;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.function.Supplier;
+import java.util.stream.Collectors;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.PreDestroy;
+import javax.inject.Inject;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.debug.core.DebugPlugin;
+import org.eclipse.debug.core.ILaunchMode;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.internal.model.LaunchObjectContainerModel;
+import org.eclipse.debug.ui.launchview.internal.model.LaunchObjectFavoriteContainerModel;
+import org.eclipse.debug.ui.launchview.internal.model.LaunchObjectModel;
+import org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel;
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.e4.core.di.annotations.Execute;
+import org.eclipse.e4.ui.di.Focus;
+import org.eclipse.e4.ui.model.application.ui.basic.MPart;
+import org.eclipse.e4.ui.model.application.ui.menu.MDirectMenuItem;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenu;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuFactory;
+import org.eclipse.e4.ui.model.application.ui.menu.MPopupMenu;
+import org.eclipse.e4.ui.services.EMenuService;
+import org.eclipse.jface.viewers.DelegatingStyledCellLabelProvider;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.jface.viewers.ITreeSelection;
+import org.eclipse.jface.viewers.TreePath;
+import org.eclipse.jface.viewers.Viewer;
+import org.eclipse.jface.viewers.ViewerComparator;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.ui.dialogs.FilteredTree;
+import org.eclipse.ui.dialogs.PatternFilter;
+
+public class LaunchViewImpl implements Supplier<Set<ILaunchObject>> {
+
+ private static final String CONTEXT_MENU_ID = "LaunchViewContextMenu"; //$NON-NLS-1$
+
+ private LaunchViewModel model;
+ private final Runnable reset = () -> queueReset();
+ private final Job resetJob;
+ private FilteredTree tree;
+
+ @Inject
+ EMenuService menuService;
+
+ public LaunchViewImpl() {
+ resetJob = new Job(LaunchViewMessages.LaunchView_Reset) {
+
+ @Override
+ protected IStatus run(IProgressMonitor monitor) {
+ reset();
+ return Status.OK_STATUS;
+ }
+ };
+
+ resetJob.setSystem(true);
+ }
+
+ @PostConstruct
+ public void createView(Composite parent, MPart part) {
+ model = LaunchViewModel.getService();
+ model.addUpdateListener(reset);
+
+ tree = new FilteredTree(parent, SWT.BORDER | SWT.MULTI, new PatternFilter() {
+
+ @Override
+ public void setPattern(String pattern) {
+ if (pattern != null && !pattern.isEmpty() && pattern.indexOf("*") != 0 && pattern.indexOf("?") != 0 //$NON-NLS-1$ //$NON-NLS-2$
+ && pattern.indexOf(".") != 0) { //$NON-NLS-1$
+ super.setPattern("*" + pattern); //$NON-NLS-1$
+ } else {
+ super.setPattern(pattern);
+ }
+ }
+
+ @Override
+ protected boolean isLeafMatch(Viewer viewer, Object element) {
+ if (!(element instanceof LaunchObjectModel) || element instanceof LaunchObjectContainerModel) {
+ return false;
+ }
+ String txt = ((LaunchObjectModel) element).getLabel().toString();
+ return wordMatches(txt);
+ }
+ }, true, true);
+ tree.getViewer().setContentProvider(new LaunchViewContentProvider());
+ tree.getViewer().setLabelProvider(new DelegatingStyledCellLabelProvider(new LaunchViewLabelProvider()));
+ tree.getViewer().getTree().setLayout(new GridLayout());
+ tree.getViewer().getTree().setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
+ createMenus(part);
+
+ tree.getViewer().addDoubleClickListener((e) -> {
+ ITreeSelection selection = tree.getViewer().getStructuredSelection();
+ if (selection.isEmpty()) {
+ return;
+ }
+
+ for (Object selected : selection.toList()) {
+ if (selected instanceof LaunchObjectContainerModel) {
+ tree.getViewer().setExpandedState(selected, !tree.getViewer().getExpandedState(selected));
+ return; // only supported for single element double-click
+ }
+ }
+
+ new LaunchAction(DebugPlugin.getDefault().getLaunchManager().getLaunchMode("run"), LaunchViewImpl.this).run(); //$NON-NLS-1$
+ });
+ tree.getViewer().setComparator(new ViewerComparator(String.CASE_INSENSITIVE_ORDER));
+
+ reset();
+ }
+
+ @Focus
+ public void onFocus() {
+ tree.getViewer().getControl().setFocus();
+ }
+
+ private void createMenus(MPart part) {
+ part.getMenus().clear(); // clear persisted state
+
+ // View menu
+ MMenu viewMenu = MMenuFactory.INSTANCE.createMenu();
+ viewMenu.setElementId("menu:" + part.getElementId()); //$NON-NLS-1$
+ viewMenu.getTags().add("ViewMenu"); //$NON-NLS-1$
+
+ MDirectMenuItem refresh = MMenuFactory.INSTANCE.createDirectMenuItem();
+ refresh.setLabel(LaunchViewMessages.LaunchView_Refresh);
+ refresh.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/icons/refresh.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ refresh.setObject(new RefreshHandler());
+
+ MDirectMenuItem terminateAll = MMenuFactory.INSTANCE.createDirectMenuItem();
+ terminateAll.setLabel(LaunchViewMessages.LaunchView_TerminateAll);
+ terminateAll.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/icons/terminate_all_co.png"); //$NON-NLS-1$ //$NON-NLS-2$
+ terminateAll.setObject(new TerminateAllHandler());
+
+ viewMenu.getChildren().add(refresh);
+ viewMenu.getChildren().add(MMenuFactory.INSTANCE.createMenuSeparator());
+ viewMenu.getChildren().add(terminateAll);
+
+ // contributions from providers
+ model.getProviders().forEach(p -> p.contributeViewMenu(this, viewMenu));
+
+ part.getMenus().add(viewMenu);
+
+ // Context menu
+ MPopupMenu ctxMenu = MMenuFactory.INSTANCE.createPopupMenu();
+ ctxMenu.setElementId(CONTEXT_MENU_ID);
+
+ // one menu item for each mode that launches all selected
+ for (ILaunchMode mode : getPreSortedLaunchModes()) {
+ ctxMenu.getChildren().add(new LaunchAction(mode, this).asMMenuItem());
+ }
+
+ ctxMenu.getChildren().add(MMenuFactory.INSTANCE.createMenuSeparator());
+ ctxMenu.getChildren().add(new RelaunchAction(this).asMMenuItem());
+ ctxMenu.getChildren().add(new TerminateAction(this).asMMenuItem());
+ ctxMenu.getChildren().add(MMenuFactory.INSTANCE.createMenuSeparator());
+ ctxMenu.getChildren().add(new EditAction(this).asMMenuItem());
+
+ // contributions from providers
+ model.getProviders().forEach(p -> p.contributeContextMenu(this, ctxMenu));
+
+ part.getMenus().add(ctxMenu);
+
+ menuService.registerContextMenu(tree.getViewer().getControl(), CONTEXT_MENU_ID);
+ }
+
+ private List<ILaunchMode> getPreSortedLaunchModes() {
+ List<ILaunchMode> modes = new ArrayList<>();
+
+ ILaunchMode run = null;
+ ILaunchMode debug = null;
+ ILaunchMode profile = null;
+ ILaunchMode coverage = null;
+
+ ILaunchMode[] launchModes = DebugPlugin.getDefault().getLaunchManager().getLaunchModes();
+ List<ILaunchMode> others = new ArrayList<>();
+
+ for (ILaunchMode m : launchModes) {
+ switch (m.getIdentifier()) {
+ case "run": //$NON-NLS-1$
+ run = m;
+ break;
+ case "debug": //$NON-NLS-1$
+ debug = m;
+ break;
+ case "profile": //$NON-NLS-1$
+ profile = m;
+ break;
+ case "coverage": //$NON-NLS-1$
+ coverage = m;
+ break;
+ default:
+ others.add(m);
+ }
+ }
+
+ if (run != null) {
+ modes.add(run);
+ }
+ if (debug != null) {
+ modes.add(debug);
+ }
+ if (coverage != null) {
+ modes.add(coverage);
+ }
+ if (profile != null) {
+ modes.add(profile);
+ }
+ modes.addAll(others);
+ return modes;
+ }
+
+ private void queueReset() {
+ resetJob.cancel();
+ resetJob.schedule(100);
+ }
+
+ @Override
+ public Set<ILaunchObject> get() {
+ ISelection selection = tree.getViewer().getSelection();
+ IStructuredSelection structuredSelection = (IStructuredSelection) selection;
+ if (structuredSelection.isEmpty()) {
+ return Collections.emptySet();
+ }
+
+ Set<LaunchObjectModel> elements = new TreeSet<>();
+ // expand selection if containers are selected
+ for (Object selected : structuredSelection.toList()) {
+ if (selected instanceof LaunchObjectContainerModel) {
+ // skip container nodes (Bug 577581)
+ } else if (selected instanceof LaunchObjectModel) {
+ elements.add((LaunchObjectModel) selected);
+ }
+ }
+
+ return elements.stream().map(m -> m.getObject()).filter(Objects::nonNull).collect(Collectors.toCollection(TreeSet::new));
+ }
+
+ private synchronized void reset() {
+ if (tree == null || tree.isDisposed()) {
+ return;
+ }
+ tree.getDisplay().syncExec(() -> {
+ tree.getViewer().getTree().setRedraw(false);
+ try {
+ TreePath[] exp = tree.getViewer().getExpandedTreePaths();
+ tree.getViewer().setInput(model.getModel());
+ tree.getViewer().setExpandedTreePaths(exp);
+ } finally {
+ tree.getViewer().getTree().setRedraw(true);
+ }
+ });
+ }
+
+ @PreDestroy
+ public void destroy() {
+ model.removeUpdateListener(reset);
+ }
+
+ private final class RefreshHandler {
+
+ @Execute
+ public void handle() {
+ reset();
+ }
+ }
+
+ private final class TerminateAllHandler {
+
+ @Execute
+ public void handle() {
+ LaunchObjectContainerModel root = (LaunchObjectContainerModel) tree.getViewer().getInput();
+ if (root == null) {
+ return;
+ }
+
+ for (LaunchObjectModel container : root.getChildren()) {
+ if (container instanceof LaunchObjectFavoriteContainerModel) {
+ continue;
+ }
+
+ if (container instanceof LaunchObjectContainerModel) {
+ for (LaunchObjectModel m : ((LaunchObjectContainerModel) container).getChildren()) {
+ if (m.getObject() == null) {
+ continue;
+ }
+
+ if (m.getObject().canTerminate()) {
+ m.getObject().terminate();
+ }
+ }
+ }
+ }
+ }
+ }
+
+} \ No newline at end of file
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewLabelProvider.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewLabelProvider.java
new file mode 100644
index 000000000..4d8b1759e
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/LaunchViewLabelProvider.java
@@ -0,0 +1,72 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.model.LaunchObjectModel;
+import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.resource.ImageRegistry;
+import org.eclipse.jface.viewers.BaseLabelProvider;
+import org.eclipse.jface.viewers.DecorationOverlayIcon;
+import org.eclipse.jface.viewers.DelegatingStyledCellLabelProvider.IStyledLabelProvider;
+import org.eclipse.jface.viewers.IDecoration;
+import org.eclipse.jface.viewers.StyledString;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+
+public class LaunchViewLabelProvider extends BaseLabelProvider implements IStyledLabelProvider {
+
+ private static final ImageDescriptor ICON_RUNNING = AbstractUIPlugin.imageDescriptorFromPlugin(LaunchViewBundleInfo.PLUGIN_ID, "icons/run_co.png"); //$NON-NLS-1$
+
+ private final ImageRegistry perConfig = new ImageRegistry();
+
+ @Override
+ public StyledString getStyledText(Object element) {
+ if (element instanceof LaunchObjectModel) {
+ return ((LaunchObjectModel) element).getLabel();
+ }
+
+ return null;
+ }
+
+ @Override
+ public Image getImage(Object element) {
+ if (element instanceof LaunchObjectModel) {
+ LaunchObjectModel obj = (LaunchObjectModel) element;
+ if (obj.getObject() != null && obj.getObject().canTerminate()) {
+ return getCachedRunningImage(obj);
+ }
+
+ return obj.getImage();
+ }
+
+ return null;
+ }
+
+ private Image getCachedRunningImage(LaunchObjectModel obj) {
+ Image img = perConfig.get(obj.getObject().getId());
+ if (img == null) {
+ img = new DecorationOverlayIcon(obj.getImage(), ICON_RUNNING, IDecoration.TOP_LEFT).createImage();
+ perConfig.put(obj.getObject().getId(), img);
+ }
+ return img;
+ }
+
+ @Override
+ public void dispose() {
+ perConfig.dispose();
+ super.dispose();
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/RelaunchAction.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/RelaunchAction.java
new file mode 100644
index 000000000..210397aad
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/RelaunchAction.java
@@ -0,0 +1,57 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import java.util.Set;
+
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.e4.core.di.annotations.CanExecute;
+import org.eclipse.e4.core.di.annotations.Execute;
+import org.eclipse.e4.ui.model.application.ui.menu.MDirectMenuItem;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuFactory;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuItem;
+
+public class RelaunchAction {
+
+ private LaunchViewImpl view;
+
+ public RelaunchAction(LaunchViewImpl view) {
+ this.view = view;
+ }
+
+ public MMenuItem asMMenuItem() {
+ MDirectMenuItem item = MMenuFactory.INSTANCE.createDirectMenuItem();
+ item.setLabel(LaunchViewMessages.RelaunchAction_TerminateRelaunch);
+ item.setEnabled(isEnabled());
+ item.setObject(this);
+
+ item.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/icons/term_restart.png"); //$NON-NLS-1$ //$NON-NLS-2$
+
+ return item;
+ }
+
+ @CanExecute
+ public boolean isEnabled() {
+ Set<ILaunchObject> elements = view.get();
+ return !elements.isEmpty() && elements.stream().allMatch(m -> m.canTerminate());
+ }
+
+ @Execute
+ public void run() {
+ view.get().stream().forEach(m -> m.relaunch());
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/TerminateAction.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/TerminateAction.java
new file mode 100644
index 000000000..5544e2754
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/internal/view/TerminateAction.java
@@ -0,0 +1,57 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.internal.view;
+
+import java.util.Set;
+
+import org.eclipse.debug.ui.launchview.internal.LaunchViewBundleInfo;
+import org.eclipse.debug.ui.launchview.internal.LaunchViewMessages;
+import org.eclipse.debug.ui.launchview.services.ILaunchObject;
+import org.eclipse.e4.core.di.annotations.CanExecute;
+import org.eclipse.e4.core.di.annotations.Execute;
+import org.eclipse.e4.ui.model.application.ui.menu.MDirectMenuItem;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuFactory;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenuItem;
+
+public class TerminateAction {
+
+ private LaunchViewImpl view;
+
+ public TerminateAction(LaunchViewImpl view) {
+ this.view = view;
+ }
+
+ public MMenuItem asMMenuItem() {
+ MDirectMenuItem item = MMenuFactory.INSTANCE.createDirectMenuItem();
+ item.setLabel(LaunchViewMessages.TerminateAction_Terminate);
+ item.setEnabled(isEnabled());
+ item.setObject(this);
+
+ item.setIconURI("platform:/plugin/" + LaunchViewBundleInfo.PLUGIN_ID + "/icons/terminate_co.png"); //$NON-NLS-1$ //$NON-NLS-2$
+
+ return item;
+ }
+
+ @CanExecute
+ public boolean isEnabled() {
+ Set<ILaunchObject> elements = view.get();
+ return !elements.isEmpty() && elements.stream().allMatch(m -> m.canTerminate());
+ }
+
+ @Execute
+ public void run() {
+ view.get().forEach(e -> e.terminate());
+ }
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObject.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObject.java
new file mode 100644
index 000000000..9bfc2f9c9
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObject.java
@@ -0,0 +1,94 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.services;
+
+import org.eclipse.debug.core.ILaunchConfigurationType;
+import org.eclipse.debug.core.ILaunchMode;
+import org.eclipse.debug.internal.ui.DebugPluginImages;
+import org.eclipse.jface.viewers.StyledString;
+import org.eclipse.swt.graphics.Image;
+
+/**
+ * A {@link ILaunchObject} describes a single launch-able "thing".
+ * <p>
+ * Instances of this interface are provided by extensions by a custom
+ * {@link ILaunchObjectProvider} implementation in the extension.
+ *
+ * @since 1.0.2
+ */
+public interface ILaunchObject extends Comparable<ILaunchObject> {
+
+ /**
+ * @return the unique ID of the {@link ILaunchObject}.
+ */
+ public String getId();
+
+ /**
+ * @return a label for display purposes.
+ */
+ public StyledString getLabel();
+
+ /**
+ * @return an image, usually derived from the type of the launch
+ */
+ default public Image getImage() {
+ if (getType() == null) {
+ return null;
+ }
+ return DebugPluginImages.getImage(getType().getIdentifier());
+ }
+
+ /**
+ * @return the underlying {@link ILaunchConfigurationType} of the launch
+ */
+ public ILaunchConfigurationType getType();
+
+ /**
+ * Launch the {@link ILaunchObject} in the specified mode.
+ *
+ * @param mode in which mode to launch
+ */
+ public void launch(ILaunchMode mode);
+
+ /**
+ * @return whether this {@link ILaunchObject} supports termination by the
+ * user.
+ */
+ public boolean canTerminate();
+
+ /**
+ * Terminates all running instances of this {@link ILaunchObject}.
+ */
+ public void terminate();
+
+ /**
+ * First terminates and then launches this {@link ILaunchObject} if it is
+ * running already.
+ */
+ public void relaunch();
+
+ /**
+ * Triggers custom editing UI logic for the {@link ILaunchObject}. Might open
+ * an editor, or a dialog, or do something completely different depending on
+ * the implementation.
+ */
+ public void edit();
+
+ /**
+ * @return whether this {@link ILaunchObject} should be displayed in the
+ * favorite container of the view.
+ */
+ public boolean isFavorite();
+
+}
diff --git a/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObjectProvider.java b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObjectProvider.java
new file mode 100644
index 000000000..653f42449
--- /dev/null
+++ b/org.eclipse.debug.ui.launchview/src/org/eclipse/debug/ui/launchview/services/ILaunchObjectProvider.java
@@ -0,0 +1,77 @@
+/*******************************************************************************
+ * Copyright (c) 2017, 2019 SSI Schaefer IT Solutions GmbH and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * SSI Schaefer IT Solutions GmbH
+ *******************************************************************************/
+package org.eclipse.debug.ui.launchview.services;
+
+import java.util.Set;
+import java.util.function.Supplier;
+
+import org.eclipse.debug.ui.launchview.internal.view.LaunchViewImpl;
+import org.eclipse.e4.ui.model.application.ui.menu.MMenu;
+
+/**
+ * Provides different {@link ILaunchObject} instances to the view for display.
+ * Also allows some interaction with the view by means of an update listener and
+ * menu contributions.
+ * <p>
+ * Contribute extensions to the view by implementing this interface and
+ * registering it as a {@literal @Component} (declarative service).
+ *
+ * @since 1.0.2
+ */
+public interface ILaunchObjectProvider {
+
+ /**
+ * @return all {@link ILaunchObject}s that this provider contributes to the
+ * view
+ */
+ public Set<? extends ILaunchObject> getLaunchObjects();
+
+ /**
+ * @param r register a {@link Runnable} that should be notified whenever the
+ * provider's state changed. The view will react with refreshing
+ * it's in-memory models.
+ */
+ public void addUpdateListener(Runnable r);
+
+ /**
+ * @param r a previously registered update listener {@link Runnable}.
+ */
+ public void removeUpdateListener(Runnable r);
+
+ /**
+ * @return the priority of the provider. The default (debug.core) provider
+ * has priority 0. A higher priority means that
+ * {@link ILaunchObject}s with the same type and id will take
+ * precedence. This allows to provide {@link ILaunchObject}s that
+ * will generate {@link ILaunchObject}s in lower priority providers.
+ */
+ public int getPriority();
+
+ /**
+ * @param selected supplier for selected elements in the view.
+ * @param menu the view's menu where items can be contributed.
+ */
+ public void contributeViewMenu(Supplier<Set<ILaunchObject>> selected, MMenu menu);
+
+ /**
+ * Contribute per-item context menu items here. Use
+ * {@link LaunchViewImpl#getSelectedElements()} to retrieve selected
+ * elements during CanExecute and Execute methods of menu items.
+ *
+ * @param selected supplier for selected elements in the view.
+ * @param menu the context menu applied to items in the tree.
+ */
+ public void contributeContextMenu(Supplier<Set<ILaunchObject>> selected, MMenu menu);
+
+}
diff --git a/org.eclipse.debug.ui/.classpath b/org.eclipse.debug.ui/.classpath
index 2ddccc40c..623144a15 100644
--- a/org.eclipse.debug.ui/.classpath
+++ b/org.eclipse.debug.ui/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="ui"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.debug.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.debug.ui/.settings/org.eclipse.jdt.core.prefs
index 05d8e79da..1aa186aa3 100644
--- a/org.eclipse.debug.ui/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.debug.ui/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -37,6 +37,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -95,6 +96,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=erro
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -131,12 +133,14 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
@@ -144,20 +148,23 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=16
org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=16
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_for_loop_header=0
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=16
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_module_statements=16
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16
org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=16
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
@@ -249,11 +256,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -284,6 +292,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -308,13 +318,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -362,6 +376,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do no
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -398,9 +414,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -436,10 +455,14 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
org.eclipse.jdt.core.formatter.wrap_before_assignment_operator=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
org.eclipse.jdt.core.formatter.wrap_before_conditional_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.debug.ui/META-INF/MANIFEST.MF b/org.eclipse.debug.ui/META-INF/MANIFEST.MF
index 7cea69f2b..b5596c3ce 100644
--- a/org.eclipse.debug.ui/META-INF/MANIFEST.MF
+++ b/org.eclipse.debug.ui/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.debug.ui; singleton:=true
-Bundle-Version: 3.14.900.qualifier
+Bundle-Version: 3.16.100.qualifier
Bundle-Activator: org.eclipse.debug.internal.ui.DebugUIPlugin
Bundle-Vendor: %providerName
Bundle-Localization: plugin
@@ -12,7 +12,8 @@ Export-Package: org.eclipse.debug.internal.ui;
org.eclipse.jdt.debug.tests,
org.eclipse.debug.tests,
org.eclipse.debug.examples.ui,
- org.eclipse.debug.examples.mixedmode",
+ org.eclipse.debug.examples.mixedmode,
+ org.eclipse.debug.ui.launchview",
org.eclipse.debug.internal.ui.actions;x-internal:=true,
org.eclipse.debug.internal.ui.actions.breakpointGroups;x-internal:=true,
org.eclipse.debug.internal.ui.actions.breakpointSortBy;x-internal:=true,
@@ -48,6 +49,7 @@ Export-Package: org.eclipse.debug.internal.ui;
org.eclipse.debug.internal.ui.viewers.model;x-friends:="org.eclipse.debug.tests,org.eclipse.jdt.debug.tests,org.eclipse.debug.examples.ui",
org.eclipse.debug.internal.ui.viewers.model.provisional;
x-friends:="org.eclipse.cdt.dsf.gdb.ui,
+ org.eclipse.debug.internal.ui.views.memory.renderings;x-internal:=true,
org.eclipse.cdt.dsf.ui,
org.eclipse.debug.examples.ui,
org.eclipse.debug.tests,
@@ -97,5 +99,5 @@ Require-Bundle: org.eclipse.core.expressions;bundle-version="[3.4.0,4.0.0)",
Bundle-ActivationPolicy: lazy
Bundle-ClassPath: .
Import-Package: org.eclipse.ui.forms.widgets
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Automatic-Module-Name: org.eclipse.debug.ui
diff --git a/org.eclipse.debug.ui/icons/full/obj16/launchConfiguration.png b/org.eclipse.debug.ui/icons/full/obj16/launchConfiguration.png
new file mode 100644
index 000000000..27b2f80e4
--- /dev/null
+++ b/org.eclipse.debug.ui/icons/full/obj16/launchConfiguration.png
Binary files differ
diff --git a/org.eclipse.debug.ui/icons/full/obj16/launchConfiguration@2x.png b/org.eclipse.debug.ui/icons/full/obj16/launchConfiguration@2x.png
new file mode 100644
index 000000000..8e6529b14
--- /dev/null
+++ b/org.eclipse.debug.ui/icons/full/obj16/launchConfiguration@2x.png
Binary files differ
diff --git a/org.eclipse.debug.ui/plugin.properties b/org.eclipse.debug.ui/plugin.properties
index e3a2ceda2..0789bdb08 100644
--- a/org.eclipse.debug.ui/plugin.properties
+++ b/org.eclipse.debug.ui/plugin.properties
@@ -234,6 +234,9 @@ ActionDefinition.terminate.description=Terminate
ActionDefinition.terminateAndRelaunch.name=Terminate and Relaunch
ActionDefinition.terminateAndRelaunch.description=Terminate and Relaunch
+ActionDefinition.terminateAll.name=Terminate/Disconnect All
+ActionDefinition.terminateAll.description=Terminate/Disconnect All
+
ActionDefinition.toggleBreakpoint.name=Toggle Breakpoint
ActionDefinition.toggleBreakpoint.description=Creates or removes a breakpoint
ActionDefinition.toggleLineBreakpoint.name=Toggle Line Breakpoint
diff --git a/org.eclipse.debug.ui/plugin.xml b/org.eclipse.debug.ui/plugin.xml
index c95e6314f..fc82676be 100644
--- a/org.eclipse.debug.ui/plugin.xml
+++ b/org.eclipse.debug.ui/plugin.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<!--
- Copyright (c) 2005, 2020 IBM Corporation and others.
+ Copyright (c) 2005, 2021 IBM Corporation and others.
This program and the accompanying materials
are made available under the terms of the Eclipse Public License 2.0
@@ -1918,6 +1918,15 @@ M4 = Platform-specific fourth key
</defaultHandler>
</command>
<command
+ name="%ActionDefinition.terminateAll.name"
+ categoryId="org.eclipse.debug.ui.category.run"
+ description="%ActionDefinition.terminateAll.description"
+ id="org.eclipse.debug.ui.commands.TerminateAll">
+ <defaultHandler
+ class="org.eclipse.debug.internal.ui.commands.actions.TerminateAllHandler">
+ </defaultHandler>
+ </command>
+ <command
name="%ActionDefinition.restart.name"
categoryId="org.eclipse.debug.ui.category.run"
description="%ActionDefinition.restart.description"
@@ -3376,4 +3385,18 @@ M4 = Platform-specific fourth key
class="org.eclipse.debug.internal.ui.quickaccess.ProfileQuickAccessComputer"
name="%ProfileDropDownAction.label"/>
</extension>
+ <extension
+ point="org.eclipse.ui.genericeditor.icons">
+ <icon
+ contentType="org.eclipse.debug.core.launch"
+ icon="icons/full/obj16/launchConfiguration.png">
+ </icon>
+ </extension>
+ <extension
+ point="org.eclipse.ui.workbench.texteditor.codeMiningProviders">
+ <codeMiningProvider
+ class="org.eclipse.debug.internal.ui.codemining.DebugValueCodeMiningProvider"
+ id="org.eclipse.debug.ui.codeMiningProvider1">
+ </codeMiningProvider>
+ </extension>
</plugin>
diff --git a/org.eclipse.debug.ui/pom.xml b/org.eclipse.debug.ui/pom.xml
index 13d8303ba..76c65e5f1 100644
--- a/org.eclipse.debug.ui/pom.xml
+++ b/org.eclipse.debug.ui/pom.xml
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
- Copyright (c) 2012, 2020 Eclipse Foundation and others.
+ Copyright (c) 2012, 2021 Eclipse Foundation and others.
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Distribution License v1.0
which accompanies this distribution, and is available at
@@ -15,11 +15,11 @@
<parent>
<artifactId>eclipse.platform.debug</artifactId>
<groupId>eclipse.platform.debug</groupId>
- <version>4.20.0-SNAPSHOT</version>
+ <version>4.24.0-SNAPSHOT</version>
</parent>
<groupId>org.eclipse.debug</groupId>
<artifactId>org.eclipse.debug.ui</artifactId>
- <version>3.14.900-SNAPSHOT</version>
+ <version>3.16.100-SNAPSHOT</version>
<packaging>eclipse-plugin</packaging>
<properties>
<code.ignoredWarnings>-warn:+resource,-deprecation,unavoidableGenericProblems</code.ignoredWarnings>
diff --git a/org.eclipse.debug.ui/schema/variableValueEditors.exsd b/org.eclipse.debug.ui/schema/variableValueEditors.exsd
index 76d585467..77d8b014d 100644
--- a/org.eclipse.debug.ui/schema/variableValueEditors.exsd
+++ b/org.eclipse.debug.ui/schema/variableValueEditors.exsd
@@ -2,18 +2,23 @@
<!-- Schema file written by PDE -->
<schema targetNamespace="org.eclipse.debug.ui" xmlns="http://www.w3.org/2001/XMLSchema">
<annotation>
- <appinfo>
+ <appInfo>
<meta.schema plugin="org.eclipse.debug.ui" id="variableValueEditors" name="Variable Value Editors"/>
- </appinfo>
+ </appInfo>
<documentation>
This extension point provides a mechanism for contributing variable value editors for a particular debug model. Variable value editors are used to edit/save variable values. When the user invokes the &quot;Change Value...&quot; or &quot;Assign Value&quot; (details pane) actions on a variable in the Variables view, the contributed &lt;code&gt;org.eclipse.debug.ui.actions.IVariableValueEditor&lt;/code&gt; will be invoked to change the value.
</documentation>
</annotation>
<element name="extension">
+ <annotation>
+ <appInfo>
+ <meta.element />
+ </appInfo>
+ </annotation>
<complexType>
<sequence>
- <element ref="variableValueEditor"/>
+ <element ref="variableValueEditor" minOccurs="1" maxOccurs="unbounded"/>
</sequence>
<attribute name="point" type="string" use="required">
<annotation>
@@ -46,9 +51,9 @@
<documentation>
Implementation of &lt;code&gt;org.eclipse.debug.ui.actions.IVariableValueEditor&lt;/code&gt;
</documentation>
- <appinfo>
+ <appInfo>
<meta.attribute kind="java" basedOn=":org.eclipse.debug.ui.actions.IVariableValueEditor"/>
- </appinfo>
+ </appInfo>
</annotation>
</attribute>
<attribute name="modelId" type="string" use="required">
@@ -58,22 +63,31 @@
</documentation>
</annotation>
</attribute>
+ <attribute name="priority" type="string">
+ <annotation>
+ <documentation>
+ Optional integer number 0 to 10 describing priority of this extension, with 0 being the lowest priority.
+If values outside of [0,10] range are specified, they are replaced with appropriate limits, any non integer values are ignored and zero (lowest priority) is used.
+If multiple contributions have the same priority, an arbitrary contribution among them will be selected.
+ </documentation>
+ </annotation>
+ </attribute>
</complexType>
</element>
<annotation>
- <appinfo>
+ <appInfo>
<meta.section type="since"/>
- </appinfo>
+ </appInfo>
<documentation>
3.1
</documentation>
</annotation>
<annotation>
- <appinfo>
+ <appInfo>
<meta.section type="examples"/>
- </appinfo>
+ </appInfo>
<documentation>
&lt;pre&gt;
&lt;extension
@@ -87,20 +101,19 @@
</annotation>
<annotation>
- <appinfo>
+ <appInfo>
<meta.section type="apiInfo"/>
- </appinfo>
+ </appInfo>
<documentation>
Value of the attribute &lt;b&gt;class&lt;/b&gt; must be a fully qualified name of a Java class that implements the interface &lt;b&gt;org.eclipse.debug.ui.actions.IVariableValueEditor&lt;/b&gt;.
</documentation>
</annotation>
-
<annotation>
- <appinfo>
+ <appInfo>
<meta.section type="copyright"/>
- </appinfo>
+ </appInfo>
<documentation>
Copyright (c) 2004, 2005 IBM Corporation and others.&lt;br&gt;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/InstructionPointerManager.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/InstructionPointerManager.java
index f5d1db073..42b1aab4e 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/InstructionPointerManager.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/InstructionPointerManager.java
@@ -92,8 +92,10 @@ public class InstructionPointerManager{
* specified stack frame.
*/
public void addAnnotation(ITextEditor textEditor, IStackFrame frame, Annotation annotation) {
-
IDocumentProvider docProvider = textEditor.getDocumentProvider();
+ if (docProvider == null) {
+ return;
+ }
IEditorInput editorInput = textEditor.getEditorInput();
// If there is no annotation model, there's nothing more to do
IAnnotationModel annModel = docProvider.getAnnotationModel(editorInput);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/MultipleInputDialog.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/MultipleInputDialog.java
index 5e3092622..e3fd25878 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/MultipleInputDialog.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/MultipleInputDialog.java
@@ -365,7 +365,7 @@ public class MultipleInputDialog extends Dialog {
getButton(IDialogConstants.OK_ID).setEnabled(true);
}
- protected class FieldSummary {
+ protected static class FieldSummary {
int type;
String name;
String initialValue;
@@ -379,7 +379,7 @@ public class MultipleInputDialog extends Dialog {
}
}
- protected class Validator {
+ protected static class Validator {
boolean validate() {
return true;
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/VariableValueEditorManager.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/VariableValueEditorManager.java
index 2608bf0cc..80fa4dd19 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/VariableValueEditorManager.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/VariableValueEditorManager.java
@@ -33,6 +33,14 @@ import org.eclipse.debug.ui.actions.IVariableValueEditor;
*/
public class VariableValueEditorManager {
+ private static final int MAX_PRIORITY = 10;
+
+ private static final int DEFAULT_PRIORITY = 0;
+
+ private static final String MODEL_ID = "modelId"; //$NON-NLS-1$
+
+ private static final String PRIORITY = "priority";//$NON-NLS-1$
+
/**
* Mapping of debug model identifiers to variable value editors.
* The keys in this map are always Strings (model ids).
@@ -101,10 +109,39 @@ public class VariableValueEditorManager {
IExtensionPoint ep = Platform.getExtensionRegistry().getExtensionPoint(DebugUIPlugin.getUniqueIdentifier(), IDebugUIConstants.EXTENSION_POINT_VARIABLE_VALUE_EDITORS);
IConfigurationElement[] elements = ep.getConfigurationElements();
for (IConfigurationElement element : elements) {
- String modelId = element.getAttribute("modelId"); //$NON-NLS-1$
+ String modelId = element.getAttribute(MODEL_ID);
if (modelId != null) {
- fEditorMap.put(modelId, element);
+ Object original = fEditorMap.put(modelId, element);
+ // Check if the original contribution had higher priority
+ if (original instanceof IConfigurationElement) {
+ int newPrio = getPriority(element);
+ int oldPrio = getPriority((IConfigurationElement) original);
+ if (oldPrio > newPrio) {
+ // restore
+ fEditorMap.put(modelId, original);
+ }
+ }
+ }
+ }
+ }
+
+ private static int getPriority(IConfigurationElement element) {
+ String attribute = element.getAttribute(PRIORITY);
+ int priority = DEFAULT_PRIORITY;
+ if (attribute != null) {
+ try {
+ priority = Integer.parseInt(attribute);
+ } catch (Exception e) {
+ String error = "Unexpected value: '" + attribute + //$NON-NLS-1$
+ "' for '" + PRIORITY + "' attribute " //$NON-NLS-1$//$NON-NLS-2$
+ + " in extension point '" + IDebugUIConstants.EXTENSION_POINT_VARIABLE_VALUE_EDITORS //$NON-NLS-1$
+ + "' was specified by " + element.getNamespaceIdentifier(); //$NON-NLS-1$
+ IllegalArgumentException ie = new IllegalArgumentException(error, e);
+ DebugUIPlugin.log(ie);
}
+ priority = Math.max(DEFAULT_PRIORITY, priority);
+ priority = Math.min(MAX_PRIORITY, priority);
}
+ return priority;
}
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/ConfigureColumnsAction.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/ConfigureColumnsAction.java
index c2c58f5f0..5157a0079 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/ConfigureColumnsAction.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/ConfigureColumnsAction.java
@@ -43,7 +43,7 @@ public class ConfigureColumnsAction extends Action implements IUpdate {
private TreeModelViewer fViewer;
- class ColumnContentProvider implements IStructuredContentProvider {
+ static class ColumnContentProvider implements IStructuredContentProvider {
@Override
public Object[] getElements(Object inputElement) {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMining.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMining.java
new file mode 100644
index 000000000..b53553506
--- /dev/null
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMining.java
@@ -0,0 +1,61 @@
+/*******************************************************************************
+ * Copyright (c) 2022 Red Hat, Inc. and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.codemining;
+
+import java.util.function.Consumer;
+
+import org.eclipse.debug.core.model.IVariable;
+import org.eclipse.debug.internal.ui.DebugUIPlugin;
+import org.eclipse.debug.internal.ui.views.variables.VariablesView;
+import org.eclipse.debug.ui.IDebugUIConstants;
+import org.eclipse.jface.text.BadLocationException;
+import org.eclipse.jface.text.IDocument;
+import org.eclipse.jface.text.codemining.ICodeMiningProvider;
+import org.eclipse.jface.text.codemining.LineEndCodeMining;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.swt.events.MouseEvent;
+import org.eclipse.ui.PartInitException;
+import org.eclipse.ui.PlatformUI;
+
+public class DebugValueCodeMining extends LineEndCodeMining {
+
+ private IVariable variable;
+
+ protected DebugValueCodeMining(IDocument document, int line, IVariable variable, ICodeMiningProvider provider)
+ throws BadLocationException {
+ super(document, line, provider);
+ this.variable = variable;
+ setLabel(DebugUIPlugin.getModelPresentation().getText(variable));
+ }
+
+ @Override
+ public Consumer<MouseEvent> getAction() {
+ return e -> openVariableInVariablesView(variable);
+ }
+
+ private static void openVariableInVariablesView(IVariable variable) {
+
+ VariablesView view;
+ try {
+ view = (VariablesView) PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage()
+ .showView(IDebugUIConstants.ID_VARIABLE_VIEW);
+ view.getViewer().setSelection(new StructuredSelection(variable));
+ } catch (PartInitException e) {
+ DebugUIPlugin.log(e);
+ }
+ }
+
+ @Override
+ public boolean isResolved() {
+ return true;
+ }
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMiningProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMiningProvider.java
new file mode 100644
index 000000000..5ddcd2a0f
--- /dev/null
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/codemining/DebugValueCodeMiningProvider.java
@@ -0,0 +1,109 @@
+/*******************************************************************************
+ * Copyright (c) 2022 Red Hat, Inc. and others.
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.codemining;
+
+import java.util.ArrayList;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.concurrent.CompletableFuture;
+import java.util.function.Predicate;
+import java.util.stream.Stream;
+
+import org.eclipse.core.runtime.Adapters;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.debug.core.DebugException;
+import org.eclipse.debug.core.DebugPlugin;
+import org.eclipse.debug.core.IDebugEventSetListener;
+import org.eclipse.debug.core.ILaunch;
+import org.eclipse.debug.core.ILaunchManager;
+import org.eclipse.debug.core.model.IVariable;
+import org.eclipse.debug.internal.ui.DebugUIPlugin;
+import org.eclipse.debug.ui.IDebugUIConstants;
+import org.eclipse.jface.text.BadLocationException;
+import org.eclipse.jface.text.IDocument;
+import org.eclipse.jface.text.IRegion;
+import org.eclipse.jface.text.ITextViewer;
+import org.eclipse.jface.text.TextSelection;
+import org.eclipse.jface.text.codemining.AbstractCodeMiningProvider;
+import org.eclipse.jface.text.codemining.ICodeMining;
+import org.eclipse.jface.text.source.ISourceViewerExtension5;
+
+public class DebugValueCodeMiningProvider extends AbstractCodeMiningProvider {
+
+ private volatile IDebugEventSetListener listener;
+
+ @Override
+ public CompletableFuture<List<? extends ICodeMining>> provideCodeMinings(ITextViewer viewer,
+ IProgressMonitor monitor) {
+ if (!isEnabled()) {
+ return CompletableFuture.completedFuture(List.of());
+ }
+ final IDocument document = viewer.getDocument();
+ if (viewer instanceof ISourceViewerExtension5 && listener == null) {
+ synchronized (this) {
+ if (listener == null) {
+ IDebugEventSetListener debugListener = e -> ((ISourceViewerExtension5) viewer).updateCodeMinings();
+ DebugPlugin.getDefault().addDebugEventListener(debugListener);
+ listener = debugListener;
+ }
+ }
+ }
+ if (!hasDebugRunning()) {
+ return CompletableFuture.completedFuture(List.of());
+ }
+ return CompletableFuture.supplyAsync(() -> {
+ List<DebugValueCodeMining> res = new ArrayList<>();
+ for (int line = 0; line < document.getNumberOfLines(); line++) {
+ LinkedHashMap<String, IVariable> variablesOnLine = new LinkedHashMap<>();
+ try {
+ IRegion lineInfo = document.getLineInformation(line);
+ for (int offsetInLine = 0; offsetInLine < lineInfo.getLength(); offsetInLine++) {
+ IVariable variableAtOffset = Adapters.adapt(
+ new TextSelection(document, lineInfo.getOffset() + offsetInLine, 0), IVariable.class);
+ if (variableAtOffset != null) {
+ try {
+ variablesOnLine.putIfAbsent(variableAtOffset.getName(), variableAtOffset);
+ offsetInLine += variableAtOffset.getName().length();
+ } catch (DebugException ex) {
+ DebugUIPlugin.log(ex);
+ }
+ }
+ }
+ for (IVariable variableOnLine : variablesOnLine.values()) {
+ res.add(new DebugValueCodeMining(document, line, variableOnLine, this));
+ }
+ } catch (BadLocationException e) {
+ DebugUIPlugin.log(e);
+ }
+ }
+ return res;
+ });
+ }
+
+ private boolean hasDebugRunning() {
+ return Stream.of(DebugPlugin.getDefault().getLaunchManager().getLaunches()) //
+ .filter(Predicate.not(ILaunch::isTerminated)) //
+ .anyMatch(launch -> ILaunchManager.DEBUG_MODE.equals(launch.getLaunchMode()));
+ }
+
+ private boolean isEnabled() {
+ return DebugUIPlugin.getDefault().getPreferenceStore().getBoolean(IDebugUIConstants.PREF_SHOW_VARIABLES_INLINE);
+ }
+
+ @Override
+ public void dispose() {
+ IDebugEventSetListener debugListener = listener;
+ if (debugListener != null) {
+ DebugPlugin.getDefault().removeDebugEventListener(debugListener);
+ listener = null;
+ }
+ }
+}
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/StreamDecoder.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/TerminateAllHandler.java
index e334aa22e..ff14fbb5a 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/StreamDecoder.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/TerminateAllHandler.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2017 Andreas Loth and others.
+ * Copyright (c) 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -9,22 +9,21 @@
* SPDX-License-Identifier: EPL-2.0
*
* Contributors:
- * Andreas Loth - initial API and implementation
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
+package org.eclipse.debug.internal.ui.commands.actions;
-package org.eclipse.ui.internal.console;
-
-import java.nio.charset.Charset;
+import org.eclipse.debug.internal.ui.views.launch.LaunchView;
/**
- * @deprecated class was moved to
- * {@link org.eclipse.debug.internal.core.StreamDecoder}
+ * Default handler for terminate and re-launch. See bug 300810.
*/
-@Deprecated
-public class StreamDecoder extends org.eclipse.debug.internal.core.StreamDecoder {
+public class TerminateAllHandler extends DebugActionHandler {
- public StreamDecoder(Charset charset) {
- super(charset);
+ public TerminateAllHandler() {
+ super(LaunchView.TERMINATE_ALL);
}
+
+
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/contextlaunching/LaunchingResourceManager.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/contextlaunching/LaunchingResourceManager.java
index 3042bf069..2b1d97b90 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/contextlaunching/LaunchingResourceManager.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/contextlaunching/LaunchingResourceManager.java
@@ -84,7 +84,6 @@ import org.eclipse.ui.internal.WorkbenchWindow;
*
* @since 3.3
*/
-@SuppressWarnings("restriction")
public class LaunchingResourceManager implements IPropertyChangeListener, IWindowListener, ISelectionListener, ILaunchHistoryChangedListener, ILaunchesListener2 {
/**
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/groups/CommonTabLite.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/groups/CommonTabLite.java
index d6ce28a47..fdcfb1dc7 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/groups/CommonTabLite.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/groups/CommonTabLite.java
@@ -509,7 +509,7 @@ class CommonTabLite extends AbstractLaunchConfigurationTab {
* Provides the labels for the favorites table
*
*/
- class FavoritesLabelProvider implements ITableLabelProvider {
+ static class FavoritesLabelProvider implements ITableLabelProvider {
private Map<Object, Image> fImages = new HashMap<>();
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationManager.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationManager.java
index ec0934c17..95b9ce0b7 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationManager.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationManager.java
@@ -102,7 +102,7 @@ public class LaunchConfigurationManager implements ILaunchListener, ISavePartici
* A comparator for the ordering of launch shortcut extensions
* @since 3.3
*/
- class ShortcutComparator implements Comparator<LaunchShortcutExtension> {
+ static class ShortcutComparator implements Comparator<LaunchShortcutExtension> {
/**
* @see Comparator#compare(Object, Object)
*/
@@ -983,6 +983,9 @@ public class LaunchConfigurationManager implements ILaunchListener, ISavePartici
base = DebugPluginImages.getImage(IInternalDebugUIConstants.IMG_OVR_TRANSPARENT);
}
base = new Image(Display.getCurrent(), base, SWT.IMAGE_COPY);
+ // register the base image, to avoid nondisposed resource error
+ fErrorImages.put(key + "-baseImage", base); //$NON-NLS-1$
+
LaunchConfigurationTabImageDescriptor desc = new LaunchConfigurationTabImageDescriptor(base, LaunchConfigurationTabImageDescriptor.ERROR);
image = desc.createImage();
fErrorImages.put(key, image);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
index 9d8adbf2e..f274d52a9 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2020 IBM Corporation and others.
+ * Copyright (c) 2000, 2022 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -363,10 +363,11 @@ public class LaunchConfigurationTabGroupViewer {
SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_6, DebugUITools.getImage(IInternalDebugUIConstants.IMG_ELCL_DUPLICATE_CONFIG), 1, width);
SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_4, DebugUITools.getImage(IInternalDebugUIConstants.IMG_ELCL_DELETE_CONFIG), 1, width);
SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_8, DebugUITools.getImage(IInternalDebugUIConstants.IMG_ELCL_FILTER_CONFIGS), 1, width);
- SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_3, DebugUITools.getImage(IInternalDebugUIConstants.IMG_OVR_TRANSPARENT), 1, width);
SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_10, DebugUITools.getImage(IInternalDebugUIConstants.IMG_ELCL_LINK_PROTO), 1, width);
SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_11, DebugUITools.getImage(IInternalDebugUIConstants.IMG_ELCL_UNLINK_PROTO), 1, width);
SWTFactory.createWrapCLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_12, DebugUITools.getImage(IInternalDebugUIConstants.IMG_ELCL_RESET_PROTO), 1, width);
+ SWTFactory.createHorizontalSpacer(parent, 2);
+ SWTFactory.createLabel(parent, LaunchConfigurationsMessages.LaunchConfigurationTabGroupViewer_3, width);
SWTFactory.createHorizontalSpacer(parent, 2);
Link link = new Link(parent, SWT.LEFT | SWT.WRAP);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupWrapper.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupWrapper.java
index f45c6287d..f2f9e11f0 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupWrapper.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupWrapper.java
@@ -45,7 +45,7 @@ public class LaunchConfigurationTabGroupWrapper implements ILaunchConfigurationT
*
* @since 3.5
*/
- class TabCollector implements Iterator<ILaunchConfigurationTab> {
+ static class TabCollector implements Iterator<ILaunchConfigurationTab> {
private HashSet<String> idSet = null;
private ArrayList<ILaunchConfigurationTab> tabList = null;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationsMessages.properties b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationsMessages.properties
index 5a9456a68..96ac5b2da 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationsMessages.properties
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationsMessages.properties
@@ -1,5 +1,5 @@
###############################################################################
-# Copyright (c) 2000, 2021 IBM Corporation and others.
+# Copyright (c) 2000, 2022 IBM Corporation and others.
#
# This program and the accompanying materials
# are made available under the terms of the Eclipse Public License 2.0
@@ -16,7 +16,7 @@
###############################################################################
CommonTab__Browse_6=&Browse...
-CommonTab__Common_15=&Common
+CommonTab__Common_15=Common
CommonTab_Display_in_favorites_menu__10=Display in favo&rites menu
CommonTab_Invalid_shared_configuration_location_14=Invalid shared configuration location
CommonTab_Invalid_stdin_file_location_15=No file specified for process input
@@ -72,7 +72,7 @@ LaunchConfigurationDialog_An_exception_occurred_while_retrieving_launch_configur
LaunchConfigurationTabGroupViewer_1=Configure launch settings from this dialog:
LaunchConfigurationTabGroupViewer_2=- Press the 'New Configuration' button to create a configuration of the selected type.
-LaunchConfigurationTabGroupViewer_3=- Edit or view an existing configuration by selecting it.
+LaunchConfigurationTabGroupViewer_3=Edit or view an existing configuration by selecting it.
LaunchConfigurationTabGroupViewer_4=- Press the 'Delete' button to remove the selected configuration.
LaunchConfigurationTabGroupViewer_6=- Press the 'Duplicate' button to copy the selected configuration.
LaunchConfigurationTabGroupViewer_5=Configure launch perspective settings from the <a>'Perspectives'</a> preference page.
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchShortcutExtension.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchShortcutExtension.java
index 7a48f5cc2..140647c47 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchShortcutExtension.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchShortcutExtension.java
@@ -67,7 +67,7 @@ public class LaunchShortcutExtension implements ILaunchShortcut2, IPluginContrib
/**
* Command handler for launch shortcut key binding.
*/
- private class LaunchCommandHandler extends AbstractHandler {
+ private static class LaunchCommandHandler extends AbstractHandler {
// the shortcut to invoke
private LaunchShortcutExtension fShortcut;
private String fMode;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/SelectLaunchModesDialog.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/SelectLaunchModesDialog.java
index 37b0b4a35..ed6bab9a7 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/SelectLaunchModesDialog.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/SelectLaunchModesDialog.java
@@ -43,7 +43,7 @@ public class SelectLaunchModesDialog extends AbstractDebugListSelectionDialog{
/**
* Builds labels for list control
*/
- class OptionsLabelProvider implements ILabelProvider {
+ static class OptionsLabelProvider implements ILabelProvider {
@Override
public Image getImage(Object element) {return null;}
@Override
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/memory/provisional/AbstractAsyncTableRendering.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/memory/provisional/AbstractAsyncTableRendering.java
index e7da67f94..f91ff538f 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/memory/provisional/AbstractAsyncTableRendering.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/memory/provisional/AbstractAsyncTableRendering.java
@@ -337,7 +337,7 @@ public abstract class AbstractAsyncTableRendering extends AbstractBaseTableRende
}
}
- private class SerialByObjectRule implements ISchedulingRule {
+ private static class SerialByObjectRule implements ISchedulingRule {
private Object fObject = null;
public SerialByObjectRule(Object lock) {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerContentProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerContentProvider.java
index 89e241016..92944bf10 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerContentProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerContentProvider.java
@@ -26,15 +26,11 @@ import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
+import java.util.function.Consumer;
import org.eclipse.core.resources.IMarkerDelta;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.ISchedulingRule;
-import org.eclipse.core.runtime.jobs.Job;
import org.eclipse.debug.core.DebugPlugin;
import org.eclipse.debug.core.IBreakpointManager;
import org.eclipse.debug.core.IBreakpointsListener;
@@ -756,23 +752,6 @@ public class BreakpointManagerContentProvider extends ElementContentProvider
}
/**
- * Scheduling rule to make sure that breakpoint manager listener updates
- * are process serially.
- */
- private ISchedulingRule fBreakpointsListenerSchedulingRule = new ISchedulingRule() {
-
- @Override
- public boolean isConflicting(ISchedulingRule rule) {
- return rule == this;
- }
-
- @Override
- public boolean contains(ISchedulingRule rule) {
- return rule == this;
- }
- };
-
- /**
* A map of input to info data cache
*/
final private Map<DefaultBreakpointsViewInput, InputData> fInputToData = Collections.synchronizedMap(new InputDataMap<>());
@@ -1019,58 +998,25 @@ public class BreakpointManagerContentProvider extends ElementContentProvider
return EMPTY;
}
+ final SerialExecutor breakpointUpdater = new SerialExecutor("Breakpoints View Update Job", this); //$NON-NLS-1$
+
+ void updateBreakpointView(Consumer<InputData> action) {
+ breakpointUpdater.schedule(() -> fInputToData.values().forEach(action::accept));
+ }
+
@Override
public void breakpointsAdded(final IBreakpoint[] breakpoints) {
- new Job("Breakpoints View Update Job") { //$NON-NLS-1$
- {
- setSystem(true);
- setRule(fBreakpointsListenerSchedulingRule);
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- for (InputData data : fInputToData.values()) {
- data.breakpointsAdded(breakpoints);
- }
- return Status.OK_STATUS;
- }
- }.schedule();
+ updateBreakpointView(data -> data.breakpointsAdded(breakpoints));
}
@Override
public void breakpointsRemoved(final IBreakpoint[] breakpoints, IMarkerDelta[] deltas) {
- new Job("Breakpoints View Update Job") { //$NON-NLS-1$
- {
- setSystem(true);
- setRule(fBreakpointsListenerSchedulingRule);
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- for (InputData data : fInputToData.values()) {
- data.breakpointsRemoved(breakpoints);
- }
- return Status.OK_STATUS;
- }
- }.schedule();
+ updateBreakpointView(data -> data.breakpointsRemoved(breakpoints));
}
@Override
public void breakpointsChanged(final IBreakpoint[] breakpoints, IMarkerDelta[] deltas) {
- new Job("Breakpoints View Update Job") { //$NON-NLS-1$
- {
- setSystem(true);
- setRule(fBreakpointsListenerSchedulingRule);
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- for (InputData data : fInputToData.values()) {
- data.breakpointsChanged(breakpoints);
- }
- return Status.OK_STATUS;
- }
- }.schedule();
+ updateBreakpointView(data -> data.breakpointsChanged(breakpoints));
}
/**
* Appends the model delta flags to child containers that contains the breakpoint.
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/SerialExecutor.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/SerialExecutor.java
new file mode 100644
index 000000000..6e46b2a9e
--- /dev/null
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/SerialExecutor.java
@@ -0,0 +1,75 @@
+/*****************************************************************
+ * Copyright (c) 2021 Joerg Kubitz and others
+ *
+ * This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License 2.0
+ * which accompanies this distribution, and is available at
+ * https://www.eclipse.org/legal/epl-2.0/
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Joerg Kubitz - Initial API and implementation
+ *****************************************************************/
+
+package org.eclipse.debug.internal.ui.model.elements;
+
+import java.util.concurrent.ConcurrentLinkedQueue;
+
+import org.eclipse.core.runtime.Assert;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+
+/**
+ * A singleton SerialExecutor job instance can be used to execute Runnable
+ * objects offered by {@link #schedule(Runnable)} method in order of they
+ * submission, one after another.
+ */
+public final class SerialExecutor extends Job {
+
+ private final ConcurrentLinkedQueue<Runnable> queue;
+ private final Object myFamily;
+
+ /**
+ * @param jobName descriptive job name
+ * @param family non null object to control this job execution
+ **/
+ public SerialExecutor(String jobName, Object family) {
+ super(jobName);
+ Assert.isNotNull(family);
+ this.myFamily = family;
+ this.queue = new ConcurrentLinkedQueue<>();
+ setSystem(true);
+ }
+
+ @Override
+ public boolean belongsTo(Object family) {
+ return myFamily == family;
+ }
+
+ @Override
+ protected IStatus run(IProgressMonitor monitor) {
+ Runnable action = queue.poll();
+ try {
+ if (action != null) {
+ action.run();
+ }
+ } finally {
+ if (!queue.isEmpty()) {
+ // in case actions got faster scheduled then processed reschedule:
+ schedule();
+ }
+ }
+ return Status.OK_STATUS;
+ }
+
+ /**
+ * Enqueue an action asynchronously.
+ **/
+ public void schedule(Runnable action) {
+ queue.offer(action);
+ schedule(); // will reschedule if already running
+ }
+} \ No newline at end of file
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencePage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencePage.java
index 129c1a3c5..2f740d038 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencePage.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencePage.java
@@ -50,6 +50,8 @@ public class DebugPreferencePage extends FieldEditorPreferencePage implements IW
@Override
protected void createFieldEditors() {
addField(new BooleanFieldEditor(IDebugUIConstants.PREF_REUSE_EDITOR, DebugPreferencesMessages.DebugPreferencePage_2, SWT.NONE, getFieldEditorParent()));
+ addField(new BooleanFieldEditor(IDebugUIConstants.PREF_SHOW_VARIABLES_INLINE,
+ DebugPreferencesMessages.DebugPreferencePage_showValuesInline, SWT.NONE, getFieldEditorParent()));
SWTFactory.createHorizontalSpacer(getFieldEditorParent(), 2);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.java
index f16c04ca5..bc2d6e4ed 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.java
@@ -59,6 +59,7 @@ public class DebugPreferencesMessages extends NLS {
public static String DebugPreferencePage_25;
public static String DebugPreferencePage_26;
public static String DebugPreferencePage_27;
+ public static String DebugPreferencePage_showValuesInline;
public static String DefaultLaunchConfigurationsPropertiesPage_0;
@@ -189,6 +190,8 @@ public class DebugPreferencesMessages extends NLS {
public static String ProcessPropertyPage_10;
+ public static String ProcessPropertyPage_11;
+
public static String ProcessPropertyPage_1;
public static String ProcessPropertyPage_2;
@@ -213,4 +216,5 @@ public class DebugPreferencesMessages extends NLS {
public static String RunDebugPropertiesPage_0;
+
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.properties b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.properties
index 1cb992017..ca6df3223 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.properties
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugPreferencesMessages.properties
@@ -1,5 +1,5 @@
###############################################################################
-# Copyright (c) 2000, 2020 IBM Corporation and others.
+# Copyright (c) 2000, 2022 IBM Corporation and others.
#
# This program and the accompanying materials
# are made available under the terms of the Eclipse Public License 2.0
@@ -52,6 +52,7 @@ DebugPreferencePage_30=Prompt for confirmation when deleting breakpoint con&tain
DebugPreferencePage_31=&Prompt for confirmation when removing all triggerpoints
DebugPreferencePage_32=&Prompt for confirmation when disabling all breakpoints
DebugPreferencePage_5=Prompt for confirmation when deleting all e&xpressions
+DebugPreferencePage_showValuesInline=Show debug values &inline on text editors (Experimental)
LaunchingPreferencePage_1=&Build (if required) before launching
LaunchingPreferencePage_2=Save required dirty editors before launching
@@ -93,11 +94,12 @@ LaunchingPreferencePage_39=Launch the associated pro&ject
LaunchingPreferencePage_40=Launch Operation
LaunchingPreferencePage_41=La&unch the previously launched application
LaunchingPreferencePage_confirm_0=Prompt for confirmation when removin&g a configuration from the launch history
-LaunchingPreferencePage_42=Termin&ate and Relaunch while launching (Press 'Shift' to toggle during launch from menu and toolbar)
+LaunchingPreferencePage_42=Termin&ate and relaunch while launching (Press 'Shift' to toggle during launch from menu and toolbar)
ProcessPropertyPage_Command_Line__1=Co&mmand Line:
ProcessPropertyPage_0=Run-&at time:
ProcessPropertyPage_10=&Terminated-at time:
+ProcessPropertyPage_11=PID:
ProcessPropertyPage_1=&Path:
ProcessPropertyPage_2=Process properties
ProcessPropertyPage_3=No path information available
@@ -133,7 +135,7 @@ StringVariablePreferencePage_23=Cannot overwrite read-only variable
StringVariablePreferencePage_22=A read-only variable named {0} already exists. Read-only variables can not be overwritten.
StringVariablePreferencePage_21=Problem creating variable
StringVariablePreferencePage_20=Variables cannot have an empty name.
-ViewManagementPreferencePage_0=The Debug View can automatically open and close views based on selection. Choose in which perspectives this feature should be enabled:
+ViewManagementPreferencePage_0=The 'Debug' view can automatically open and close views based on selection. Choose in which perspectives this feature should be enabled:
ViewManagementPreferencePage_1=View Management
ViewManagementPreferencePage_2=&Perspectives:
ViewManagementPreferencePage_3=Do &not automatically open/close views which have been manually closed/opened.
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchPerspectivePreferencePage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchPerspectivePreferencePage.java
index c6055fad0..2fc1bb843 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchPerspectivePreferencePage.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchPerspectivePreferencePage.java
@@ -127,7 +127,7 @@ public class LaunchPerspectivePreferencePage extends PreferencePage implements I
/**
* Provides content for the configuration tree viewer
*/
- final class PerspectiveContentProvider implements ITreeContentProvider {
+ static final class PerspectiveContentProvider implements ITreeContentProvider {
@Override
public Object[] getChildren(Object parentElement) {
if(parentElement instanceof ILaunchConfigurationType) {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchersPreferencePage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchersPreferencePage.java
index a76918943..77f4c36c4 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchersPreferencePage.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/LaunchersPreferencePage.java
@@ -65,7 +65,7 @@ public class LaunchersPreferencePage extends PreferencePage implements IWorkbenc
/**
* Class to collect and persist attributes to sufficiently describe a duplicate launch delegate
*/
- class DuplicateDelegate {
+ static class DuplicateDelegate {
private ILaunchConfigurationType fType = null;
private ILaunchDelegate[] fDelegates = null;
private Set<String> fModes = null;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/ProcessPropertyPage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/ProcessPropertyPage.java
index 4e10ecc43..4e086e8ad 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/ProcessPropertyPage.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/ProcessPropertyPage.java
@@ -57,10 +57,18 @@ public class ProcessPropertyPage extends PropertyPage {
Composite parent = SWTFactory.createComposite(ancestor, ancestor.getFont(), 1, 1, GridData.FILL_BOTH);
IProcess proc = getProcess();
-
+ Text text;
+ if (proc.getAttribute(IProcess.ATTR_PROCESS_ID) != null) {
+ SWTFactory.createLabel(parent, DebugPreferencesMessages.ProcessPropertyPage_11, fHeadingFont, 1);
+ text = SWTFactory.createText(parent, SWT.READ_ONLY, 1);
+ ((GridData) text.getLayoutData()).horizontalIndent = 10;
+ text.setText(proc.getAttribute(IProcess.ATTR_PROCESS_ID));
+ text.setBackground(parent.getBackground());
+ SWTFactory.createVerticalSpacer(parent, 2);
+ }
// create the process launch time section
SWTFactory.createLabel(parent, DebugPreferencesMessages.ProcessPropertyPage_0, fHeadingFont, 1);
- Text text = SWTFactory.createText(parent, SWT.READ_ONLY, 1);
+ text = SWTFactory.createText(parent, SWT.READ_ONLY, 1);
((GridData)text.getLayoutData()).horizontalIndent = 10;
PlatformUI.getWorkbench().getHelpSystem().setHelp(text, IDebugHelpContextIds.PROCESS_PAGE_RUN_AT);
text.setText(getLaunchTimeText(proc));
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/StringVariablePreferencePage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/StringVariablePreferencePage.java
index b03ab1e77..b6a8adaac 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/StringVariablePreferencePage.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/StringVariablePreferencePage.java
@@ -564,7 +564,7 @@ public class StringVariablePreferencePage extends PreferencePage implements IWor
}
- class VariableWrapper {
+ static class VariableWrapper {
protected IValueVariable fVariable;
protected String fNewName = null;
@@ -722,7 +722,7 @@ public class StringVariablePreferencePage extends PreferencePage implements IWor
}
}
- class VariableFilter extends ViewerFilter {
+ static class VariableFilter extends ViewerFilter {
@Override
public boolean select(Viewer viewer, Object parentElement, Object element) {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupFacility.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupFacility.java
index a3ee70ba9..74e359d73 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupFacility.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupFacility.java
@@ -15,9 +15,13 @@
*******************************************************************************/
package org.eclipse.debug.internal.ui.sourcelookup;
-import java.util.ArrayList;
+import java.util.Collections;
import java.util.HashMap;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.LinkedHashSet;
import java.util.Map;
+import java.util.Objects;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IProgressMonitor;
@@ -69,6 +73,7 @@ import org.eclipse.ui.IReusableEditor;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.IWorkbenchPartReference;
+import org.eclipse.ui.IWorkbenchPartSite;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.progress.UIJob;
@@ -87,10 +92,9 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
*
* @since 3.10
*/
- static class LRU extends HashMap<Object, SourceLookupResult> {
+ static class LRU extends LinkedHashMap<Object, SourceLookupResult> {
private static final long serialVersionUID = 1L;
- ArrayList<Object> fEntryStack = null;
int fSize;
/**
@@ -99,44 +103,14 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
* @param size The desired size
*/
LRU(int size) {
+ // true == use this map like LRU cache
+ super(size, 0.75f, true);
fSize = size;
- fEntryStack = new ArrayList<>();
}
@Override
- public SourceLookupResult put(Object key, SourceLookupResult value) {
- shuffle(key);
- return super.put(key, value);
- }
-
- @Override
- public SourceLookupResult remove(Object key) {
- SourceLookupResult oldResult = super.remove(key);
- fEntryStack.remove(key);
- return oldResult;
- }
-
- /**
- * Shuffles the entry stack and removes mapped results as needed
- *
- * @param key
- */
- void shuffle(Object key) {
- int index = fEntryStack.indexOf(key);
- if (index < 0) {
- if (fEntryStack.size() >= fSize) {
- remove(fEntryStack.get(fEntryStack.size() - 1));
- }
- } else {
- fEntryStack.remove(index);
- }
- fEntryStack.add(0, key);
- }
-
- @Override
- public void clear() {
- fEntryStack.clear();
- super.clear();
+ protected boolean removeEldestEntry(Map.Entry<Object, SourceLookupResult> eldest) {
+ return size() > fSize;
}
}
@@ -157,7 +131,7 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
*
* @since 3.10
*/
- private static LRU fLookupResults = new LRU(10);
+ private final Map<Object, SourceLookupResult> fLookupResults = Collections.synchronizedMap(new LRU(10));
/**
* Used to generate annotations for stack frames
@@ -169,6 +143,9 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
*/
private boolean fReuseEditor = DebugUIPlugin.getDefault().getPreferenceStore().getBoolean(IDebugUIConstants.PREF_REUSE_EDITOR);
+ /** Singleton job to process source lookup requests */
+ private final SourceLookupJob sourceLookupJob;
+
/**
* Constructs singleton source display adapter for stack frames.
*/
@@ -198,6 +175,7 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
*/
private SourceLookupFacility() {
fEditorsByPage = new HashMap<>();
+ sourceLookupJob = new SourceLookupJob();
DebugUIPlugin.getDefault().getPreferenceStore().addPropertyChangeListener(this);
DebugPlugin.getDefault().addDebugEventListener(this);
}
@@ -236,7 +214,7 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
}
}
- private class ArtifactWithLocator {
+ private static class ArtifactWithLocator {
public final Object artifact;
public final ISourceLocator locator;
public ArtifactWithLocator(Object artifact, ISourceLocator locator) {
@@ -246,12 +224,7 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
@Override
public int hashCode() {
- final int prime = 31;
- int result = 1;
- result = prime * result + getOuterType().hashCode();
- result = prime * result + ((artifact == null) ? 0 : artifact.hashCode());
- result = prime * result + ((locator == null) ? 0 : locator.hashCode());
- return result;
+ return 31 + Objects.hash(artifact, locator);
}
@Override
@@ -259,36 +232,30 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
if (this == obj) {
return true;
}
- if (obj == null) {
- return false;
- }
- if (getClass() != obj.getClass()) {
+ if (!(obj instanceof ArtifactWithLocator)) {
return false;
}
ArtifactWithLocator other = (ArtifactWithLocator) obj;
- if (!getOuterType().equals(other.getOuterType())) {
- return false;
- }
- if (artifact == null) {
- if (other.artifact != null) {
- return false;
- }
- } else if (!artifact.equals(other.artifact)) {
- return false;
+ return Objects.equals(artifact, other.artifact) && Objects.equals(locator, other.locator);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder builder = new StringBuilder();
+ builder.append("ArtifactWithLocator ["); //$NON-NLS-1$
+ if (artifact != null) {
+ builder.append("artifact="); //$NON-NLS-1$
+ builder.append(artifact);
+ builder.append(", "); //$NON-NLS-1$
}
- if (locator == null) {
- if (other.locator != null) {
- return false;
- }
- } else if (!locator.equals(other.locator)) {
- return false;
+ if (locator != null) {
+ builder.append("locator="); //$NON-NLS-1$
+ builder.append(locator);
}
- return true;
+ builder.append("]"); //$NON-NLS-1$
+ return builder.toString();
}
- private SourceLookupFacility getOuterType() {
- return SourceLookupFacility.this;
- }
}
/**
@@ -304,74 +271,70 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
*/
public SourceLookupResult lookup(Object artifact, ISourceLocator locator, boolean force) {
SourceLookupResult result = null;
- synchronized (fLookupResults) {
- ArtifactWithLocator key = new ArtifactWithLocator(artifact, locator);
- if (!force) {
- result = fLookupResults.get(key);
- if (result != null) {
- return result;
- }
+ ArtifactWithLocator key = new ArtifactWithLocator(artifact, locator);
+ if (!force) {
+ result = fLookupResults.get(key);
+ if (result != null) {
+ return result;
}
- result = new SourceLookupResult(artifact, null, null, null);
- IDebugElement debugElement = null;
- if (artifact instanceof IDebugElement) {
- debugElement = (IDebugElement) artifact;
+ }
+ IDebugElement debugElement = null;
+ if (artifact instanceof IDebugElement) {
+ debugElement = (IDebugElement) artifact;
+ }
+ ISourceLocator localLocator = locator;
+ if (localLocator == null) {
+ ILaunch launch = null;
+ if (debugElement != null) {
+ launch = debugElement.getLaunch();
}
- ISourceLocator localLocator = locator;
- if (localLocator == null) {
- ILaunch launch = null;
- if (debugElement != null) {
- launch = debugElement.getLaunch();
- }
- if (launch != null) {
- localLocator = launch.getSourceLocator();
- }
+ if (launch != null) {
+ localLocator = launch.getSourceLocator();
}
- if (localLocator != null) {
- String editorId = null;
- IEditorInput editorInput = null;
- Object sourceElement = null;
- if (localLocator instanceof ISourceLookupDirector) {
- ISourceLookupDirector director = (ISourceLookupDirector) localLocator;
- sourceElement = director.getSourceElement(artifact);
- } else {
- if (artifact instanceof IStackFrame) {
- sourceElement = localLocator.getSourceElement((IStackFrame) artifact);
- }
+ }
+ if (localLocator == null) {
+ return new SourceLookupResult(artifact, null, null, null);
+ }
+ String editorId = null;
+ IEditorInput editorInput = null;
+ Object sourceElement = null;
+ if (localLocator instanceof ISourceLookupDirector) {
+ ISourceLookupDirector director = (ISourceLookupDirector) localLocator;
+ sourceElement = director.getSourceElement(artifact);
+ } else {
+ if (artifact instanceof IStackFrame) {
+ sourceElement = localLocator.getSourceElement((IStackFrame) artifact);
+ }
+ }
+ if (sourceElement == null) {
+ if (localLocator instanceof AbstractSourceLookupDirector) {
+ editorInput = new CommonSourceNotFoundEditorInput(artifact);
+ editorId = IDebugUIConstants.ID_COMMON_SOURCE_NOT_FOUND_EDITOR;
+ } else {
+ if (artifact instanceof IStackFrame) {
+ IStackFrame frame = (IStackFrame) artifact;
+ editorInput = new SourceNotFoundEditorInput(frame);
+ editorId = IInternalDebugUIConstants.ID_SOURCE_NOT_FOUND_EDITOR;
}
- if (sourceElement == null) {
- if (localLocator instanceof AbstractSourceLookupDirector) {
- editorInput = new CommonSourceNotFoundEditorInput(artifact);
- editorId = IDebugUIConstants.ID_COMMON_SOURCE_NOT_FOUND_EDITOR;
- } else {
- if (artifact instanceof IStackFrame) {
- IStackFrame frame = (IStackFrame) artifact;
- editorInput = new SourceNotFoundEditorInput(frame);
- editorId = IInternalDebugUIConstants.ID_SOURCE_NOT_FOUND_EDITOR;
- }
- }
- } else {
- ISourcePresentation presentation = null;
- if (localLocator instanceof ISourcePresentation) {
- presentation = (ISourcePresentation) localLocator;
- } else {
- if (debugElement != null) {
- presentation = getPresentation(debugElement.getModelIdentifier());
- }
- }
- if (presentation != null) {
- editorInput = presentation.getEditorInput(sourceElement);
- }
- if (editorInput != null && presentation != null) {
- editorId = presentation.getEditorId(editorInput, sourceElement);
- }
+ }
+ } else {
+ ISourcePresentation presentation = null;
+ if (localLocator instanceof ISourcePresentation) {
+ presentation = (ISourcePresentation) localLocator;
+ } else {
+ if (debugElement != null) {
+ presentation = getPresentation(debugElement.getModelIdentifier());
}
- result.setEditorInput(editorInput);
- result.setEditorId(editorId);
- result.setSourceElement(sourceElement);
- fLookupResults.put(key, result);
+ }
+ if (presentation != null) {
+ editorInput = presentation.getEditorInput(sourceElement);
+ }
+ if (editorInput != null && presentation != null) {
+ editorId = presentation.getEditorId(editorInput, sourceElement);
}
}
+ result = new SourceLookupResult(artifact, sourceElement, editorId, editorInput);
+ fLookupResults.put(key, result);
return result;
}
@@ -467,7 +430,7 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
// open a new editor
editor = openEditor(page, input, id);
editorForPage = editor;
- } else if (editorForPage instanceof IReusableEditor && editorForPage.getSite().getId().equals(id)) {
+ } else if (canReuseEditor(input, id, editorForPage)) {
// re-use editor
page.reuseEditor((IReusableEditor)editorForPage, input);
editor = editorForPage;
@@ -477,8 +440,10 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
} else {
// close editor, open a new one
editor = openEditor(page, input, id);
- page.closeEditor(editorForPage, false);
- editorForPage = editor;
+ if (editor != editorForPage) {
+ page.closeEditor(editorForPage, false);
+ editorForPage = editor;
+ }
}
setEditor(page, editorForPage);
}
@@ -489,6 +454,22 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
return editor;
}
+ private static boolean canReuseEditor(IEditorInput input, String id, IEditorPart editorForPage) {
+ if (!(editorForPage instanceof IReusableEditor)) {
+ return false;
+ }
+ IWorkbenchPartSite site = editorForPage.getSite();
+ if (site == null) {
+ // editor is disposed
+ return false;
+ }
+ if (site.getId().equals(id)) {
+ return true;
+ }
+ IEditorInput editorInput = editorForPage.getEditorInput();
+ return editorInput != null && input.equals(editorInput);
+ }
+
/**
* Positions the text editor for the given stack frame
*/
@@ -510,10 +491,14 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
}
/**
- * Returns the line information for the given line in the given editor
+ * Returns the line information for the given line in the given editor, or
+ * {@code null} if no information could be retrieved or error happens
*/
private IRegion getLineInformation(ITextEditor editor, int lineNumber) {
IDocumentProvider provider= editor.getDocumentProvider();
+ if (provider == null) {
+ return null;
+ }
IEditorInput input= editor.getEditorInput();
try {
provider.connect(input);
@@ -669,110 +654,283 @@ public class SourceLookupFacility implements IPageListener, IPartListener2, IPro
fEditorsByPage.clear();
fPresentation.dispose();
fLookupResults.clear();
+ sourceLookupJob.cancel();
}
/**
- * A job to perform source lookup on the currently selected stack frame.
+ * A singleton job to perform source lookups via given {@link SourceLookupTask}
+ * objects. The tasks are put in the queue to process in the background,
+ * duplicated tasks are ignored. Job re-schedules itself if new task is added to
+ * the queue.
*/
- class SourceLookupJob extends Job {
+ final class SourceLookupJob extends Job {
- private IStackFrame fTarget;
- private ISourceLocator fLocator;
- private IWorkbenchPage fPage;
- private boolean fForce = false;
+ private final LinkedHashSet<SourceLookupTask> queue;
+ private final SourceDisplayJob sourceDisplayJob;
- /**
- * Constructs a new source lookup job.
- */
- public SourceLookupJob(IStackFrame frame, ISourceLocator locator, IWorkbenchPage page, boolean force) {
+ public SourceLookupJob() {
super("Debug Source Lookup"); //$NON-NLS-1$
- setPriority(Job.INTERACTIVE);
+ this.sourceDisplayJob = new SourceDisplayJob();
+ this.queue = new LinkedHashSet<>();
setSystem(true);
- fTarget = frame;
- fLocator = locator;
- fPage = page;
- fForce = force;
+ setPriority(Job.INTERACTIVE);
// Note: Be careful when trying to use scheduling rules with this
// job, in order to avoid blocking nested jobs (bug 339542).
}
@Override
+ public boolean belongsTo(Object family) {
+ return family instanceof SourceLookupFacility;
+ }
+
+ @Override
protected IStatus run(IProgressMonitor monitor) {
+ SourceLookupTask next;
+ while ((next = poll()) != null && !monitor.isCanceled()) {
+ SourceDisplayRequest uiTask = next.run(monitor);
+ if (uiTask != null) {
+ sourceDisplayJob.schedule(uiTask);
+ }
+ }
+
+ synchronized (queue) {
+ if (monitor.isCanceled()) {
+ queue.clear();
+ return Status.CANCEL_STATUS;
+ } else if (!queue.isEmpty()) {
+ schedule(100);
+ }
+ }
+ return Status.OK_STATUS;
+ }
+
+ private SourceLookupTask poll() {
+ SourceLookupTask next = null;
+ synchronized (queue) {
+ if (!queue.isEmpty()) {
+ Iterator<SourceLookupTask> iterator = queue.iterator();
+ next = iterator.next();
+ iterator.remove();
+ }
+ }
+ return next;
+ }
+
+ void schedule(SourceLookupTask task) {
+ synchronized (queue) {
+ boolean added = queue.add(task);
+ if (added) {
+ schedule(100);
+ }
+ }
+ }
+ }
+
+ /**
+ * A task to perform source lookup on the currently selected stack frame.
+ */
+ class SourceLookupTask {
+
+ final IStackFrame fTarget;
+ final ISourceLocator fLocator;
+ final IWorkbenchPage fPage;
+ final boolean fForce;
+
+ /**
+ * Constructs a new source lookup task.
+ */
+ public SourceLookupTask(IStackFrame frame, ISourceLocator locator, IWorkbenchPage page, boolean force) {
+ fTarget = frame;
+ fLocator = locator;
+ fPage = page;
+ fForce = force;
+ }
+
+ protected SourceDisplayRequest run(IProgressMonitor monitor) {
if (!monitor.isCanceled()) {
if (!fTarget.isTerminated()) {
- ISourceLookupResult result = lookup(fTarget, fLocator, fForce);
- if (!monitor.isCanceled() && !fTarget.isTerminated() && fPage != null) {
- new SourceDisplayJob(result, fPage).schedule();
+ SourceLookupResult result = lookup(fTarget, fLocator, fForce);
+ if (!monitor.isCanceled() && !fTarget.isTerminated() && fPage != null && result != null) {
+ return new SourceDisplayRequest(result, fPage);
}
}
}
- return Status.OK_STATUS;
+ return null;
}
@Override
- public boolean belongsTo(Object family) {
- // source lookup jobs are a family per workbench page
- if (family instanceof SourceLookupJob) {
- SourceLookupJob slj = (SourceLookupJob) family;
- return slj.fPage.equals(fPage);
+ public int hashCode() {
+ return 31 + Objects.hash(fForce, fLocator, fPage, fTarget);
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj) {
+ return true;
}
- return false;
+ if (!(obj instanceof SourceLookupTask)) {
+ return false;
+ }
+ SourceLookupTask other = (SourceLookupTask) obj;
+ return fForce == other.fForce && Objects.equals(fPage, other.fPage)
+ && Objects.equals(fLocator, other.fLocator) && Objects.equals(fTarget, other.fTarget);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder builder = new StringBuilder();
+ builder.append("SourceLookupTask ["); //$NON-NLS-1$
+ if (fTarget != null) {
+ builder.append("target="); //$NON-NLS-1$
+ builder.append(fTarget);
+ builder.append(", "); //$NON-NLS-1$
+ }
+ builder.append("force="); //$NON-NLS-1$
+ builder.append(fForce);
+ builder.append(", "); //$NON-NLS-1$
+ if (fLocator != null) {
+ builder.append("locator="); //$NON-NLS-1$
+ builder.append(fLocator);
+ builder.append(", "); //$NON-NLS-1$
+ }
+ if (fPage != null) {
+ builder.append("page="); //$NON-NLS-1$
+ builder.append(fPage);
+ }
+ builder.append("]"); //$NON-NLS-1$
+ return builder.toString();
+ }
+
+ }
+
+ /**
+ * A request to show the result of the source lookup in the UI
+ */
+ static class SourceDisplayRequest {
+
+ final SourceLookupResult fResult;
+ final IWorkbenchPage fPage;
+
+ public SourceDisplayRequest(SourceLookupResult result, IWorkbenchPage page) {
+ fResult = result;
+ fPage = page;
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(fPage, fResult);
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj) {
+ return true;
+ }
+ if (!(obj instanceof SourceDisplayRequest)) {
+ return false;
+ }
+ SourceDisplayRequest other = (SourceDisplayRequest) obj;
+ return Objects.equals(fPage, other.fPage) && Objects.equals(fResult, other.fResult);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder builder = new StringBuilder();
+ builder.append("SourceDisplayRequest ["); //$NON-NLS-1$
+ if (fResult != null) {
+ builder.append("result="); //$NON-NLS-1$
+ builder.append(fResult);
+ builder.append(", "); //$NON-NLS-1$
+ }
+ if (fPage != null) {
+ builder.append("page="); //$NON-NLS-1$
+ builder.append(fPage);
+ }
+ builder.append("]"); //$NON-NLS-1$
+ return builder.toString();
}
}
+ /**
+ * A singleton job to show the result of the source lookup in the UI for given
+ * {@link SourceDisplayRequest} objects. The requests are put in the queue to
+ * process in the background, duplicated requests are ignored. Job re-schedules
+ * itself if new request is added to the queue.
+ */
class SourceDisplayJob extends UIJob {
- private ISourceLookupResult fResult;
- private IWorkbenchPage fPage;
+ private final LinkedHashSet<SourceDisplayRequest> queue;
- public SourceDisplayJob(ISourceLookupResult result, IWorkbenchPage page) {
+ public SourceDisplayJob() {
super("Debug Source Display"); //$NON-NLS-1$
setSystem(true);
setPriority(Job.INTERACTIVE);
- fResult = result;
- fPage = page;
+ this.queue = new LinkedHashSet<>();
}
+
@Override
public IStatus runInUIThread(IProgressMonitor monitor) {
- if (!monitor.isCanceled() && fResult != null) {
- display(fResult, fPage);
- // termination may have occurred while displaying source
- if (monitor.isCanceled()) {
- Object artifact = fResult.getArtifact();
+ SourceDisplayRequest next;
+ // Do not break on cancelled monitor, to allow remove debugger
+ // annotations from already opened editors
+ while ((next = poll()) != null) {
+ IWorkbenchPage page = next.fPage;
+ if (page.getWorkbenchWindow() == null) {
+ // don't try to update if page is closed
+ continue;
+ }
+ ISourceLookupResult result = next.fResult;
+ if (!monitor.isCanceled()) {
+ display(result, page);
+ } else {
+ // termination may have occurred while displaying source
+ Object artifact = result.getArtifact();
if (artifact instanceof IStackFrame) {
clearSourceSelection(((IStackFrame) artifact).getThread());
}
}
}
-
return Status.OK_STATUS;
}
+ private SourceDisplayRequest poll() {
+ SourceDisplayRequest next = null;
+ synchronized (queue) {
+ if (!queue.isEmpty()) {
+ Iterator<SourceDisplayRequest> iterator = queue.iterator();
+ next = iterator.next();
+ iterator.remove();
+ }
+ }
+ return next;
+ }
+
+ void schedule(SourceDisplayRequest task) {
+ synchronized (queue) {
+ boolean added = queue.add(task);
+ if (added) {
+ schedule(100);
+ }
+ }
+ }
+
@Override
public boolean belongsTo(Object family) {
- // source display jobs are a family per workbench page
- if (family instanceof SourceDisplayJob) {
- SourceDisplayJob sdj = (SourceDisplayJob) family;
- return sdj.fPage.equals(fPage);
- }
- return false;
+ return family instanceof SourceLookupFacility;
}
}
/*
- * @see
- * org.eclipse.debug.ui.contexts.ISourceDisplayAdapter#displaySource(java
- * .lang.Object, org.eclipse.ui.IWorkbenchPage, boolean)
+ * See org.eclipse.debug.ui.sourcelookup.ISourceDisplay
*/
- public synchronized void displaySource(Object context, IWorkbenchPage page, boolean force) {
+ public void displaySource(Object context, IWorkbenchPage page, boolean force) {
IStackFrame frame = (IStackFrame) context;
- SourceLookupJob slj = new SourceLookupJob(frame, frame.getLaunch().getSourceLocator(), page, force);
- // cancel any existing source lookup jobs for this page
- Job.getJobManager().cancel(slj);
- slj.schedule();
+ SourceLookupTask slj = new SourceLookupTask(frame, frame.getLaunch().getSourceLocator(), page, force);
+ // will drop any existing equal source lookup jobs
+ sourceLookupJob.schedule(slj);
}
/**
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupResult.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupResult.java
index c524b8cff..55ab38932 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupResult.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/sourcelookup/SourceLookupResult.java
@@ -13,6 +13,8 @@
*******************************************************************************/
package org.eclipse.debug.internal.ui.sourcelookup;
+import java.util.Objects;
+
import org.eclipse.debug.ui.sourcelookup.ISourceLookupResult;
import org.eclipse.ui.IEditorInput;
@@ -27,22 +29,22 @@ public class SourceLookupResult implements ISourceLookupResult {
/**
* Element that source was resolved for.
*/
- private Object fArtifact;
+ private final Object fArtifact;
/**
* Corresponding source element, or <code>null</code>
* if unknown.
*/
- private Object fSourceElement;
+ private final Object fSourceElement;
/**
* Associated editor id, used to display the source element,
* or <code>null</code> if unknown.
*/
- private String fEditorId;
+ private final String fEditorId;
/**
* Associated editor input, used to display the source element,
* or <code>null</code> if unknown.
*/
- private IEditorInput fEditorInput;
+ private final IEditorInput fEditorInput;
/**
* Creates a source lookup result on the given artifact, source element,
@@ -50,9 +52,9 @@ public class SourceLookupResult implements ISourceLookupResult {
*/
public SourceLookupResult(Object artifact, Object sourceElement, String editorId, IEditorInput editorInput) {
fArtifact = artifact;
- setSourceElement(sourceElement);
- setEditorId(editorId);
- setEditorInput(editorInput);
+ fSourceElement = sourceElement;
+ fEditorId = editorId;
+ fEditorInput = editorInput;
}
@Override
@@ -65,60 +67,63 @@ public class SourceLookupResult implements ISourceLookupResult {
return fSourceElement;
}
- /**
- * Sets the source element resolved for the artifact that source
- * lookup was performed for, or <code>null</code> if a source element
- * was not resolved.
- *
- * @param element resolved source element or <code>null</code> if unknown
- */
- protected void setSourceElement(Object element) {
- fSourceElement = element;
- }
-
@Override
public String getEditorId() {
return fEditorId;
}
- /**
- * Sets the identifier of the editor used to display this source
- * lookup result's source element, or <code>null</code> if unknown.
- *
- * @param id the identifier of the editor used to display this source
- * lookup result's source element, or <code>null</code> if unknown
- */
- protected void setEditorId(String id) {
- fEditorId = id;
- }
-
@Override
public IEditorInput getEditorInput() {
return fEditorInput;
}
- /**
- * Sets the editor input used to display this source lookup
- * result's source element, or <code>null</code> if unknown.
- *
- * @param input the editor input used to display this source lookup
- * result's source element, or <code>null</code> if unknown
- */
- protected void setEditorInput(IEditorInput input) {
- fEditorInput = input;
+ @Override
+ public int hashCode() {
+ return Objects.hash(fArtifact, fEditorId, fEditorInput, fSourceElement);
}
- /**
- * Updates the artifact to refer to the given artifact
- * if equal. For example, when a source lookup result is reused
- * for the same stack frame, we still need to update in case
- * the stack frame is not identical.
- *
- * @param artifact new artifact state
- */
- public void updateArtifact(Object artifact) {
- if (fArtifact.equals(artifact)) {
- fArtifact = artifact;
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj) {
+ return true;
+ }
+
+ if (!(obj instanceof SourceLookupResult)) {
+ return false;
}
+
+ SourceLookupResult other = (SourceLookupResult) obj;
+ return Objects.equals(fEditorId, other.fEditorId)
+ && Objects.equals(fArtifact, other.fArtifact)
+ && Objects.equals(fEditorInput, other.fEditorInput)
+ && Objects.equals(fSourceElement, other.fSourceElement);
}
+
+ @Override
+ public String toString() {
+ StringBuilder builder = new StringBuilder();
+ builder.append("SourceLookupResult ["); //$NON-NLS-1$
+ if (fEditorId != null) {
+ builder.append("editorId="); //$NON-NLS-1$
+ builder.append(fEditorId);
+ builder.append(", "); //$NON-NLS-1$
+ }
+ if (fEditorInput != null) {
+ builder.append("editorInput="); //$NON-NLS-1$
+ builder.append(fEditorInput);
+ builder.append(", "); //$NON-NLS-1$
+ }
+ if (fArtifact != null) {
+ builder.append("artifact="); //$NON-NLS-1$
+ builder.append(fArtifact);
+ builder.append(", "); //$NON-NLS-1$
+ }
+ if (fSourceElement != null) {
+ builder.append("sourceElement="); //$NON-NLS-1$
+ builder.append(fSourceElement);
+ }
+ builder.append("]"); //$NON-NLS-1$
+ return builder.toString();
+ }
+
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousModel.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousModel.java
index fdb5cc03c..e09b9bfc7 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousModel.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousModel.java
@@ -66,7 +66,7 @@ public abstract class AsynchronousModel {
private AsynchronousViewer fViewer; // viewer this model works for
private boolean fDisposed = false; // whether disposed
- class EmptyContentAdapter extends AsynchronousContentAdapter {
+ static class EmptyContentAdapter extends AsynchronousContentAdapter {
@Override
protected Object[] getChildren(Object parent, IPresentationContext context) throws CoreException {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousSchedulingRuleFactory.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousSchedulingRuleFactory.java
index a9f1a0c4b..4f05e0bc8 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousSchedulingRuleFactory.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousSchedulingRuleFactory.java
@@ -27,7 +27,7 @@ public class AsynchronousSchedulingRuleFactory {
/**
* Rule allows only one job to run at a time
*/
- class SerialRule implements ISchedulingRule {
+ static class SerialRule implements ISchedulingRule {
public SerialRule() {
}
@@ -43,7 +43,7 @@ public class AsynchronousSchedulingRuleFactory {
}
}
- class SerialPerObjectRule implements ISchedulingRule {
+ static class SerialPerObjectRule implements ISchedulingRule {
private Object fObject = null;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousViewer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousViewer.java
index aba77c7ab..b287456c9 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousViewer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/AsynchronousViewer.java
@@ -643,7 +643,7 @@ public abstract class AsynchronousViewer extends StructuredViewer implements Lis
/**
* A content provider that does nothing.
*/
- private class NullContentProvider implements IStructuredContentProvider {
+ private static class NullContentProvider implements IStructuredContentProvider {
@Override
public void dispose() {
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/InternalTreeModelViewer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/InternalTreeModelViewer.java
index c7c4325a5..64215e31c 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/InternalTreeModelViewer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/InternalTreeModelViewer.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2006, 2016 IBM Corporation and others.
+ * Copyright (c) 2006, 2022 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -1776,6 +1776,9 @@ public class InternalTreeModelViewer extends TreeViewer implements IInternalTree
@Override
protected void handleTreeCollapse(TreeEvent event) {
+ if (event.item.isDisposed()) {
+ return;
+ }
super.handleTreeCollapse(event);
IContentProvider contentProvider = getContentProvider();
if (contentProvider instanceof TreeModelContentProvider && event.item.getData() != null) {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/TreeModelContentProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/TreeModelContentProvider.java
index 4ed94c55a..c00ae9ffe 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/TreeModelContentProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/TreeModelContentProvider.java
@@ -401,6 +401,9 @@ public class TreeModelContentProvider implements ITreeModelContentProvider, ICon
private class DelayedDoModelChangedJob extends WorkbenchJob {
+ // limit batch size to avoid freezing the UI.
+ private static final int MAX_BATCH_SIZE = 100;
+
// queue of submitted deltas to process
private final List<Object> fQueue = new ArrayList<>();
private boolean shutdown;
@@ -418,8 +421,18 @@ public class TreeModelContentProvider implements ITreeModelContentProvider, ICon
if (shutdown || fQueue.isEmpty()) {
return Status.OK_STATUS;
}
- currentBatch = new ArrayList<>(fQueue);
- fQueue.clear();
+ fQueue.removeIf(o -> {
+ if (currentBatch.size() < MAX_BATCH_SIZE) {
+ currentBatch.add(o);
+ return true;
+ }
+ return false;
+ });
+ if (!fQueue.isEmpty()) {
+ // There is work left.
+ // Give other UI tasks chance to work instead of freezing UI
+ schedule();
+ }
}
if (DebugUIPlugin.DEBUG_CONTENT_PROVIDER) {
DebugUIPlugin.trace("Delayed batch size: " + currentBatch.size()); //$NON-NLS-1$
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualCopyToClipboardActionDelegate.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualCopyToClipboardActionDelegate.java
index cab30d7f1..1c46d887f 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualCopyToClipboardActionDelegate.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualCopyToClipboardActionDelegate.java
@@ -171,7 +171,7 @@ public class VirtualCopyToClipboardActionDelegate extends AbstractDebugActionDel
return label.trim();
}
- private class ItemsToCopyVirtualItemValidator implements IVirtualItemValidator {
+ private static class ItemsToCopyVirtualItemValidator implements IVirtualItemValidator {
Set<VirtualItem> fItemsToCopy = Collections.EMPTY_SET;
Set<VirtualItem> fItemsToValidate = Collections.EMPTY_SET;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualFindAction.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualFindAction.java
index f427d443a..af81638b5 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualFindAction.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/VirtualFindAction.java
@@ -61,7 +61,7 @@ public class VirtualFindAction extends Action implements IUpdate {
private TreeModelViewer fClientViewer;
- private class VirtualViewerListener implements IViewerUpdateListener, ILabelUpdateListener {
+ private static class VirtualViewerListener implements IViewerUpdateListener, ILabelUpdateListener {
private boolean fViewerUpdatesComplete = false;
private boolean fLabelUpdatesComplete = false;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointOrganizerManager.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointOrganizerManager.java
index c1eab4725..f02f3569d 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointOrganizerManager.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointOrganizerManager.java
@@ -16,6 +16,7 @@ package org.eclipse.debug.internal.ui.views.breakpoints;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
+import java.util.Comparator;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@@ -117,7 +118,7 @@ public class BreakpointOrganizerManager {
Collection<IBreakpointOrganizer> collection = fOrganizers.values();
fSorted = new ArrayList<>();
fSorted.addAll(collection);
- Collections.sort(fSorted, (o1, o2) -> o1.getLabel().compareTo(o2.getLabel()));
+ Collections.sort(fSorted, Comparator.comparing(IBreakpointOrganizer::getLabel));
}
return fSorted.toArray(new IBreakpointOrganizer[fSorted.size()]);
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointsView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointsView.java
index 4a4fdefd8..c767ac88b 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointsView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/breakpoints/BreakpointsView.java
@@ -1,5 +1,5 @@
/*****************************************************************
- * Copyright (c) 2009, 2018 Texas Instruments and others
+ * Copyright (c) 2009, 2021 Texas Instruments and others
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -196,8 +196,11 @@ public class BreakpointsView extends VariablesView implements IBreakpointManager
menu.add(getAction(ACTION_GOTO_MARKER));
menu.add(new Separator(IDebugUIConstants.EMPTY_BREAKPOINT_GROUP));
menu.add(new Separator(IDebugUIConstants.BREAKPOINT_GROUP));
- menu.add(getAction(PASTE_ACTION));
- IAction action = getAction(ACTION_REMOVE_FROM_GROUP);
+ IAction action = getAction(PASTE_ACTION);
+ if (action != null) {
+ menu.add(action);
+ }
+ action = getAction(ACTION_REMOVE_FROM_GROUP);
if (action != null && action.isEnabled()) {
menu.add(action);
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java
index 472a894e0..2799ab0b5 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java
@@ -361,6 +361,13 @@ public class ProcessConsole extends IOConsole implements IConsole, IDebugEventSe
buffer.append(MessageFormat.format(ConsoleMessages.ProcessConsole_commandLabel_withEnd,
procLabel, dateTimeFormat.format(terminateTime)));
}
+
+ String pid = process.getAttribute(IProcess.ATTR_PROCESS_ID);
+ if (pid != null && !pid.isBlank()) {
+ buffer.append(" [pid: "); //$NON-NLS-1$
+ buffer.append(pid);
+ buffer.append("]"); //$NON-NLS-1$
+ }
label = buffer.toString();
}
}
@@ -989,7 +996,7 @@ public class ProcessConsole extends IOConsole implements IConsole, IDebugEventSe
}
}
- private class ConsoleLogFileHyperlink implements IHyperlink {
+ private static class ConsoleLogFileHyperlink implements IHyperlink {
String fFilePath;
ConsoleLogFileHyperlink(String filePath) {
fFilePath = filePath;
@@ -1024,7 +1031,7 @@ public class ProcessConsole extends IOConsole implements IConsole, IDebugEventSe
}
}
- class StorageEditorInput extends PlatformObject implements IStorageEditorInput {
+ static class StorageEditorInput extends PlatformObject implements IStorageEditorInput {
private File fFile;
private IStorage fStorage;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java
index d8bae0c13..e7fdedc7e 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2019 IBM Corporation and others.
+ * Copyright (c) 2000, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -163,7 +163,7 @@ public class LaunchView extends AbstractDebugView
public static final String TERMINATE_AND_REMOVE = "terminate_and_remove"; //$NON-NLS-1$
- private static final String TERMINATE_ALL = "terminate_all"; //$NON-NLS-1$
+ public static final String TERMINATE_ALL = "terminate_all"; //$NON-NLS-1$
public static final String TERMINATE_AND_RELAUNCH = "terminate_relaunch"; //$NON-NLS-1$
@@ -550,7 +550,9 @@ public class LaunchView extends AbstractDebugView
addCapabilityAction(action, TERMINATE_AND_RELAUNCH);
setHandler(TERMINATE_AND_RELAUNCH, new ActionHandler(action));
addCapabilityAction(new RestartCommandAction(), RESTART);
- addCapabilityAction(new TerminateAllAction(), TERMINATE_ALL);
+ action = new TerminateAllAction();
+ addCapabilityAction(action, TERMINATE_ALL);
+ setHandler(TERMINATE_ALL, new ActionHandler(action));
addCapabilityAction(new ToggleStepFiltersAction(), TOGGLE_STEP_FILTERS);
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/AddMemoryRenderingDialog.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/AddMemoryRenderingDialog.java
index 427955ba0..f7d159b83 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/AddMemoryRenderingDialog.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/AddMemoryRenderingDialog.java
@@ -112,7 +112,7 @@ public class AddMemoryRenderingDialog extends SelectionDialog {
job.schedule();
};
- class MemoryRenderingLabelProvider implements ILabelProvider {
+ static class MemoryRenderingLabelProvider implements ILabelProvider {
@Override
public Image getImage(Object element) {
@@ -147,7 +147,7 @@ public class AddMemoryRenderingDialog extends SelectionDialog {
}
- class MemoryRenderingContentProvider implements IStructuredContentProvider {
+ static class MemoryRenderingContentProvider implements IStructuredContentProvider {
@Override
public Object[] getElements(Object inputElement) {
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryView.java
index 9f4b8a6d0..f0c7f7475 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryView.java
@@ -124,7 +124,7 @@ public class MemoryView extends ViewPart implements IMemoryRenderingSite2 {
private String fActivePaneId;
- class MemoryViewSelectionProvider implements ISelectionProvider, ISelectionChangedListener {
+ static class MemoryViewSelectionProvider implements ISelectionProvider, ISelectionChangedListener {
ArrayList<ISelectionChangedListener> fListeners = new ArrayList<>();
IStructuredSelection fSelections = new StructuredSelection();
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryViewSynchronizationService.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryViewSynchronizationService.java
index 9a5002d31..9abc831f2 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryViewSynchronizationService.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/MemoryViewSynchronizationService.java
@@ -58,7 +58,7 @@ public class MemoryViewSynchronizationService implements IMemoryRenderingSynchro
* Wrapper for ISynchronizedMemoryBlockView Holds a list of property filters
* for the view.
*/
- class PropertyListener {
+ static class PropertyListener {
IPropertyChangeListener fListener;
String[] fFilters;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CreateRendering.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CreateRendering.java
index 5c2d85ba3..a2f01aee3 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CreateRendering.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/CreateRendering.java
@@ -78,7 +78,7 @@ public class CreateRendering extends AbstractMemoryRendering implements IMemoryR
fContainer = container;
}
- class MemoryRenderingLabelProvider implements ILabelProvider
+ static class MemoryRenderingLabelProvider implements ILabelProvider
{
@Override
@@ -116,7 +116,7 @@ public class CreateRendering extends AbstractMemoryRendering implements IMemoryR
}
- class MemoryRenderingContentProvider implements IStructuredContentProvider
+ static class MemoryRenderingContentProvider implements IStructuredContentProvider
{
@Override
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/HexIntegerRendering.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/HexIntegerRendering.java
index 4e05c2207..05b589643 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/HexIntegerRendering.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/HexIntegerRendering.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2007 IBM Corporation and others.
+ * Copyright (c) 2007, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -11,6 +11,7 @@
* Contributors:
* IBM Corporation - initial API and implementation
* David Pickens - [Memory View] Endian in hex view and ASCII view doesn't work
+ * John Dallaway - Accommodate addressableSize != 1 (bug 575413)
*******************************************************************************/
package org.eclipse.debug.internal.ui.views.memory.renderings;
@@ -39,9 +40,10 @@ public class HexIntegerRendering extends AbstractIntegerRendering {
String paddedStr = DebugUIPlugin.getDefault().getPreferenceStore().getString(IDebugUIConstants.PREF_PADDED_STR);
if (endianess == RenderingsUtil.LITTLE_ENDIAN) {
+ int addressableSize = getAddressableSize();
MemoryByte[] swapped = new MemoryByte[data.length];
- for (int i = 0; i < data.length; i++){
- swapped[data.length-i-1] = data[i];
+ for (int i = 0; i < data.length; i += addressableSize) {
+ System.arraycopy(data, i, swapped, data.length - i - addressableSize, addressableSize);
}
data = swapped;
}
@@ -82,9 +84,10 @@ public class HexIntegerRendering extends AbstractIntegerRendering {
if (endianess == RenderingsUtil.LITTLE_ENDIAN) {
+ int addressableSize = getAddressableSize();
byte[] swapped = new byte[bytes.length];
- for (int i = 0; i < bytes.length; i++){
- swapped[bytes.length-i-1] = bytes[i];
+ for (int i = 0; i < bytes.length; i += addressableSize) {
+ System.arraycopy(bytes, i, swapped, bytes.length - i - addressableSize, addressableSize);
}
bytes = swapped;
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/RenderingsUtil.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/RenderingsUtil.java
index 9382579d1..e62d485db 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/RenderingsUtil.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/RenderingsUtil.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2004, 2015 IBM Corporation and others.
+ * Copyright (c) 2004, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -10,6 +10,7 @@
*
* Contributors:
* IBM Corporation - initial API and implementation
+ * John Dallaway - Accommodate addressableSize != 1 (bug 577106)
*******************************************************************************/
package org.eclipse.debug.internal.ui.views.memory.renderings;
@@ -72,7 +73,7 @@ public class RenderingsUtil {
return array;
}
- static public BigInteger convertByteArrayToUnsignedLong(byte[] array, int endianess)
+ static public BigInteger convertByteArrayToUnsignedLong(byte[] array, int endianess, int addressableSize)
{
if (array.length < 8)
{
@@ -82,14 +83,15 @@ public class RenderingsUtil {
BigInteger value = new BigInteger("0"); //$NON-NLS-1$
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int i=0; i< 8; i++)
- {
- byte[] temp = new byte[1];
- temp[0] = array[i];
- BigInteger b = new BigInteger(temp);
- b = b.and(new BigInteger("ff", 16)); //$NON-NLS-1$
- b = b.shiftLeft(i*8);
- value = value.or(b);
+ for (int i = 0; i < 8; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ byte[] temp = new byte[1];
+ temp[0] = array[i + j];
+ BigInteger b = new BigInteger(temp);
+ b = b.and(new BigInteger("ff", 16)); //$NON-NLS-1$
+ b = b.shiftLeft((i + addressableSize - j - 1) * 8);
+ value = value.or(b);
+ }
}
}
else
@@ -111,9 +113,10 @@ public class RenderingsUtil {
* Convert byte array to long.
* @param array
* @param endianess
+ * @param addressableSize
* @return result of the conversion in long
*/
- static public long convertByteArrayToLong(byte[] array, int endianess)
+ static public long convertByteArrayToLong(byte[] array, int endianess, int addressableSize)
{
if (array.length < 8)
{
@@ -123,10 +126,12 @@ public class RenderingsUtil {
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
long value = 0;
- for (int i = 0; i < 8; i++) {
- long b = array[i];
- b &= 0xff;
- value |= (b << (i * 8));
+ for (int i = 0; i < 8; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ long b = array[i + j];
+ b &= 0xff;
+ value |= (b << ((i + addressableSize - j - 1) * 8));
+ }
}
return value;
}
@@ -141,7 +146,7 @@ public class RenderingsUtil {
return value;
}
- static public BigInteger convertByteArrayToSignedBigInt(byte[] array, int endianess)
+ static public BigInteger convertByteArrayToSignedBigInt(byte[] array, int endianess, int addressableSize)
{
if (array.length < 16)
{
@@ -152,10 +157,10 @@ public class RenderingsUtil {
{
// reverse bytes
byte[] holder = new byte[16];
- int j=15;
- for (int i=0; i<16; i++, j--)
- {
- holder[i] = array[j];
+ for (int i = 0; i < 16; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ holder[i + j] = array[16 + j - i - addressableSize];
+ }
}
// create BigInteger
@@ -166,7 +171,7 @@ public class RenderingsUtil {
return value;
}
- static public BigInteger convertByteArrayToSignedBigInt(byte[] array, int endianess, int arraySize)
+ static public BigInteger convertByteArrayToSignedBigInt(byte[] array, int endianess, int arraySize, int addressableSize)
{
if (array.length < arraySize)
{
@@ -177,10 +182,10 @@ public class RenderingsUtil {
{
// reverse bytes
byte[] holder = new byte[arraySize];
- int j=arraySize-1;
- for (int i=0; i<arraySize; i++, j--)
- {
- holder[i] = array[j];
+ for (int i = 0; i < arraySize; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ holder[i + j] = array[arraySize + j - i - addressableSize];
+ }
}
// create BigInteger
@@ -191,7 +196,7 @@ public class RenderingsUtil {
return value;
}
- static public BigInteger convertByteArrayToUnsignedBigInt(byte[] array, int endianess)
+ static public BigInteger convertByteArrayToUnsignedBigInt(byte[] array, int endianess, int addressableSize)
{
if (array.length < 16)
{
@@ -201,14 +206,15 @@ public class RenderingsUtil {
BigInteger value = new BigInteger("0"); //$NON-NLS-1$
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int i=0; i< 16; i++)
- {
- byte[] temp = new byte[1];
- temp[0] = array[i];
- BigInteger b = new BigInteger(temp);
- b = b.and(new BigInteger("ff", 16)); //$NON-NLS-1$
- b = b.shiftLeft(i*8);
- value = value.or(b);
+ for (int i = 0; i < 16; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ byte[] temp = new byte[1];
+ temp[0] = array[i + j];
+ BigInteger b = new BigInteger(temp);
+ b = b.and(new BigInteger("ff", 16)); //$NON-NLS-1$
+ b = b.shiftLeft((i + addressableSize - j - 1) * 8);
+ value = value.or(b);
+ }
}
}
else
@@ -226,7 +232,7 @@ public class RenderingsUtil {
return value;
}
- static public BigInteger convertByteArrayToUnsignedBigInt(byte[] array, int endianess, int arraySize)
+ static public BigInteger convertByteArrayToUnsignedBigInt(byte[] array, int endianess, int arraySize, int addressableSize)
{
if (array.length < arraySize)
{
@@ -236,14 +242,15 @@ public class RenderingsUtil {
BigInteger value = new BigInteger("0"); //$NON-NLS-1$
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int i=0; i< arraySize; i++)
- {
- byte[] temp = new byte[1];
- temp[0] = array[i];
- BigInteger b = new BigInteger(temp);
- b = b.and(new BigInteger("ff", 16)); //$NON-NLS-1$
- b = b.shiftLeft(i*8);
- value = value.or(b);
+ for (int i = 0; i < arraySize; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ byte[] temp = new byte[1];
+ temp[0] = array[i + j];
+ BigInteger b = new BigInteger(temp);
+ b = b.and(new BigInteger("ff", 16)); //$NON-NLS-1$
+ b = b.shiftLeft((i + addressableSize - j - 1) * 8);
+ value = value.or(b);
+ }
}
}
else
@@ -265,9 +272,10 @@ public class RenderingsUtil {
* Convert byte array to integer.
* @param array
* @param endianess
+ * @param addressableSize
* @return result of the conversion in int
*/
- static public int convertByteArrayToInt(byte[] array, int endianess)
+ static public int convertByteArrayToInt(byte[] array, int endianess, int addressableSize)
{
if (array.length < 4)
{
@@ -277,10 +285,12 @@ public class RenderingsUtil {
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
int value = 0;
- for (int i = 0; i < 4; i++) {
- int b = array[i];
- b &= 0xff;
- value |= (b << (i * 8));
+ for (int i = 0; i < 4; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ int b = array[i + j];
+ b &= 0xff;
+ value |= (b << ((i + addressableSize - j - 1) * 8));
+ }
}
return value;
}
@@ -299,9 +309,10 @@ public class RenderingsUtil {
* Convert byte array to short.
* @param array
* @param endianess
+ * @param addressableSize
* @return result of teh conversion in short
*/
- static public short convertByteArrayToShort(byte[] array, int endianess)
+ static public short convertByteArrayToShort(byte[] array, int endianess, int addressableSize)
{
if (array.length < 2)
{
@@ -311,10 +322,12 @@ public class RenderingsUtil {
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
short value = 0;
- for (int i = 0; i < 2; i++) {
- short b = array[i];
- b &= 0xff;
- value |= (b << (i * 8));
+ for (int i = 0; i < 2; i += addressableSize) {
+ for (int j = 0; j < addressableSize; j++) {
+ short b = array[i + j];
+ b &= 0xff;
+ value |= (b << ((i + addressableSize - j - 1) * 8));
+ }
}
return value;
}
@@ -332,18 +345,20 @@ public class RenderingsUtil {
* Convert big integer to byte array.
* @param i
* @param endianess
+ * @param addressableSize
* @return result of the conversion in raw byte array
*/
- static public byte[] convertBigIntegerToByteArray(BigInteger i, int endianess)
+ static public byte[] convertBigIntegerToByteArray(BigInteger i, int endianess, int addressableSize)
{
byte buf[]=new byte[16];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int j=0; j<16; j++)
- {
- BigInteger x = i.shiftRight(j*8);
- buf[j] = x.byteValue();
+ for (int j = 0; j < 16; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ BigInteger x = i.shiftRight((j + addressableSize - k - 1) * 8);
+ buf[j + k] = x.byteValue();
+ }
}
return buf;
}
@@ -355,16 +370,17 @@ public class RenderingsUtil {
return buf;
}
- static public byte[] convertSignedBigIntToByteArray(BigInteger i, int endianess, int arraySize)
+ static public byte[] convertSignedBigIntToByteArray(BigInteger i, int endianess, int arraySize, int addressableSize)
{
byte buf[]=new byte[arraySize];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int j=0; j<arraySize; j++)
- {
- BigInteger x = i.shiftRight(j*8);
- buf[j] = x.byteValue();
+ for (int j = 0; j < arraySize; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ BigInteger x = i.shiftRight((j + addressableSize - k - 1) * 8);
+ buf[j + k] = x.byteValue();
+ }
}
return buf;
}
@@ -380,18 +396,20 @@ public class RenderingsUtil {
* Convert big integer to byte array.
* @param i
* @param endianess
+ * @param addressableSize
* @return result of the conversion in raw byte array
*/
- static public byte[] convertUnsignedBigIntegerToByteArray(BigInteger i, int endianess)
+ static public byte[] convertUnsignedBigIntegerToByteArray(BigInteger i, int endianess, int addressableSize)
{
byte buf[]=new byte[32];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int j=0; j<32; j++)
- {
- BigInteger x = i.shiftRight(j*8);
- buf[j] = x.byteValue();
+ for (int j = 0; j < 32; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ BigInteger x = i.shiftRight((j + addressableSize - k - 1) * 8);
+ buf[j + k] = x.byteValue();
+ }
}
return buf;
}
@@ -403,16 +421,17 @@ public class RenderingsUtil {
return buf;
}
- static public byte[] convertUnsignedBigIntToByteArray(BigInteger i, int endianess, int arraySize)
+ static public byte[] convertUnsignedBigIntToByteArray(BigInteger i, int endianess, int arraySize, int addressableSize)
{
byte buf[]=new byte[arraySize*2];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int j=0; j<arraySize*2; j++)
- {
- BigInteger x = i.shiftRight(j*8);
- buf[j] = x.byteValue();
+ for (int j = 0; j < arraySize * 2; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ BigInteger x = i.shiftRight((j + addressableSize - k - 1) * 8);
+ buf[j + k] = x.byteValue();
+ }
}
return buf;
}
@@ -428,17 +447,19 @@ public class RenderingsUtil {
* Convert long to byte array.
* @param i
* @param endianess
+ * @param addressableSize
* @return result of the conversion in raw byte array
*/
- static public byte[] convertLongToByteArray(long i, int endianess)
+ static public byte[] convertLongToByteArray(long i, int endianess, int addressableSize)
{
byte buf[]=new byte[8];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int j=0; j<8; j++)
- {
- buf[j] = Long.valueOf(i>>j*8).byteValue();
+ for (int j = 0; j < 8; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ buf[j + k] = Long.valueOf(i >> (j + addressableSize - k - 1) * 8).byteValue();
+ }
}
return buf;
}
@@ -453,17 +474,19 @@ public class RenderingsUtil {
* Convert integer to byte array.
* @param i
* @param endianess
+ * @param addressableSize
* @return result of the conversion in raw byte array
*/
- static public byte[] convertIntToByteArray(int i, int endianess)
+ static public byte[] convertIntToByteArray(int i, int endianess, int addressableSize)
{
byte buf[]=new byte[4];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (int j=0; j<4; j++)
- {
- buf[j] = Integer.valueOf(i>>j*8).byteValue();
+ for (int j = 0; j < 4; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ buf[j + k] = Integer.valueOf(i >> (j + addressableSize - k - 1) * 8).byteValue();
+ }
}
return buf;
}
@@ -478,17 +501,19 @@ public class RenderingsUtil {
* Convert short to byte array.
* @param i
* @param endianess
+ * @param addressableSize
* @return result of the conversion in raw byte array
*/
- static public byte[] convertShortToByteArray(short i, int endianess)
+ static public byte[] convertShortToByteArray(short i, int endianess, int addressableSize)
{
byte buf[]=new byte[2];
if (endianess == RenderingsUtil.LITTLE_ENDIAN)
{
- for (short j=0; j<2; j++)
- {
- buf[j] = Integer.valueOf(i>>j*8).byteValue();
+ for (short j = 0; j < 2; j += addressableSize) {
+ for (int k = 0; k < addressableSize; k++) {
+ buf[j + k] = Integer.valueOf(i >> (j + addressableSize - k - 1) * 8).byteValue();
+ }
}
return buf;
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/SignedIntegerRendering.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/SignedIntegerRendering.java
index ac774e814..30b683183 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/SignedIntegerRendering.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/SignedIntegerRendering.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2004, 2005 IBM Corporation and others.
+ * Copyright (c) 2004, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -10,6 +10,7 @@
*
* Contributors:
* IBM Corporation - initial API and implementation
+ * John Dallaway - Accommodate addressableSize != 1 (bug 577106)
*******************************************************************************/
package org.eclipse.debug.internal.ui.views.memory.renderings;
@@ -47,22 +48,22 @@ public class SignedIntegerRendering extends AbstractIntegerRendering {
result = byteArray[0];
break;
case 2:
- result = RenderingsUtil.convertByteArrayToShort(byteArray, endianess);
+ result = RenderingsUtil.convertByteArrayToShort(byteArray, endianess, getAddressableSize());
break;
case 4:
- result = RenderingsUtil.convertByteArrayToInt(byteArray, endianess);
+ result = RenderingsUtil.convertByteArrayToInt(byteArray, endianess, getAddressableSize());
break;
case 8:
- result = RenderingsUtil.convertByteArrayToLong(byteArray, endianess);
+ result = RenderingsUtil.convertByteArrayToLong(byteArray, endianess, getAddressableSize());
break;
case 16:
{
- BigInteger bigRet = RenderingsUtil.convertByteArrayToSignedBigInt(byteArray, endianess);
+ BigInteger bigRet = RenderingsUtil.convertByteArrayToSignedBigInt(byteArray, endianess, getAddressableSize());
return bigRet.toString();
}
default:
{
- BigInteger bigRet = RenderingsUtil.convertByteArrayToSignedBigInt(byteArray, endianess, columnSize);
+ BigInteger bigRet = RenderingsUtil.convertByteArrayToSignedBigInt(byteArray, endianess, columnSize, getAddressableSize());
return bigRet.toString();
}
}
@@ -85,19 +86,19 @@ public class SignedIntegerRendering extends AbstractIntegerRendering {
case 2:
{
short i = Short.parseShort(newValue);
- bytes = RenderingsUtil.convertShortToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertShortToByteArray(i, endianess, getAddressableSize());
break;
}
case 4:
{
int i = Integer.parseInt(newValue);
- bytes = RenderingsUtil.convertIntToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertIntToByteArray(i, endianess, getAddressableSize());
break;
}
case 8:
{
long i = Long.parseLong(newValue);
- bytes = RenderingsUtil.convertLongToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertLongToByteArray(i, endianess, getAddressableSize());
break;
}
case 16:
@@ -105,7 +106,7 @@ public class SignedIntegerRendering extends AbstractIntegerRendering {
// special case for colSize == 16
// need to represent number in Big Integer
BigInteger i = new BigInteger(newValue);
- bytes = RenderingsUtil.convertBigIntegerToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertBigIntegerToByteArray(i, endianess, getAddressableSize());
return bytes;
}
@@ -128,7 +129,7 @@ public class SignedIntegerRendering extends AbstractIntegerRendering {
throw new NumberFormatException();
}
- bytes = RenderingsUtil.convertSignedBigIntToByteArray(i, endianess, colSize);
+ bytes = RenderingsUtil.convertSignedBigIntToByteArray(i, endianess, colSize, getAddressableSize());
return bytes;
}
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/UnsignedIntegerRendering.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/UnsignedIntegerRendering.java
index 572bbf293..b6f9ce73f 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/UnsignedIntegerRendering.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/memory/renderings/UnsignedIntegerRendering.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2004, 2005 IBM Corporation and others.
+ * Copyright (c) 2004, 2021 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -10,6 +10,7 @@
*
* Contributors:
* IBM Corporation - initial API and implementation
+ * John Dallaway - Accommodate addressableSize != 1 (bug 577106)
*******************************************************************************/
package org.eclipse.debug.internal.ui.views.memory.renderings;
@@ -43,22 +44,22 @@ public class UnsignedIntegerRendering extends AbstractIntegerRendering {
result &= 0xff;
break;
case 2:
- result = RenderingsUtil.convertByteArrayToInt(byteArray, endianess);
+ result = RenderingsUtil.convertByteArrayToInt(byteArray, endianess, getAddressableSize());
break;
case 4:
- result = RenderingsUtil.convertByteArrayToLong(byteArray, endianess);
+ result = RenderingsUtil.convertByteArrayToLong(byteArray, endianess, getAddressableSize());
break;
case 8:
- BigInteger value = RenderingsUtil.convertByteArrayToUnsignedLong(byteArray, endianess);
+ BigInteger value = RenderingsUtil.convertByteArrayToUnsignedLong(byteArray, endianess, getAddressableSize());
return value.toString();
case 16:
{
- BigInteger bigRet = RenderingsUtil.convertByteArrayToUnsignedBigInt(byteArray, endianess);
+ BigInteger bigRet = RenderingsUtil.convertByteArrayToUnsignedBigInt(byteArray, endianess, getAddressableSize());
return bigRet.toString();
}
default:
{
- BigInteger bigRet = RenderingsUtil.convertByteArrayToUnsignedBigInt(byteArray, endianess, columnSize);
+ BigInteger bigRet = RenderingsUtil.convertByteArrayToUnsignedBigInt(byteArray, endianess, columnSize, getAddressableSize());
return bigRet.toString();
}
}
@@ -76,7 +77,7 @@ public class UnsignedIntegerRendering extends AbstractIntegerRendering {
case 1:
{
short i = Short.parseShort(newValue);
- bytes = RenderingsUtil.convertShortToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertShortToByteArray(i, endianess, getAddressableSize());
bytes = extractBytes(bytes, endianess, colSize);
break;
}
@@ -84,28 +85,28 @@ public class UnsignedIntegerRendering extends AbstractIntegerRendering {
case 2:
{
int i = Integer.parseInt(newValue);
- bytes = RenderingsUtil.convertIntToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertIntToByteArray(i, endianess, getAddressableSize());
bytes = extractBytes(bytes, endianess, colSize);
break;
}
case 4:
{
long i = Long.parseLong(newValue);
- bytes = RenderingsUtil.convertLongToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertLongToByteArray(i, endianess, getAddressableSize());
bytes = extractBytes(bytes, endianess, colSize);
break;
}
case 8:
{
BigInteger i = new BigInteger(newValue);
- bytes = RenderingsUtil.convertBigIntegerToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertBigIntegerToByteArray(i, endianess, getAddressableSize());
bytes = extractBytes(bytes, endianess, colSize);
break;
}
case 16:
{
BigInteger i = new BigInteger(newValue);
- bytes = RenderingsUtil.convertUnsignedBigIntegerToByteArray(i, endianess);
+ bytes = RenderingsUtil.convertUnsignedBigIntegerToByteArray(i, endianess, getAddressableSize());
bytes = extractBytes(bytes, endianess, colSize);
return bytes;
@@ -113,7 +114,7 @@ public class UnsignedIntegerRendering extends AbstractIntegerRendering {
default:
{
BigInteger i = new BigInteger(newValue);
- bytes = RenderingsUtil.convertUnsignedBigIntToByteArray(i, endianess, colSize);
+ bytes = RenderingsUtil.convertUnsignedBigIntToByteArray(i, endianess, colSize, getAddressableSize());
bytes = extractBytes(bytes, endianess, colSize);
return bytes;
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java
index 8e59e6aa6..7e89642b8 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/VariablesView.java
@@ -340,7 +340,7 @@ public class VariablesView extends AbstractDebugView implements IDebugContextLis
/**
* Visits deltas to determine if details should be displayed
*/
- class Visitor implements IModelDeltaVisitor {
+ static class Visitor implements IModelDeltaVisitor {
/**
* Whether to trigger details display.
*
@@ -1086,7 +1086,13 @@ public class VariablesView extends AbstractDebugView implements IDebugContextLis
protected void fillContextMenu(IMenuManager menu) {
menu.add(new Separator(IDebugUIConstants.EMPTY_VARIABLE_GROUP));
menu.add(new Separator(IDebugUIConstants.VARIABLE_GROUP));
- menu.add(getAction(FIND_ACTION));
+ IAction findAction = getAction(FIND_ACTION);
+ if (findAction != null) {
+ menu.add(findAction);
+ } else {
+ DebugUIPlugin.log(new IllegalStateException("No action found for id: " + FIND_ACTION //$NON-NLS-1$
+ + ", fGlobalActionMap: " + fGlobalActionMap)); //$NON-NLS-1$
+ }
ChangeVariableValueAction changeValueAction = (ChangeVariableValueAction)getAction("ChangeVariableValue"); //$NON-NLS-1$
if (changeValueAction.isApplicable()) {
menu.add(changeValueAction);
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/details/DetailPaneManager.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/details/DetailPaneManager.java
index 9eea45848..10cb57b4c 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/details/DetailPaneManager.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/variables/details/DetailPaneManager.java
@@ -61,7 +61,7 @@ public class DetailPaneManager {
* to the extension point. Only loads information from the plug-in xml and only
* instantiates the specified factory if required (lazy loading).
*/
- private class DetailPaneFactoryExtension implements IDetailPaneFactory{
+ private static class DetailPaneFactoryExtension implements IDetailPaneFactory{
private IConfigurationElement fConfigElement;
private IDetailPaneFactory fFactory;
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugUIConstants.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugUIConstants.java
index e30a6fc11..208e033e8 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugUIConstants.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/IDebugUIConstants.java
@@ -1280,6 +1280,13 @@ public interface IDebugUIConstants {
String PREF_DETAIL_PANE_FONT= "org.eclipse.debug.ui.DetailPaneFont"; //$NON-NLS-1$
/**
+ * Preference to enable variable view inline on text editors.
+ *
+ * @since 3.16
+ */
+ String PREF_SHOW_VARIABLES_INLINE = "org.eclipse.debug.ui.ShowVariableInline"; //$NON-NLS-1$
+
+ /**
* Instruction pointer image for editor ruler for the currently executing
* instruction in the top stack frame.
*
@@ -1347,4 +1354,5 @@ public interface IDebugUIConstants {
* @since 3.8
*/
String COLUMN_ID_VARIABLE_VALUE_TYPE = COLUMN_PRESENTATION_ID_VARIABLE + ".COL_VALUE_TYPE"; //$NON-NLS-1$
+
}
diff --git a/org.eclipse.ui.console/.classpath b/org.eclipse.ui.console/.classpath
index eca7bdba8..e801ebfb4 100644
--- a/org.eclipse.ui.console/.classpath
+++ b/org.eclipse.ui.console/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/org.eclipse.ui.console/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.ui.console/.settings/org.eclipse.jdt.core.prefs
index 568f4d675..74839bc3c 100644
--- a/org.eclipse.ui.console/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.ui.console/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,13 +135,14 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.release=disabled
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
@@ -147,20 +150,23 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=16
org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=16
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_for_loop_header=0
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=16
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_module_statements=16
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16
org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=16
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
@@ -252,11 +258,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -287,6 +294,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -311,13 +320,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -365,6 +378,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do no
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -401,9 +416,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -439,10 +457,14 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
org.eclipse.jdt.core.formatter.wrap_before_assignment_operator=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
org.eclipse.jdt.core.formatter.wrap_before_conditional_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.ui.console/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.ui.console/.settings/org.eclipse.jdt.ui.prefs
index aba901028..77568d8af 100644
--- a/org.eclipse.ui.console/.settings/org.eclipse.jdt.ui.prefs
+++ b/org.eclipse.ui.console/.settings/org.eclipse.jdt.ui.prefs
@@ -1,55 +1,3 @@
-cleanup.add_default_serial_version_id=true
-cleanup.add_generated_serial_version_id=false
-cleanup.add_missing_annotations=true
-cleanup.add_missing_deprecated_annotations=true
-cleanup.add_missing_methods=false
-cleanup.add_missing_nls_tags=false
-cleanup.add_missing_override_annotations=true
-cleanup.add_missing_override_annotations_interface_methods=true
-cleanup.add_serial_version_id=false
-cleanup.always_use_blocks=true
-cleanup.always_use_parentheses_in_expressions=false
-cleanup.always_use_this_for_non_static_field_access=false
-cleanup.always_use_this_for_non_static_method_access=false
-cleanup.convert_to_enhanced_for_loop=false
-cleanup.correct_indentation=false
-cleanup.format_source_code=true
-cleanup.format_source_code_changes_only=false
-cleanup.make_local_variable_final=true
-cleanup.make_parameters_final=false
-cleanup.make_private_fields_final=true
-cleanup.make_type_abstract_if_missing_method=false
-cleanup.make_variable_declarations_final=false
-cleanup.never_use_blocks=false
-cleanup.never_use_parentheses_in_expressions=true
-cleanup.organize_imports=true
-cleanup.qualify_static_field_accesses_with_declaring_class=false
-cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-cleanup.qualify_static_member_accesses_with_declaring_class=true
-cleanup.qualify_static_method_accesses_with_declaring_class=false
-cleanup.remove_private_constructors=true
-cleanup.remove_trailing_whitespaces=true
-cleanup.remove_trailing_whitespaces_all=true
-cleanup.remove_trailing_whitespaces_ignore_empty=false
-cleanup.remove_unnecessary_casts=true
-cleanup.remove_unnecessary_nls_tags=true
-cleanup.remove_unused_imports=true
-cleanup.remove_unused_local_variables=false
-cleanup.remove_unused_private_fields=true
-cleanup.remove_unused_private_members=false
-cleanup.remove_unused_private_methods=true
-cleanup.remove_unused_private_types=true
-cleanup.sort_members=false
-cleanup.sort_members_all=false
-cleanup.use_blocks=true
-cleanup.use_blocks_only_for_return_and_throw=false
-cleanup.use_parentheses_in_expressions=false
-cleanup.use_this_for_non_static_field_access=false
-cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-cleanup.use_this_for_non_static_method_access=false
-cleanup.use_this_for_non_static_method_access_only_if_necessary=true
-cleanup_profile=_Platform Debug Cleanups
cleanup_settings_version=2
eclipse.preferences.version=1
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
diff --git a/org.eclipse.ui.console/META-INF/MANIFEST.MF b/org.eclipse.ui.console/META-INF/MANIFEST.MF
index cdf0ffb2f..d3fbb40d2 100644
--- a/org.eclipse.ui.console/META-INF/MANIFEST.MF
+++ b/org.eclipse.ui.console/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.ui.console; singleton:=true
-Bundle-Version: 3.10.100.qualifier
+Bundle-Version: 3.11.200.qualifier
Bundle-Activator: org.eclipse.ui.console.ConsolePlugin
Bundle-Vendor: %providerName
Bundle-Localization: plugin
@@ -17,5 +17,5 @@ Require-Bundle: org.eclipse.ui;bundle-version="[3.5.0,4.0.0)",
org.eclipse.core.variables;bundle-version="[3.2.800,4.0.0)",
org.eclipse.debug.core;bundle-version="[3.16.0,4.0.0)"
Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Automatic-Module-Name: org.eclipse.ui.console
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleInputStream.java b/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleInputStream.java
index 56464eba5..1b94147f3 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleInputStream.java
+++ b/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleInputStream.java
@@ -56,7 +56,7 @@ public class IOConsoleInputStream extends InputStream {
/**
* Flag to indicate that the stream has been closed.
*/
- private boolean closed = false;
+ private volatile boolean closed;
/**
* The console that this stream is connected to.
@@ -251,13 +251,19 @@ public class IOConsoleInputStream extends InputStream {
}
@Override
- public synchronized void close() throws IOException {
+ public void close() throws IOException {
if(closed) {
// Closeable#close() has no effect if already closed
return;
}
- closed = true;
- notifyAll();
+ synchronized (this) {
+ if (closed) {
+ return;
+ }
+ closed = true;
+ notifyAll();
+ }
+ // Locked in the console
console.streamClosed(this);
}
}
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleOutputStream.java b/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleOutputStream.java
index bbe638bb5..38cd40b7c 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleOutputStream.java
+++ b/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleOutputStream.java
@@ -43,7 +43,7 @@ public class IOConsoleOutputStream extends OutputStream {
/**
* Flag indicating whether this stream has been closed.
*/
- private boolean closed = false;
+ private volatile boolean closed;
/**
* The console's document partitioner.
@@ -53,26 +53,28 @@ public class IOConsoleOutputStream extends OutputStream {
/**
* The console this stream is attached to.
*/
- private IOConsole console;
+ private final IOConsole console;
/**
* Flag indicating that the console should be activated when data
* is written to this stream.
*/
- private boolean activateOnWrite = false;
+ private volatile boolean activateOnWrite;
/**
* The color used to decorate data written to this stream.
*/
- private Color color;
+ private volatile Color color;
/**
* The font style used to decorate data written to this stream.
*/
- private int fontStyle;
+ private volatile int fontStyle;
+ /** synchronized access for atomic update **/
private StreamDecoder decoder;
+ /** synchronized access for atomic update **/
private boolean prependCR;
/**
@@ -159,7 +161,7 @@ public class IOConsoleOutputStream extends OutputStream {
* Returns true if the stream has been closed
* @return true is the stream has been closed, false otherwise.
*/
- public synchronized boolean isClosed() {
+ public boolean isClosed() {
return closed;
}
@@ -169,14 +171,13 @@ public class IOConsoleOutputStream extends OutputStream {
// Closeable#close() has no effect if already closed
return;
}
- StringBuilder builder = new StringBuilder();
if (prependCR) { // force writing of last /r
prependCR = false;
- builder.append('\r');
+ notifyParitioner("\r"); //$NON-NLS-1$
}
- this.decoder.finish(builder);
- if (builder.length() > 0) {
- notifyParitioner(builder.toString());
+ String s = this.decoder.finish();
+ if (s.length() > 0) {
+ notifyParitioner(s);
}
console.streamClosed(this);
closed = true;
@@ -196,9 +197,8 @@ public class IOConsoleOutputStream extends OutputStream {
if (closed) {
throw new IOException("Output Stream is closed"); //$NON-NLS-1$
}
- StringBuilder builder = new StringBuilder();
- this.decoder.decode(builder, b, off, len);
- encodedWrite(builder.toString());
+ String s = this.decoder.decode(b, off, len);
+ encodedWrite(s);
}
@Override
@@ -271,7 +271,7 @@ public class IOConsoleOutputStream extends OutputStream {
}
if (newencoding.endsWith("\r")) { //$NON-NLS-1$
prependCR = true;
- newencoding = new String(newencoding.substring(0, newencoding.length() - 1));
+ newencoding = newencoding.substring(0, newencoding.length() - 1);
}
notifyParitioner(newencoding);
}
@@ -323,10 +323,9 @@ public class IOConsoleOutputStream extends OutputStream {
if (closed) {
throw new IOException("Output Stream is closed"); //$NON-NLS-1$
}
- StringBuilder builder = new StringBuilder();
- this.decoder.finish(builder);
- if (builder.length() > 0) {
- this.encodedWrite(builder.toString());
+ String s = this.decoder.finish();
+ if (s.length() > 0) {
+ this.encodedWrite(s);
}
this.decoder = new StreamDecoder(charset);
}
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleDocument.java b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleDocument.java
index 2d6aef421..f5c44276d 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleDocument.java
+++ b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleDocument.java
@@ -99,4 +99,10 @@ public class ConsoleDocument extends Document {
public synchronized Position[] getPositions(String category) throws BadPositionCategoryException {
return super.getPositions(category);
}
+
+ /** for debug only **/
+ @Override
+ public synchronized String toString() {
+ return get();
+ }
}
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsolePatternMatcher.java b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsolePatternMatcher.java
index 97dbab694..c82ec6b6e 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsolePatternMatcher.java
+++ b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsolePatternMatcher.java
@@ -179,7 +179,7 @@ public class ConsolePatternMatcher implements IDocumentListener {
}
- private class CompiledPatternMatchListener {
+ private static class CompiledPatternMatchListener {
Pattern pattern;
Pattern qualifier;
@@ -276,12 +276,10 @@ public class ConsolePatternMatcher implements IDocumentListener {
for (CompiledPatternMatchListener notifier : fPatterns) {
notifier.end = 0;
}
- } else {
- if (event.fOffset == 0) {
- //document was trimmed
- for (CompiledPatternMatchListener notifier : fPatterns) {
- notifier.end = notifier.end > event.fLength ? notifier.end - event.fLength : 0;
- }
+ } else if (event.fOffset == 0) {
+ //document was trimmed
+ for (CompiledPatternMatchListener notifier : fPatterns) {
+ notifier.end = notifier.end > event.fLength ? notifier.end - event.fLength : 0;
}
}
}
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
index 0e448a6c1..3158162b6 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
+++ b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
@@ -28,6 +28,9 @@ import java.util.Comparator;
import java.util.Iterator;
import java.util.List;
import java.util.Objects;
+import java.util.concurrent.BlockingQueue;
+import java.util.concurrent.LinkedBlockingQueue;
+import java.util.concurrent.TimeUnit;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
@@ -113,10 +116,19 @@ public class IOConsolePartitioner
* elements. (see also {@link #checkPartitions()})
*/
private final ArrayList<IOConsolePartition> partitions = new ArrayList<>();
- /** Blocks of data that have not yet been appended to the document. */
- private final ArrayList<PendingPartition> pendingPartitions = new ArrayList<>();
- /** Total length of pending partitions content. */
- private int pendingSize;
+ /**
+ * max ~ 16MB when debugged application outputs faster then we can handle. Seems
+ * to be a could compromise between memory and speed we can handle. Eclipse IDE
+ * may use that memory size ~3 times during processing (buffer+document+parser)
+ */
+ private static final int MAX_BUFFER_BYTES = 16_000_000;
+ /**
+ * Queue of buffers that have not yet been appended to the document. Every
+ * buffer will hold up to 8192 byte - but typically a single line output if
+ * handled fast. The debugged application will block if the limit is exceeded.
+ */
+ private final BlockingQueue<PendingPartition> pendingPartitions = new LinkedBlockingQueue<>(
+ MAX_BUFFER_BYTES / 8192);
/** Job that appends pending partitions to the document. */
private final QueueProcessingJob queueJob = new QueueProcessingJob();
/** Job that trims console content if it exceeds {@link #highWaterMark}. */
@@ -130,7 +142,6 @@ public class IOConsolePartitioner
* </p>
*/
private DocUpdateType updateType = DocUpdateType.INPUT;
- private IRegion changedRegion;
/**
* A list of partitions containing input from the console, that have not been
* appended to the input stream yet. No guarantees on element order.
@@ -214,11 +225,7 @@ public class IOConsolePartitioner
@Override
public void disconnect() {
- synchronized (pendingPartitions) {
- pendingPartitions.clear();
- pendingSize = 0;
- pendingPartitions.notifyAll();
- }
+ pendingPartitions.clear();
synchronized (partitions) {
trimJob.cancel();
queueJob.cancel();
@@ -283,10 +290,7 @@ public class IOConsolePartitioner
if (streamsClosed) {
// do not expect new data since all streams are closed
// check if pending data is queued
- final boolean morePending;
- synchronized (pendingPartitions) {
- morePending = !pendingPartitions.isEmpty();
- }
+ final boolean morePending = !pendingPartitions.isEmpty();
if (morePending) {
queueJob.schedule();
} else {
@@ -430,10 +434,8 @@ public class IOConsolePartitioner
if (document != null && highWaterMark > 0) {
int length = document.getLength();
if (length > highWaterMark) {
- if (trimJob.getState() == Job.NONE) { // if the job isn't already running
- trimJob.setTrimLineOffset(length - lowWaterMark);
- trimJob.schedule();
- }
+ // do trim synchronous to prevent drawing trimmed text - we are already in UI and have the lock
+ trim(length - lowWaterMark, true);
}
}
}
@@ -442,10 +444,7 @@ public class IOConsolePartitioner
* Clears the console content.
*/
public void clearBuffer() {
- synchronized (pendingPartitions) {
- pendingPartitions.clear();
- pendingSize = 0;
- }
+ pendingPartitions.clear();
synchronized (partitions) {
if (document != null) {
trimJob.setTrimOffset(document.getLength());
@@ -484,7 +483,7 @@ public class IOConsolePartitioner
// update and trim jobs are triggered by this partitioner and all partitioning
// changes are applied separately
case OUTPUT:
- return changedRegion;
+ return null; // changedRegion was never assigned
case TRIM:
return null; // trim does not change partition types
@@ -692,37 +691,27 @@ public class IOConsolePartitioner
if (s == null) {
return;
}
- synchronized (pendingPartitions) {
- final PendingPartition lastPending = pendingPartitions.size() > 0
- ? pendingPartitions.get(pendingPartitions.size() - 1)
- : null;
- if (lastPending != null && lastPending.stream == stream) {
- lastPending.append(s);
- } else {
- pendingPartitions.add(new PendingPartition(stream, s));
- }
+ PendingPartition partition = new PendingPartition(stream, s);
+ while (!offer(partition)) {
+ helpProgress();
+ }
+ queueJob.schedule();
+ }
- if (pendingSize > 1000) {
- queueJob.schedule();
- } else {
- queueJob.schedule(50);
- }
+ private void helpProgress() {
+ if (Display.getCurrent() != null) {
+ // make sure pendingPartitions can take
+ queueJob.processPendingPartitions();
+ } else {
+ Thread.yield(); // give UI thread chance to proceed
+ }
+ }
- if (pendingSize > 160000) {
- if (Display.getCurrent() == null) {
- try {
- // Block thread to give UI time to process pending output.
- // Do not wait forever. Current thread and UI thread might share locks. An
- // example is bug 421303 where current thread and UI thread both write to
- // console and therefore both need the write lock for IOConsoleOutputStream.
- pendingPartitions.wait(1000);
- } catch (InterruptedException e) {
- }
- } else {
- // If we are in UI thread we cannot lock it, so process queued output.
- queueJob.processPendingPartitions();
- }
- }
+ private boolean offer(PendingPartition p) {
+ try {
+ return pendingPartitions.offer(p, 10, TimeUnit.MILLISECONDS);
+ } catch (InterruptedException e) {
+ return false;
}
}
@@ -730,17 +719,17 @@ public class IOConsolePartitioner
* Holds data until updateJob can be run and the document can be updated.
*/
private class PendingPartition {
- StringBuilder text = new StringBuilder(8192);
- IOConsoleOutputStream stream;
+ private final CharSequence text;
+ private final IOConsoleOutputStream stream;
- PendingPartition(IOConsoleOutputStream stream, String text) {
+ PendingPartition(IOConsoleOutputStream stream, CharSequence text) {
this.stream = stream;
- append(text);
+ this.text = text;
}
- void append(String moreText) {
- text.append(moreText);
- pendingSize += moreText.length();
+ @Override
+ public String toString() {
+ return text.toString();
}
}
@@ -755,8 +744,6 @@ public class IOConsolePartitioner
private int atOutputPartitionIndex = -1;
/** The pending number of characters to replace in document. */
private int replaceLength;
- /** The pending content to be inserted in document. */
- private StringBuilder content;
/** The offset in document where to apply the next replace. */
private int nextWriteOffset;
@@ -784,10 +771,7 @@ public class IOConsolePartitioner
*/
@Override
public boolean shouldRun() {
- synchronized (pendingPartitions) {
- final boolean shouldRun = pendingPartitions.size() > 0;
- return shouldRun;
- }
+ return !pendingPartitions.isEmpty();
}
/**
@@ -795,22 +779,29 @@ public class IOConsolePartitioner
* update partitioning.
*/
private void processPendingPartitions() {
- final List<PendingPartition> pendingCopy;
- final int size;
- synchronized (pendingPartitions) {
- pendingCopy = new ArrayList<>(pendingPartitions);
- size = pendingSize;
- pendingPartitions.clear();
- pendingSize = 0;
- pendingPartitions.notifyAll();
+ final List<PendingPartition> pendingCopy = new ArrayList<>();
+ // draining the whole buffer here is important - this way we get as much data as
+ // available and may skip to draw text that exceeds the Console buffer size
+ // anyway (see checkBufferSize()).
+ pendingPartitions.drainTo(pendingCopy);
+ int sizeHint = 0;
+ if (pendingCopy.isEmpty()) {
+ return;
+ }
+ IOConsoleOutputStream stream = pendingCopy.get(0).stream;
+ for (PendingPartition p : pendingCopy) {
+ if (p.stream != stream) {
+ break;
+ }
+ sizeHint += p.text.length();
}
synchronized (partitions) {
if (document != null) {
- applyStreamOutput(pendingCopy, size);
+ applyStreamOutput(pendingCopy, sizeHint);
}
+ checkFinished();
+ checkBufferSize(); // needs partitions synchronized
}
- checkFinished();
- checkBufferSize();
}
/**
@@ -835,17 +826,19 @@ public class IOConsolePartitioner
// resulting in multiple partitions but if all the content is appended to the
// document there is only one update required to add the actual content.
nextWriteOffset = outputOffset;
- content = new StringBuilder(sizeHint);
+ StringBuilder content = new StringBuilder(sizeHint);
replaceLength = 0;
atOutputPartition = null;
atOutputPartitionIndex = -1;
for (PendingPartition pending : pendingCopy) {
// create matcher to find control characters in pending content (if enabled)
- final Matcher controlCharacterMatcher = controlPattern != null ? controlPattern.matcher(pending.text)
+ CharSequence text = pending.text;
+ IOConsoleOutputStream stream = pending.stream;
+ final Matcher controlCharacterMatcher = controlPattern != null ? controlPattern.matcher(text)
: null;
- for (int textOffset = 0; textOffset < pending.text.length();) {
+ for (int textOffset = 0; textOffset < text.length();) {
// Process pending content in chunks.
// Processing is primary split on control characters since there interpretation
// is easier if all content changes before are already applied.
@@ -866,11 +859,11 @@ public class IOConsolePartitioner
partEnd = controlCharacterMatcher.start();
foundControlCharacter = true;
} else {
- partEnd = pending.text.length();
+ partEnd = text.length();
foundControlCharacter = false;
}
- partititonContent(pending.stream, pending.text, textOffset, partEnd);
+ partititonContent(stream, text, textOffset, partEnd, content);
textOffset = partEnd;
// finished processing of regular content before control characters
@@ -891,7 +884,7 @@ public class IOConsolePartitioner
// move virtual output cursor one step back for each \b
// but stop at current line start and skip any input partitions
int backStepCount = controlCharacterMatch.length();
- if (partitions.size() == 0) {
+ if (partitions.isEmpty()) {
outputOffset = 0;
break;
}
@@ -947,7 +940,7 @@ public class IOConsolePartitioner
}
outputOffset = document.getLength();
nextWriteOffset = outputOffset;
- partititonContent(pending.stream, vtab, 0, vtab.length());
+ partititonContent(stream, vtab, 0, vtab.length(), content);
break;
case 0:
@@ -968,7 +961,6 @@ public class IOConsolePartitioner
}
}
applyOutputToDocument(content.toString(), nextWriteOffset, replaceLength);
- content = null;
}
/**
@@ -988,7 +980,8 @@ public class IOConsolePartitioner
* @param offset the start offset (inclusive) within text to partition
* @param endOffset the end offset (exclusive) within text to partition
*/
- private void partititonContent(IOConsoleOutputStream stream, CharSequence text, int offset, int endOffset) {
+ private void partititonContent(IOConsoleOutputStream stream, CharSequence text, int offset, int endOffset,
+ StringBuilder content) {
int textOffset = offset;
while (textOffset < endOffset) {
// Process content part. This part never contains control characters.
@@ -1180,27 +1173,25 @@ public class IOConsolePartitioner
* @param offset trims console content up to this offset
*/
public void setTrimOffset(int offset) {
+ // XXX an arbitrary offset would cause follow up errors if we trim a delim
+ // exactly between \r and \n
truncateOffset = offset;
truncateToOffsetLineStart = false;
}
- /**
- * Sets the trim offset.
- *
- * @param offset trims output up to the line containing this offset
- */
- public void setTrimLineOffset(int offset) {
- truncateOffset = offset;
- truncateToOffsetLineStart = true;
- }
-
@Override
public IStatus runInUIThread(IProgressMonitor monitor) {
synchronized (partitions) {
- if (document == null) {
- return Status.OK_STATUS;
- }
+ trim(truncateOffset, truncateToOffsetLineStart);
+ }
+ return Status.OK_STATUS;
+ }
+ }
+
+ private void trim(int truncateOffset, boolean truncateToOffsetLineStart) {
+ if (document != null) {
+ {
try {
int length = document.getLength();
int cutOffset = truncateOffset;
@@ -1242,7 +1233,6 @@ public class IOConsolePartitioner
log(e);
}
}
- return Status.OK_STATUS;
}
}
diff --git a/org.eclipse.ui.externaltools/.classpath b/org.eclipse.ui.externaltools/.classpath
index a612ce54a..71ebb06d5 100644
--- a/org.eclipse.ui.externaltools/.classpath
+++ b/org.eclipse.ui.externaltools/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="External Tools Base"/>
<classpathentry kind="src" path="Program Tools Support"/>
diff --git a/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.core.prefs
index 129d9d8a1..46a1b61e4 100644
--- a/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.core.prefs
+++ b/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.core.prefs
@@ -19,9 +19,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=11
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.8
+org.eclipse.jdt.core.compiler.compliance=11
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -38,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
+org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore
org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
@@ -96,6 +97,7 @@ org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warn
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
@@ -133,11 +135,13 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.8
+org.eclipse.jdt.core.compiler.release=enabled
+org.eclipse.jdt.core.compiler.source=11
org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled
org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,NORMAL,HIGH,HIGH
org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,EXPERIMENTAL,CONTEXTLAUNCHING
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_additive_operator=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=0
@@ -145,17 +149,20 @@ org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_c
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=0
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=0
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=0
+org.eclipse.jdt.core.formatter.alignment_for_bitwise_operator=0
org.eclipse.jdt.core.formatter.alignment_for_compact_if=0
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=0
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=32
+org.eclipse.jdt.core.formatter.alignment_for_logical_operator=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=0
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_string_concatenation=0
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=0
@@ -239,11 +246,12 @@ org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
@@ -273,6 +281,8 @@ org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=inser
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
@@ -297,13 +307,17 @@ org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_additive_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_bitwise_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
@@ -350,6 +364,8 @@ org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do n
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_logical_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_multiplicative_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
@@ -386,9 +402,12 @@ org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not inser
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_relational_operator=insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_shift_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_string_concatenation=insert
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
@@ -414,8 +433,12 @@ org.eclipse.jdt.core.formatter.tabulation.char=tab
org.eclipse.jdt.core.formatter.tabulation.size=4
org.eclipse.jdt.core.formatter.use_on_off_tags=false
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_additive_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_bitwise_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_logical_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_multiplicative_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
org.eclipse.jdt.core.incompatibleJDKLevel=ignore
org.eclipse.jdt.core.incompleteClasspath=error
diff --git a/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.ui.prefs
index 8e18452e3..ddcf96428 100644
--- a/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.ui.prefs
+++ b/org.eclipse.ui.externaltools/.settings/org.eclipse.jdt.ui.prefs
@@ -1,55 +1,3 @@
-cleanup.add_default_serial_version_id=true
-cleanup.add_generated_serial_version_id=false
-cleanup.add_missing_annotations=true
-cleanup.add_missing_deprecated_annotations=true
-cleanup.add_missing_methods=false
-cleanup.add_missing_nls_tags=false
-cleanup.add_missing_override_annotations=true
-cleanup.add_missing_override_annotations_interface_methods=true
-cleanup.add_serial_version_id=false
-cleanup.always_use_blocks=true
-cleanup.always_use_parentheses_in_expressions=false
-cleanup.always_use_this_for_non_static_field_access=false
-cleanup.always_use_this_for_non_static_method_access=false
-cleanup.convert_to_enhanced_for_loop=false
-cleanup.correct_indentation=false
-cleanup.format_source_code=true
-cleanup.format_source_code_changes_only=false
-cleanup.make_local_variable_final=true
-cleanup.make_parameters_final=false
-cleanup.make_private_fields_final=true
-cleanup.make_type_abstract_if_missing_method=false
-cleanup.make_variable_declarations_final=false
-cleanup.never_use_blocks=false
-cleanup.never_use_parentheses_in_expressions=true
-cleanup.organize_imports=true
-cleanup.qualify_static_field_accesses_with_declaring_class=false
-cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-cleanup.qualify_static_member_accesses_with_declaring_class=true
-cleanup.qualify_static_method_accesses_with_declaring_class=false
-cleanup.remove_private_constructors=true
-cleanup.remove_trailing_whitespaces=true
-cleanup.remove_trailing_whitespaces_all=true
-cleanup.remove_trailing_whitespaces_ignore_empty=false
-cleanup.remove_unnecessary_casts=true
-cleanup.remove_unnecessary_nls_tags=true
-cleanup.remove_unused_imports=true
-cleanup.remove_unused_local_variables=false
-cleanup.remove_unused_private_fields=true
-cleanup.remove_unused_private_members=false
-cleanup.remove_unused_private_methods=true
-cleanup.remove_unused_private_types=true
-cleanup.sort_members=false
-cleanup.sort_members_all=false
-cleanup.use_blocks=true
-cleanup.use_blocks_only_for_return_and_throw=false
-cleanup.use_parentheses_in_expressions=false
-cleanup.use_this_for_non_static_field_access=false
-cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-cleanup.use_this_for_non_static_method_access=false
-cleanup.use_this_for_non_static_method_access_only_if_necessary=true
-cleanup_profile=_Platform Debug Cleanups
cleanup_settings_version=2
eclipse.preferences.version=1
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsBuildTab.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsBuildTab.java
index a0e96b04a..efd514529 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsBuildTab.java
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsBuildTab.java
@@ -79,7 +79,7 @@ public class ExternalToolsBuildTab extends AbstractLaunchConfigurationTab {
// projects to build (empty if none)
private List<IProject> fProjects = new ArrayList<>();
- class ProjectsContentProvider implements IStructuredContentProvider {
+ static class ProjectsContentProvider implements IStructuredContentProvider {
@Override
public Object[] getElements(Object inputElement) {
@@ -232,17 +232,15 @@ public class ExternalToolsBuildTab extends AbstractLaunchConfigurationTab {
// select the workspace by default
fBuildButton.setSelection(true);
fWorkspaceButton.setSelection(true);
- } else {
- if (scope.equals("${none}")) { //$NON-NLS-1$
- fBuildButton.setSelection(false);
- } else if (scope.equals("${project}")) { //$NON-NLS-1$
- fProjectButton.setSelection(true);
- } else if (scope.startsWith("${projects:")) { //$NON-NLS-1$
- fSpecificProjectsButton.setSelection(true);
- IProject[] projects = getBuildProjects(configuration, IExternalToolConstants.ATTR_BUILD_SCOPE);
- fProjects = new ArrayList<>(projects.length);
- Collections.addAll(fProjects, projects);
- }
+ } else if (scope.equals("${none}")) { //$NON-NLS-1$
+ fBuildButton.setSelection(false);
+ } else if (scope.equals("${project}")) { //$NON-NLS-1$
+ fProjectButton.setSelection(true);
+ } else if (scope.startsWith("${projects:")) { //$NON-NLS-1$
+ fSpecificProjectsButton.setSelection(true);
+ IProject[] projects = getBuildProjects(configuration, IExternalToolConstants.ATTR_BUILD_SCOPE);
+ fProjects = new ArrayList<>(projects.length);
+ Collections.addAll(fProjects, projects);
}
}
@Override
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsMainTab.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsMainTab.java
index 8b8a8b438..0eab24c12 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsMainTab.java
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/launchConfigurations/ExternalToolsMainTab.java
@@ -626,7 +626,7 @@ public abstract class ExternalToolsMainTab extends AbstractLaunchConfigurationTa
control.getAccessible().addAccessibleListener(new ControlAccessibleListener(stripped.toString()));
}
- private class ControlAccessibleListener extends AccessibleAdapter {
+ private static class ControlAccessibleListener extends AccessibleAdapter {
private String controlName;
ControlAccessibleListener(String name) {
controlName = name;
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/BuilderUtils.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/BuilderUtils.java
index e0f4d21c8..039cd0a7e 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/BuilderUtils.java
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/BuilderUtils.java
@@ -82,20 +82,6 @@ public class BuilderUtils {
}
/**
- * Returns whether the given configuration is an "unmigrated" builder.
- * Unmigrated builders are external tools that are stored in an old format
- * but have not been migrated by the user. Old format builders are always
- * translated into launch config working copies in memory, but they're not
- * considered "migrated" until the config has been saved and the project spec
- * updated.
- * @param config the config to examine
- * @return whether the given config represents an unmigrated builder
- */
- public static boolean isUnmigratedConfig(ILaunchConfiguration config) {
- return BuilderCoreUtils.isUnmigratedConfig(config);
- }
-
- /**
* Converts the given config to a build command which is stored in the
* given command.
*
@@ -154,25 +140,6 @@ public class BuilderUtils {
return newWorkingCopy.doSave();
}
- /**
- * Migrates the launch configuration working copy, which is based on an old-
- * style external tool builder, to a new, saved launch configuration. The
- * returned launch configuration will contain the same attributes as the
- * given working copy with the exception of the configuration name, which
- * may be changed during the migration. The name of the configuration will
- * only be changed if the current name is not a valid name for a saved
- * config.
- *
- * @param workingCopy the launch configuration containing attributes from an
- * old-style project builder.
- * @return ILaunchConfiguration a new, saved launch configuration whose
- * attributes match those of the given working copy as well as possible
- * @throws CoreException if an exception occurs while attempting to save the
- * new launch configuration
- */
- public static ILaunchConfiguration migrateBuilderConfiguration(IProject project, ILaunchConfigurationWorkingCopy workingCopy) throws CoreException {
- return BuilderCoreUtils.migrateBuilderConfiguration(project, workingCopy);
- }
/**
* Converts the build types string into an array of
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPlugin.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPlugin.java
index 1e75be8a7..3d66b868e 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPlugin.java
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPlugin.java
@@ -63,7 +63,7 @@ public final class ExternalToolsPlugin extends AbstractUIPlugin implements
* A window listener that warns the user about any running programs when the
* workbench closes. Programs are killed when the VM exits.
*/
- private class ProgramLaunchWindowListener implements IWindowListener {
+ private static class ProgramLaunchWindowListener implements IWindowListener {
@Override
public void windowActivated(IWorkbenchWindow window) {
}
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPreferenceInitializer.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPreferenceInitializer.java
deleted file mode 100644
index 1c8043a5b..000000000
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/ExternalToolsPreferenceInitializer.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2013 IBM Corporation and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ui.externaltools.internal.model;
-
-import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
-import org.eclipse.jface.preference.IPreferenceStore;
-
-public class ExternalToolsPreferenceInitializer extends AbstractPreferenceInitializer {
-
- public ExternalToolsPreferenceInitializer() {
- super();
- }
-
- @Override
- public void initializeDefaultPreferences() {
- IPreferenceStore prefs = ExternalToolsPlugin.getDefault().getPreferenceStore();
- prefs.setDefault(IPreferenceConstants.PROMPT_FOR_TOOL_MIGRATION, true);
- prefs.setDefault(IPreferenceConstants.PROMPT_FOR_PROJECT_MIGRATION, true);
- }
-}
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/IPreferenceConstants.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/IPreferenceConstants.java
deleted file mode 100644
index c63cd7e74..000000000
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/model/IPreferenceConstants.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2005 IBM Corporation and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.ui.externaltools.internal.model;
-
-
-/**
- * Constants used to identify user preferences.
- */
-public interface IPreferenceConstants {
-
- /**
- * Boolean preference key which indicates whether or not the user should be prompted
- * before an external tool project builder is migrated to the new builder format.
- * This is used before an old-style (Eclipse 1.0 or 2.0) builder is migrated to
- * the new format (launch configurations).
- */
- String PROMPT_FOR_TOOL_MIGRATION = "externaltools.builders.promptForMigration"; //$NON-NLS-1$
- /**
- * Boolean preference key which indicates whether or not the user should be prompted
- * before a project is migrated tot he new builder handle format.
- * This is used before an old-style (Eclipse 2.1) project handle is migrated
- * from the old format (launch config handles) to the new format (path to the launch).
- */
- String PROMPT_FOR_PROJECT_MIGRATION = "externaltools.builders.promptForProjectMigration"; //$NON-NLS-1$
-}
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java
index 2bee78fc2..fd87237ad 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/BuilderPropertyPage.java
@@ -50,9 +50,7 @@ import org.eclipse.debug.ui.DebugUITools;
import org.eclipse.jface.dialogs.ErrorDialog;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.dialogs.MessageDialogWithToggle;
import org.eclipse.jface.operation.IRunnableWithProgress;
-import org.eclipse.jface.preference.IPreferenceStore;
import org.eclipse.jface.viewers.CheckStateChangedEvent;
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
@@ -84,7 +82,6 @@ import org.eclipse.ui.externaltools.internal.launchConfigurations.IgnoreWhiteSpa
import org.eclipse.ui.externaltools.internal.model.BuilderUtils;
import org.eclipse.ui.externaltools.internal.model.ExternalToolsPlugin;
import org.eclipse.ui.externaltools.internal.model.IExternalToolsHelpContextIds;
-import org.eclipse.ui.externaltools.internal.model.IPreferenceConstants;
import org.eclipse.ui.progress.IProgressService;
/**
@@ -116,7 +113,7 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
* Error configs are objects representing entries pointing to
* invalid launch configurations
*/
- public class ErrorConfig {
+ public static class ErrorConfig {
private ICommand command;
public ErrorConfig(ICommand command) {
this.command= command;
@@ -214,15 +211,9 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
return;
}
- boolean projectNeedsMigration= false;
for (ICommand command : commands) {
String[] version= new String[] {IExternalToolConstants.EMPTY_STRING};
ILaunchConfiguration config = BuilderUtils.configFromBuildCommandArgs(project, command.getArguments(), version);
- if (BuilderCoreUtils.VERSION_2_1.equals(version[0])) {
- // Storing the .project file of a project with 2.1 configs, will
- // edit the file in a way that isn't backwards compatible.
- projectNeedsMigration= true;
- }
Object element= null;
if (config != null) {
if (!config.isWorkingCopy() && !config.exists()) {
@@ -252,29 +243,6 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
viewer.setChecked(element, isEnabled(element));
}
}
- if (projectNeedsMigration) {
- IPreferenceStore store= ExternalToolsPlugin.getDefault().getPreferenceStore();
- boolean prompt= store.getBoolean(IPreferenceConstants.PROMPT_FOR_PROJECT_MIGRATION);
- boolean proceed= true;
- if (prompt) {
- Shell shell= getShell();
- if (shell == null) {
- return;
- }
- MessageDialogWithToggle dialog= MessageDialogWithToggle.openYesNoQuestion(shell, ExternalToolsUIMessages.BuilderPropertyPage_0, ExternalToolsUIMessages.BuilderPropertyPage_1, ExternalToolsUIMessages.BuilderPropertyPage_2, false, null, null);
- proceed= dialog.getReturnCode() == IDialogConstants.YES_ID;
- store.setValue(IPreferenceConstants.PROMPT_FOR_PROJECT_MIGRATION, !dialog.getToggleState());
- }
- if (!proceed) {
- // Open the page read-only
- viewer.getTable().setEnabled(false);
- downButton.setEnabled(false);
- editButton.setEnabled(false);
- importButton.setEnabled(false);
- newButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
}
/**
@@ -693,19 +661,6 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
Object data = selection.getData();
if (data instanceof ILaunchConfiguration) {
ILaunchConfiguration config= (ILaunchConfiguration) data;
- if (BuilderUtils.isUnmigratedConfig(config)) {
- if (!shouldProceedWithMigration()) {
- return;
- }
- try {
- config= BuilderUtils.migrateBuilderConfiguration(getInputProject(), (ILaunchConfigurationWorkingCopy) config);
- } catch (CoreException e) {
- handleException(e);
- return;
- }
- // Replace the working copy in the table with the migrated configuration
- selection.setData(config);
- }
userHasMadeChanges= true;
boolean wasAutobuilding= ResourcesPlugin.getWorkspace().getDescription().isAutoBuilding();
try {
@@ -736,32 +691,6 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
return Window.OK == dialog.open();
}
- /**
- * Prompts the user to proceed with the migration of a project builder from
- * the old format to the new, launch configuration-based, format and returns
- * whether or not the user wishes to proceed with the migration.
- *
- * @return boolean whether or not the user wishes to proceed with migration
- */
- private boolean shouldProceedWithMigration() {
- if (!ExternalToolsPlugin.getDefault().getPreferenceStore().getBoolean(IPreferenceConstants.PROMPT_FOR_TOOL_MIGRATION)) {
- // User has asked not to be prompted
- return true;
- }
- Shell shell= getShell();
- if (shell == null) {
- return false;
- }
- // Warn the user that editing an old config will cause storage migration.
- MessageDialogWithToggle dialog= MessageDialogWithToggle.openYesNoQuestion(getShell(),
- ExternalToolsUIMessages.BuilderPropertyPage_Migrate_project_builder_10,
- ExternalToolsUIMessages.BuilderPropertyPage_Not_Support,
- ExternalToolsUIMessages.BuilderPropertyPage_Prompt,
- false,
- ExternalToolsPlugin.getDefault().getPreferenceStore(),
- IPreferenceConstants.PROMPT_FOR_TOOL_MIGRATION);
- return dialog.getReturnCode() == IDialogConstants.YES_ID;
- }
/**
* Handles unexpected internal exceptions
@@ -988,17 +917,17 @@ public final class BuilderPropertyPage extends PropertyPage implements ICheckSta
}
} catch (CoreException e1) {
}
-
- if (!BuilderUtils.isUnmigratedConfig(config) && (config instanceof ILaunchConfigurationWorkingCopy)) {
- ILaunchConfigurationWorkingCopy workingCopy= ((ILaunchConfigurationWorkingCopy) config);
+ if (config instanceof ILaunchConfigurationWorkingCopy) {
+ ILaunchConfigurationWorkingCopy workingCopy = ((ILaunchConfigurationWorkingCopy) config);
// Save any changes to the config (such as enable/disable)
if (workingCopy.isDirty()) {
try {
workingCopy.doSave();
} catch (CoreException e) {
- Shell shell= getShell();
+ Shell shell = getShell();
if (shell != null) {
- MessageDialog.openError(shell, ExternalToolsUIMessages.BuilderPropertyPage_39, NLS.bind(ExternalToolsUIMessages.BuilderPropertyPage_40, new String[] {workingCopy.getName()}));
+ MessageDialog.openError(shell, ExternalToolsUIMessages.BuilderPropertyPage_39, NLS.bind(ExternalToolsUIMessages.BuilderPropertyPage_40, new String[] {
+ workingCopy.getName() }));
}
}
}
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsPreferencePage.java b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsPreferencePage.java
deleted file mode 100644
index b3728dfbe..000000000
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsPreferencePage.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2013 IBM Corporation and others.
- *
- * This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License 2.0
- * which accompanies this distribution, and is available at
- * https://www.eclipse.org/legal/epl-2.0/
- *
- * SPDX-License-Identifier: EPL-2.0
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- * Frederic Gurr - Fixed restore default behavior (bug 346082)
- *******************************************************************************/
-package org.eclipse.ui.externaltools.internal.ui;
-
-
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.externaltools.internal.model.ExternalToolsPlugin;
-import org.eclipse.ui.externaltools.internal.model.IExternalToolsHelpContextIds;
-import org.eclipse.ui.externaltools.internal.model.IPreferenceConstants;
-
-/**
- * Preference page that allows the user to customize external tools
- */
-public class ExternalToolsPreferencePage extends PreferencePage implements IWorkbenchPreferencePage {
-
- private Button promptForToolMigrationButton;
- private Button promptForProjectMigrationButton;
-
- public ExternalToolsPreferencePage() {
- setPreferenceStore(ExternalToolsPlugin.getDefault().getPreferenceStore());
- setDescription(ExternalToolsUIMessages.ExternalToolsPreferencePage_External_tool_project_builders_migration_2);
- }
-
- /**
- * @see org.eclipse.jface.preference.PreferencePage#createContents(org.eclipse.swt.widgets.Composite)
- */
- @Override
- protected Control createContents(Composite parent) {
- PlatformUI.getWorkbench().getHelpSystem().setHelp(parent, IExternalToolsHelpContextIds.EXTERNAL_TOOLS_PREFERENCE_PAGE);
- //The main composite
- Composite composite = new Composite(parent, SWT.NULL);
- GridLayout layout = new GridLayout();
- layout.marginHeight=0;
- layout.marginWidth=0;
- composite.setLayout(layout);
- composite.setFont(parent.getFont());
-
- promptForToolMigrationButton= createCheckButton(composite, ExternalToolsUIMessages.ExternalToolsPreferencePage_Prompt_before_migrating_3, IPreferenceConstants.PROMPT_FOR_TOOL_MIGRATION);
- promptForProjectMigrationButton= createCheckButton(composite, ExternalToolsUIMessages.ExternalToolsPreferencePage_1, IPreferenceConstants.PROMPT_FOR_PROJECT_MIGRATION);
-
- applyDialogFont(composite);
-
- return composite;
- }
-
- /**
- * Returns a new check button with the given label for the given preference.
- */
- private Button createCheckButton(Composite parent, String label, String preferenceKey) {
- Button button= new Button(parent, SWT.CHECK | SWT.LEFT);
- button.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING));
- button.setFont(parent.getFont());
- button.setText(label);
- button.setSelection(getPreferenceStore().getBoolean(preferenceKey));
- return button;
- }
-
- /**
- * @see org.eclipse.ui.IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)
- */
- @Override
- public void init(IWorkbench workbench) {
- }
-
- /**
- * @see org.eclipse.jface.preference.PreferencePage#performOk()
- */
- @Override
- public boolean performOk() {
- getPreferenceStore().setValue(IPreferenceConstants.PROMPT_FOR_TOOL_MIGRATION, promptForToolMigrationButton.getSelection());
- getPreferenceStore().setValue(IPreferenceConstants.PROMPT_FOR_PROJECT_MIGRATION, promptForProjectMigrationButton.getSelection());
- return super.performOk();
- }
-
- /**
- * @see org.eclipse.jface.preference.PreferencePage#performDefaults()
- */
- @Override
- protected void performDefaults() {
- promptForToolMigrationButton.setSelection(getPreferenceStore().getDefaultBoolean(IPreferenceConstants.PROMPT_FOR_TOOL_MIGRATION));
- promptForProjectMigrationButton.setSelection(getPreferenceStore().getDefaultBoolean(IPreferenceConstants.PROMPT_FOR_PROJECT_MIGRATION));
- super.performDefaults();
- }
-}
diff --git a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsUIMessages.properties b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsUIMessages.properties
index 6c8b79ce6..e28068367 100644
--- a/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsUIMessages.properties
+++ b/org.eclipse.ui.externaltools/External Tools Base/org/eclipse/ui/externaltools/internal/ui/ExternalToolsUIMessages.properties
@@ -49,10 +49,6 @@ FileSelectionDialog_Choose_Location_1=Choose Location
FileSelectionDialog_Ok_2=OK
FileSelectionDialog_Cancel_3=Cancel
-ExternalToolsPreferencePage_External_tool_project_builders_migration_2=External tool project builders stored in an old format will be migrated to a new format when edited. Projects which store builders using an old format will be migrated whenever a change is made. Once migrated, project builders will not be understood by installations using these older formats.
-ExternalToolsPreferencePage_Prompt_before_migrating_3=&Confirm before migrating external tool project builders for edit
-ExternalToolsPreferencePage_1=C&onfirm before migrating projects to the new format
-
EditCommandDialog_0=Configure Builder
EditCommandDialog_1=Run this builder:
EditCommandDialog_2=After a "&Clean"
diff --git a/org.eclipse.ui.externaltools/META-INF/MANIFEST.MF b/org.eclipse.ui.externaltools/META-INF/MANIFEST.MF
index 84ee566d6..bf34b2762 100644
--- a/org.eclipse.ui.externaltools/META-INF/MANIFEST.MF
+++ b/org.eclipse.ui.externaltools/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Plugin.name
Bundle-SymbolicName: org.eclipse.ui.externaltools; singleton:=true
-Bundle-Version: 3.4.900.qualifier
+Bundle-Version: 3.5.100.qualifier
Bundle-Activator: org.eclipse.ui.externaltools.internal.model.ExternalToolsPlugin
Bundle-Vendor: %Plugin.providerName
Bundle-Localization: plugin
@@ -21,5 +21,5 @@ Require-Bundle: org.eclipse.ui.ide;bundle-version="[3.2.0,4.0.0)";resolution:=op
org.eclipse.core.runtime;bundle-version="[3.1.0,4.0.0)",
org.eclipse.core.externaltools;bundle-version="[1.0.300,2.0.0)"
Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+Bundle-RequiredExecutionEnvironment: JavaSE-11
Automatic-Module-Name: org.eclipse.ui.externaltools
diff --git a/org.eclipse.ui.externaltools/plugin.xml b/org.eclipse.ui.externaltools/plugin.xml
index 3800d0d63..1809465e3 100644
--- a/org.eclipse.ui.externaltools/plugin.xml
+++ b/org.eclipse.ui.externaltools/plugin.xml
@@ -78,15 +78,6 @@
</command>
</extension>
<extension
- point="org.eclipse.ui.preferencePages">
- <page
- name="%PreferencePage.externalToolsPreferences"
- category="org.eclipse.debug.ui.DebugPreferencePage"
- class="org.eclipse.ui.externaltools.internal.ui.ExternalToolsPreferencePage"
- id="org.eclipse.ui.externaltools.ExternalToolsPreferencePage">
- </page>
- </extension>
- <extension
point="org.eclipse.ui.propertyPages">
<page
name="%PropertyPage.externalToolsBuilders"
@@ -198,9 +189,5 @@
id="org.eclipse.ui.externaltools.workingSetComparator">
</launchConfigurationComparator>
</extension>
-
- <extension point="org.eclipse.core.runtime.preferences">
- <initializer class="org.eclipse.ui.externaltools.internal.model.ExternalToolsPreferenceInitializer"/>
- </extension>
</plugin>
diff --git a/org.eclipse.unittest.ui/pom.xml b/org.eclipse.unittest.ui/pom.xml
index 13fc94da8..095e3f78d 100644
--- a/org.eclipse.unittest.ui/pom.xml
+++ b/org.eclipse.unittest.ui/pom.xml
@@ -15,7 +15,7 @@
<parent>
<artifactId>eclipse.platform.debug</artifactId>
<groupId>eclipse.platform.debug</groupId>
- <version>4.20.0-SNAPSHOT</version>
+ <version>4.24.0-SNAPSHOT</version>
</parent>
<groupId>org.eclipse.debug</groupId>
<artifactId>org.eclipse.unittest.ui</artifactId>
diff --git a/org.eclipse.unittest.ui/src/org/eclipse/unittest/internal/UnitTestPreferencesConstants.java b/org.eclipse.unittest.ui/src/org/eclipse/unittest/internal/UnitTestPreferencesConstants.java
index 1afcd46b4..2d043f0cb 100644
--- a/org.eclipse.unittest.ui/src/org/eclipse/unittest/internal/UnitTestPreferencesConstants.java
+++ b/org.eclipse.unittest.ui/src/org/eclipse/unittest/internal/UnitTestPreferencesConstants.java
@@ -55,14 +55,7 @@ public class UnitTestPreferencesConstants {
if (list == null)
return ""; //$NON-NLS-1$
- StringBuilder buffer = new StringBuilder();
- for (int i = 0; i < list.length; i++) {
- if (i > 0)
- buffer.append(',');
-
- buffer.append(list[i]);
- }
- return buffer.toString();
+ return String.join(String.valueOf(','), list);
}
/**
diff --git a/pom.xml b/pom.xml
index 4167f3541..201de859c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -15,7 +15,7 @@
<parent>
<groupId>org.eclipse</groupId>
<artifactId>eclipse-platform-parent</artifactId>
- <version>4.20.0-SNAPSHOT</version>
+ <version>4.24.0-SNAPSHOT</version>
<relativePath>../eclipse-platform-parent</relativePath>
</parent>
@@ -24,7 +24,7 @@
<packaging>pom</packaging>
<properties>
- <tycho.scmUrl>scm:git:git://git.eclipse.org/gitroot/platform/eclipse.platform.debug.git</tycho.scmUrl>
+ <tycho.scmUrl>scm:git:https://git.eclipse.org/r/platform/eclipse.platform.debug.git</tycho.scmUrl>
</properties>
<!--
@@ -60,6 +60,8 @@
<module>org.eclipse.debug.examples.ui</module>
<module>org.eclipse.debug.tests</module>
<module>org.eclipse.debug.ui</module>
+ <module>org.eclipse.debug.ui.launchview</module>
+ <module>org.eclipse.debug.ui.launchview.tests</module>
<module>org.eclipse.ui.console</module>
<module>org.eclipse.ui.externaltools</module>
<module>org.eclipse.unittest.ui</module>

Back to the top