Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.debug.ui/ui/org/eclipse/debug/internal')
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/RelaunchLastAction.java66
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointContainer.java104
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointOrganizer.java126
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/OtherBreakpointCategory.java182
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/IEnabledTarget.java36
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContainerMementoProvider.java96
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContentProvider.java80
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerInputMementoProvider.java66
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointMementoProvider.java174
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/ProcessContentProvider.java82
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IColumnPresentation2.java70
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IModelProxyFactory2.java96
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointContainerProxy.java110
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointProxy.java102
14 files changed, 695 insertions, 695 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/RelaunchLastAction.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/RelaunchLastAction.java
index 9715c9444..9c1ff6ef6 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/RelaunchLastAction.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/actions/RelaunchLastAction.java
@@ -1,36 +1,36 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2013 IBM Corporation and others.
+/*******************************************************************************
+ * 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
+ * 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
- * Wind River Systems - bug 227877
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.actions;
-
-
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.internal.ui.contextlaunching.ContextRunner;
-
-/**
- * Re-launches the last launch.
- *
- * @see ContextRunner
- * @see ILaunchConfiguration
- * @see RunLastAction
- * @see DebugLastAction
- * @see ProfileLastAction
- * @since 3.8
- * @deprecated This class has been promoted to API as <code>org.eclipse.debug.ui.actions.RelaunchLastAction</code>. Clients
- * should discontinue use of this class and use the new API version.
- */
-@Deprecated
-public abstract class RelaunchLastAction extends org.eclipse.debug.ui.actions.RelaunchLastAction {
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ * Wind River Systems - bug 227877
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.actions;
+
+
+import org.eclipse.debug.core.ILaunchConfiguration;
+import org.eclipse.debug.internal.ui.contextlaunching.ContextRunner;
+
+/**
+ * Re-launches the last launch.
+ *
+ * @see ContextRunner
+ * @see ILaunchConfiguration
+ * @see RunLastAction
+ * @see DebugLastAction
+ * @see ProfileLastAction
+ * @since 3.8
+ * @deprecated This class has been promoted to API as <code>org.eclipse.debug.ui.actions.RelaunchLastAction</code>. Clients
+ * should discontinue use of this class and use the new API version.
+ */
+@Deprecated
+public abstract class RelaunchLastAction extends org.eclipse.debug.ui.actions.RelaunchLastAction {
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointContainer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointContainer.java
index 2eb5476d6..997b219ff 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointContainer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointContainer.java
@@ -1,55 +1,55 @@
-/*******************************************************************************
- * Copyright (c) 2008, 2009 Wind River Systems and others.
+/*******************************************************************************
+ * Copyright (c) 2008, 2009 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
+ * 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
- * Patrick Chuong (Texas Instruments) - Improve usability of the breakpoint view (Bug 238956)
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.breakpoints.provisional;
-
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.debug.core.model.IBreakpoint;
-
-/**
- * Interface representing a breakpoint category container elements in
- * Breakpoints view. Clients which provide custom content in the
- * Breakpoints view may implement this interface to represent container
- * elements. This will allow the breakpoints view to properly handle
- * drag-and-drop and copy-paste operations.
- *
- * @since 3.6
- */
-public interface IBreakpointContainer {
-
- /**
- * Returns the breakpoint organizer that this container uses.
- */
- IBreakpointOrganizer getOrganizer();
-
- /**
- * Returns the breakpoint category that this container is based on.
- * @return
- */
- IAdaptable getCategory();
-
- /**
- * Returns whether this breakpoint container contains the given breakpoint.
- *
- * @param breakpoint Breakpoint to check
- * @return Returns <code>true</code> if this container contains the
- * given breakpoint.
- */
- boolean contains(IBreakpoint breakpoint);
-
- /**
- * Returns the array of breakpoints in this container.
- */
- IBreakpoint[] getBreakpoints();
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Wind River Systems - initial API and implementation
+ * Patrick Chuong (Texas Instruments) - Improve usability of the breakpoint view (Bug 238956)
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.breakpoints.provisional;
+
+import org.eclipse.core.runtime.IAdaptable;
+import org.eclipse.debug.core.model.IBreakpoint;
+
+/**
+ * Interface representing a breakpoint category container elements in
+ * Breakpoints view. Clients which provide custom content in the
+ * Breakpoints view may implement this interface to represent container
+ * elements. This will allow the breakpoints view to properly handle
+ * drag-and-drop and copy-paste operations.
+ *
+ * @since 3.6
+ */
+public interface IBreakpointContainer {
+
+ /**
+ * Returns the breakpoint organizer that this container uses.
+ */
+ IBreakpointOrganizer getOrganizer();
+
+ /**
+ * Returns the breakpoint category that this container is based on.
+ * @return
+ */
+ IAdaptable getCategory();
+
+ /**
+ * Returns whether this breakpoint container contains the given breakpoint.
+ *
+ * @param breakpoint Breakpoint to check
+ * @return Returns <code>true</code> if this container contains the
+ * given breakpoint.
+ */
+ boolean contains(IBreakpoint breakpoint);
+
+ /**
+ * Returns the array of breakpoints in this container.
+ */
+ IBreakpoint[] getBreakpoints();
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointOrganizer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointOrganizer.java
index 0493734be..49cca1221 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointOrganizer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/IBreakpointOrganizer.java
@@ -1,66 +1,66 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2009 IBM Corporation and others.
+/*******************************************************************************
+ * Copyright (c) 2000, 2009 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
+ * 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.internal.ui.breakpoints.provisional;
-
-import org.eclipse.debug.ui.IBreakpointOrganizerDelegate;
-import org.eclipse.jface.resource.ImageDescriptor;
-
-/**
- * A breakpoint organizer is represents a breakpoint organizer delegate in
- * the breakpoint view. Clients can retrieve the current active breakpoint
- * organizers from the breakpoint view's presentation context using the
- * {@link IBreakpointUIConstants#PROP_BREAKPOINTS_ORGANIZERS} property.
- * <p>
- * This interface is not intended to be implemented. Clients contributing a breakpoint
- * organizer are intended to implement <code>IBreakpointOrganizerDelegate</code>.
- * </p>
- * @noimplement This interface is not intended to be implemented by clients.
- * @since 3.6 (internal interface since 3.1)
- *
- * @see IBreakpointUIConstants#PROP_BREAKPOINTS_ORGANIZERS
- * @see org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext
- */
-public interface IBreakpointOrganizer extends IBreakpointOrganizerDelegate {
-
- /**
- * Returns a label for this breakpoint organizer.
- *
- * @return a label for this breakpoint organizer
- */
- String getLabel();
-
- /**
- * Returns an image descriptor for this breakpoint organizer or <code>null</code>.
- *
- * @return an image descriptor for this breakpoint organizer or <code>null</code>
- */
- ImageDescriptor getImageDescriptor();
-
- /**
- * Returns a unique identifier for this breakpoint organizer.
- *
- * @return a unique identifier for this breakpoint organizer
- */
- String getIdentifier();
-
- /**
- * Returns the label for breakpoints that do not fall into a category
- * for this organizer.
- *
- * @return label for breakpoints that do not fall into a category
- * for this organizer
- */
- String getOthersLabel();
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.breakpoints.provisional;
+
+import org.eclipse.debug.ui.IBreakpointOrganizerDelegate;
+import org.eclipse.jface.resource.ImageDescriptor;
+
+/**
+ * A breakpoint organizer is represents a breakpoint organizer delegate in
+ * the breakpoint view. Clients can retrieve the current active breakpoint
+ * organizers from the breakpoint view's presentation context using the
+ * {@link IBreakpointUIConstants#PROP_BREAKPOINTS_ORGANIZERS} property.
+ * <p>
+ * This interface is not intended to be implemented. Clients contributing a breakpoint
+ * organizer are intended to implement <code>IBreakpointOrganizerDelegate</code>.
+ * </p>
+ * @noimplement This interface is not intended to be implemented by clients.
+ * @since 3.6 (internal interface since 3.1)
+ *
+ * @see IBreakpointUIConstants#PROP_BREAKPOINTS_ORGANIZERS
+ * @see org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext
+ */
+public interface IBreakpointOrganizer extends IBreakpointOrganizerDelegate {
+
+ /**
+ * Returns a label for this breakpoint organizer.
+ *
+ * @return a label for this breakpoint organizer
+ */
+ String getLabel();
+
+ /**
+ * Returns an image descriptor for this breakpoint organizer or <code>null</code>.
+ *
+ * @return an image descriptor for this breakpoint organizer or <code>null</code>
+ */
+ ImageDescriptor getImageDescriptor();
+
+ /**
+ * Returns a unique identifier for this breakpoint organizer.
+ *
+ * @return a unique identifier for this breakpoint organizer
+ */
+ String getIdentifier();
+
+ /**
+ * Returns the label for breakpoints that do not fall into a category
+ * for this organizer.
+ *
+ * @return label for breakpoints that do not fall into a category
+ * for this organizer
+ */
+ String getOthersLabel();
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/OtherBreakpointCategory.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/OtherBreakpointCategory.java
index b1b8f6d0d..9705e1459 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/OtherBreakpointCategory.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/breakpoints/provisional/OtherBreakpointCategory.java
@@ -1,94 +1,94 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2013 IBM Corporation and others.
+/*******************************************************************************
+ * 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
+ * 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.internal.ui.breakpoints.provisional;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.PlatformObject;
-import org.eclipse.debug.internal.ui.DebugPluginImages;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.ui.model.IWorkbenchAdapter;
-
-/**
- * Category for breakpoints in "other" categories. Clients which provide
- * custom content in the Breakpoints view may instantiate this object to
- * represent elements in a breakpoint organizer that do not fall into any known
- * category.
- *
- * @since 3.6
- *
- * @see IBreakpointContainer
- * @see org.eclipse.debug.ui.IBreakpointOrganizerDelegate
- */
-public class OtherBreakpointCategory extends PlatformObject implements IWorkbenchAdapter {
-
- private static Map<IBreakpointOrganizer, IAdaptable[]> fOthers = new HashMap<>();
- private IBreakpointOrganizer fOrganizer;
-
-
- public static IAdaptable[] getCategories(IBreakpointOrganizer organizer) {
- IAdaptable[] others = fOthers.get(organizer);
- if (others == null) {
- others = new IAdaptable[]{new OtherBreakpointCategory(organizer)};
- fOthers.put(organizer, others);
- }
- return others;
- }
-
- /**
- * Constructs an 'other' category for the given organizer.
- *
- * @param organizer breakpoint organizer
- */
- private OtherBreakpointCategory(IBreakpointOrganizer organizer) {
- fOrganizer = organizer;
- }
-
- @Override
- public Object[] getChildren(Object o) {
- return null;
- }
-
- @Override
- public ImageDescriptor getImageDescriptor(Object object) {
- return DebugPluginImages.getImageDescriptor(IDebugUIConstants.IMG_VIEW_BREAKPOINTS);
- }
-
- @Override
- public String getLabel(Object o) {
- return fOrganizer.getOthersLabel();
- }
-
- @Override
- public Object getParent(Object o) {
- return null;
- }
-
- @Override
- public boolean equals(Object obj) {
- if (obj instanceof OtherBreakpointCategory) {
- OtherBreakpointCategory category = (OtherBreakpointCategory) obj;
- return fOrganizer.equals(category.fOrganizer);
- }
- return false;
- }
-
- @Override
- public int hashCode() {
- return fOrganizer.hashCode();
- }
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.breakpoints.provisional;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.eclipse.core.runtime.IAdaptable;
+import org.eclipse.core.runtime.PlatformObject;
+import org.eclipse.debug.internal.ui.DebugPluginImages;
+import org.eclipse.debug.ui.IDebugUIConstants;
+import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.ui.model.IWorkbenchAdapter;
+
+/**
+ * Category for breakpoints in "other" categories. Clients which provide
+ * custom content in the Breakpoints view may instantiate this object to
+ * represent elements in a breakpoint organizer that do not fall into any known
+ * category.
+ *
+ * @since 3.6
+ *
+ * @see IBreakpointContainer
+ * @see org.eclipse.debug.ui.IBreakpointOrganizerDelegate
+ */
+public class OtherBreakpointCategory extends PlatformObject implements IWorkbenchAdapter {
+
+ private static Map<IBreakpointOrganizer, IAdaptable[]> fOthers = new HashMap<>();
+ private IBreakpointOrganizer fOrganizer;
+
+
+ public static IAdaptable[] getCategories(IBreakpointOrganizer organizer) {
+ IAdaptable[] others = fOthers.get(organizer);
+ if (others == null) {
+ others = new IAdaptable[]{new OtherBreakpointCategory(organizer)};
+ fOthers.put(organizer, others);
+ }
+ return others;
+ }
+
+ /**
+ * Constructs an 'other' category for the given organizer.
+ *
+ * @param organizer breakpoint organizer
+ */
+ private OtherBreakpointCategory(IBreakpointOrganizer organizer) {
+ fOrganizer = organizer;
+ }
+
+ @Override
+ public Object[] getChildren(Object o) {
+ return null;
+ }
+
+ @Override
+ public ImageDescriptor getImageDescriptor(Object object) {
+ return DebugPluginImages.getImageDescriptor(IDebugUIConstants.IMG_VIEW_BREAKPOINTS);
+ }
+
+ @Override
+ public String getLabel(Object o) {
+ return fOrganizer.getOthersLabel();
+ }
+
+ @Override
+ public Object getParent(Object o) {
+ return null;
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (obj instanceof OtherBreakpointCategory) {
+ OtherBreakpointCategory category = (OtherBreakpointCategory) obj;
+ return fOrganizer.equals(category.fOrganizer);
+ }
+ return false;
+ }
+
+ @Override
+ public int hashCode() {
+ return fOrganizer.hashCode();
+ }
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/IEnabledTarget.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/IEnabledTarget.java
index 615ee7803..adfc68e20 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/IEnabledTarget.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/commands/actions/IEnabledTarget.java
@@ -1,21 +1,21 @@
-/*******************************************************************************
- * Copyright (c) 2008, 2009 Wind River Systems and others.
+/*******************************************************************************
+ * Copyright (c) 2008, 2009 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
+ * 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
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.commands.actions;
-
-/**
- *
- */
-public interface IEnabledTarget {
- void setEnabled(boolean enabled);
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Wind River Systems - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.commands.actions;
+
+/**
+ *
+ */
+public interface IEnabledTarget {
+ void setEnabled(boolean enabled);
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContainerMementoProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContainerMementoProvider.java
index 9aad3e078..e51601ef4 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContainerMementoProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContainerMementoProvider.java
@@ -1,51 +1,51 @@
-/*****************************************************************
- * Copyright (c) 2009 Texas Instruments and others
+/*****************************************************************
+ * Copyright (c) 2009 Texas Instruments 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
+ * 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:
- * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
- *****************************************************************/
-package org.eclipse.debug.internal.ui.model.elements;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.debug.internal.ui.breakpoints.provisional.IBreakpointContainer;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.ui.model.IWorkbenchAdapter;
-
-/**
- * This class provides memento for the breakpoint container.
- *
- * @since 3.6
- */
-public class BreakpointContainerMementoProvider extends DebugElementMementoProvider {
-
- @Override
- protected String getElementName(Object element, IPresentationContext context) throws CoreException {
- if (element instanceof IBreakpointContainer) {
- IBreakpointContainer container = (IBreakpointContainer) element;
- IAdaptable category = container.getCategory();
- if (category != null) {
- IWorkbenchAdapter adapter = category.getAdapter(IWorkbenchAdapter.class);
- if (adapter != null) {
- return adapter.getLabel(category);
- }
- return container.getOrganizer().getLabel();
- }
- }
- return null;
- }
-
- @Override
- protected boolean supportsContextId(String id) {
- return IDebugUIConstants.ID_BREAKPOINT_VIEW.equals(id);
- }
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
+ *****************************************************************/
+package org.eclipse.debug.internal.ui.model.elements;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IAdaptable;
+import org.eclipse.debug.internal.ui.breakpoints.provisional.IBreakpointContainer;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.ui.IDebugUIConstants;
+import org.eclipse.ui.model.IWorkbenchAdapter;
+
+/**
+ * This class provides memento for the breakpoint container.
+ *
+ * @since 3.6
+ */
+public class BreakpointContainerMementoProvider extends DebugElementMementoProvider {
+
+ @Override
+ protected String getElementName(Object element, IPresentationContext context) throws CoreException {
+ if (element instanceof IBreakpointContainer) {
+ IBreakpointContainer container = (IBreakpointContainer) element;
+ IAdaptable category = container.getCategory();
+ if (category != null) {
+ IWorkbenchAdapter adapter = category.getAdapter(IWorkbenchAdapter.class);
+ if (adapter != null) {
+ return adapter.getLabel(category);
+ }
+ return container.getOrganizer().getLabel();
+ }
+ }
+ return null;
+ }
+
+ @Override
+ protected boolean supportsContextId(String id) {
+ return IDebugUIConstants.ID_BREAKPOINT_VIEW.equals(id);
+ }
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContentProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContentProvider.java
index 43bde9239..8c0a81e79 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContentProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointContentProvider.java
@@ -1,43 +1,43 @@
-/*****************************************************************
- * Copyright (c) 2009 Texas Instruments and others
+/*****************************************************************
+ * Copyright (c) 2009 Texas Instruments 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
+ * 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:
- * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
- *****************************************************************/
-package org.eclipse.debug.internal.ui.model.elements;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IViewerUpdate;
-import org.eclipse.debug.ui.IDebugUIConstants;
-
-/**
- * Breakpoint content provider.
- *
- * @since 3.6
- */
-public class BreakpointContentProvider extends ElementContentProvider {
-
- @Override
- protected int getChildCount(Object element, IPresentationContext context, IViewerUpdate monitor) throws CoreException {
- return 0;
- }
-
- @Override
- protected Object[] getChildren(Object parent, int index, int length, IPresentationContext context, IViewerUpdate monitor) throws CoreException {
- return null;
- }
-
- @Override
- protected boolean supportsContextId(String id) {
- return id.equals(IDebugUIConstants.ID_BREAKPOINT_VIEW);
- }
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
+ *****************************************************************/
+package org.eclipse.debug.internal.ui.model.elements;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IViewerUpdate;
+import org.eclipse.debug.ui.IDebugUIConstants;
+
+/**
+ * Breakpoint content provider.
+ *
+ * @since 3.6
+ */
+public class BreakpointContentProvider extends ElementContentProvider {
+
+ @Override
+ protected int getChildCount(Object element, IPresentationContext context, IViewerUpdate monitor) throws CoreException {
+ return 0;
+ }
+
+ @Override
+ protected Object[] getChildren(Object parent, int index, int length, IPresentationContext context, IViewerUpdate monitor) throws CoreException {
+ return null;
+ }
+
+ @Override
+ protected boolean supportsContextId(String id) {
+ return id.equals(IDebugUIConstants.ID_BREAKPOINT_VIEW);
+ }
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerInputMementoProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerInputMementoProvider.java
index e51cf3390..64f05d0b9 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerInputMementoProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointManagerInputMementoProvider.java
@@ -1,36 +1,36 @@
-/*****************************************************************
- * Copyright (c) 2009 Texas Instruments and others
+/*****************************************************************
+ * Copyright (c) 2009 Texas Instruments 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
+ * 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:
- * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
- *****************************************************************/
-package org.eclipse.debug.internal.ui.model.elements;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.ui.IDebugUIConstants;
-
-/**
- * Breakpoint manager input memento provider.
- *
- * @since 3.6
- */
-public class BreakpointManagerInputMementoProvider extends DebugElementMementoProvider {
-
- @Override
- protected String getElementName(Object element, IPresentationContext context) throws CoreException {
- return "BreakpointInputMemento"; //$NON-NLS-1$
- }
-
- @Override
- protected boolean supportsContextId(String id) {
- return IDebugUIConstants.ID_BREAKPOINT_VIEW.equals(id);
- }
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
+ *****************************************************************/
+package org.eclipse.debug.internal.ui.model.elements;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.ui.IDebugUIConstants;
+
+/**
+ * Breakpoint manager input memento provider.
+ *
+ * @since 3.6
+ */
+public class BreakpointManagerInputMementoProvider extends DebugElementMementoProvider {
+
+ @Override
+ protected String getElementName(Object element, IPresentationContext context) throws CoreException {
+ return "BreakpointInputMemento"; //$NON-NLS-1$
+ }
+
+ @Override
+ protected boolean supportsContextId(String id) {
+ return IDebugUIConstants.ID_BREAKPOINT_VIEW.equals(id);
+ }
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointMementoProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointMementoProvider.java
index 33cf6ce57..98b6ca432 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointMementoProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/BreakpointMementoProvider.java
@@ -1,90 +1,90 @@
-/*******************************************************************************
- * Copyright (c) 2009 Freescale Semiconductor and others.
+/*******************************************************************************
+ * Copyright (c) 2009 Freescale Semiconductor 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
+ * 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:
- * 2009 Freescale - initial API and implementation (Bug 238956)
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.model.elements;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.debug.core.model.IBreakpoint;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.ui.IMemento;
-
-/**
- * Memento provider for breakpoints
- *
- * @since 3.6
- */
-public class BreakpointMementoProvider extends ElementMementoProvider {
-
- /**
- * Marker ID. Stored as string in order to support the full range of the long type.
- */
- private static final String MARKER_ID = "MARKER_ID"; //$NON-NLS-1$
-
- /**
- * Full path from the workspace to the resource referred to by the breakpoint marker.
- *
- * Stored as String.
- */
- private static final String RESOURCE_PATH = "RESOURCE_PATH"; //$NON-NLS-1$
-
- protected boolean supportsContextId(String id) {
- return IDebugUIConstants.ID_BREAKPOINT_VIEW.equals(id);
- }
-
- @Override
- protected boolean encodeElement(Object element, IMemento memento, IPresentationContext context) throws CoreException {
- if (element instanceof IBreakpoint) {
-
- IMarker marker = ((IBreakpoint)element).getMarker();
- if (marker != null) {
-
- long markerId = marker.getId();
- memento.putString(MARKER_ID, Long.toString(markerId));
-
- IPath fullPath = marker.getResource().getFullPath();
- String path = fullPath.toString();
- memento.putString(RESOURCE_PATH, path);
- return true;
- }
- }
-
- return false;
- }
-
- @Override
- protected boolean isEqual(Object element, IMemento memento, IPresentationContext context) throws CoreException {
- if (element instanceof IBreakpoint) {
- IBreakpoint breakpoint =(IBreakpoint)element;
- IMarker marker = breakpoint.getMarker();
-
- long markerId = marker.getId();
- String mementoMarkerId = memento.getString(MARKER_ID);
- if (!Long.toString(markerId).equals(mementoMarkerId)) {
- return false;
- }
-
- IPath fullPath = marker.getResource().getFullPath();
- String path = fullPath.toString();
- String mementoPath = memento.getString(RESOURCE_PATH);
- if (!path.equals(mementoPath)) {
- return false;
- }
- return true;
- }
- return false;
- }
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * 2009 Freescale - initial API and implementation (Bug 238956)
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.model.elements;
+
+import org.eclipse.core.resources.IMarker;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.debug.core.model.IBreakpoint;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.ui.IDebugUIConstants;
+import org.eclipse.ui.IMemento;
+
+/**
+ * Memento provider for breakpoints
+ *
+ * @since 3.6
+ */
+public class BreakpointMementoProvider extends ElementMementoProvider {
+
+ /**
+ * Marker ID. Stored as string in order to support the full range of the long type.
+ */
+ private static final String MARKER_ID = "MARKER_ID"; //$NON-NLS-1$
+
+ /**
+ * Full path from the workspace to the resource referred to by the breakpoint marker.
+ *
+ * Stored as String.
+ */
+ private static final String RESOURCE_PATH = "RESOURCE_PATH"; //$NON-NLS-1$
+
+ protected boolean supportsContextId(String id) {
+ return IDebugUIConstants.ID_BREAKPOINT_VIEW.equals(id);
+ }
+
+ @Override
+ protected boolean encodeElement(Object element, IMemento memento, IPresentationContext context) throws CoreException {
+ if (element instanceof IBreakpoint) {
+
+ IMarker marker = ((IBreakpoint)element).getMarker();
+ if (marker != null) {
+
+ long markerId = marker.getId();
+ memento.putString(MARKER_ID, Long.toString(markerId));
+
+ IPath fullPath = marker.getResource().getFullPath();
+ String path = fullPath.toString();
+ memento.putString(RESOURCE_PATH, path);
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ @Override
+ protected boolean isEqual(Object element, IMemento memento, IPresentationContext context) throws CoreException {
+ if (element instanceof IBreakpoint) {
+ IBreakpoint breakpoint =(IBreakpoint)element;
+ IMarker marker = breakpoint.getMarker();
+
+ long markerId = marker.getId();
+ String mementoMarkerId = memento.getString(MARKER_ID);
+ if (!Long.toString(markerId).equals(mementoMarkerId)) {
+ return false;
+ }
+
+ IPath fullPath = marker.getResource().getFullPath();
+ String path = fullPath.toString();
+ String mementoPath = memento.getString(RESOURCE_PATH);
+ if (!path.equals(mementoPath)) {
+ return false;
+ }
+ return true;
+ }
+ return false;
+ }
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/ProcessContentProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/ProcessContentProvider.java
index 84ab157b6..59736ee11 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/ProcessContentProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/model/elements/ProcessContentProvider.java
@@ -1,44 +1,44 @@
-/*******************************************************************************
- * Copyright (c) 2010 Wind River Systems and others.
+/*******************************************************************************
+ * Copyright (c) 2010 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
+ * 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
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.model.elements;
-
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IViewerUpdate;
-import org.eclipse.debug.ui.IDebugUIConstants;
-
-/**
- * Default content provider for process objects. Even though process objects
- * have no children by default, they still need a content provider to ensure
- * proper display (see bug
- *
- * @since 3.6
- */
-public class ProcessContentProvider extends ElementContentProvider {
-
- @Override
- protected Object[] getChildren(Object parent, int index, int length, IPresentationContext context, IViewerUpdate monitor) {
- return EMPTY;
- }
-
- @Override
- protected int getChildCount(Object element, IPresentationContext context, IViewerUpdate monitor) {
- return 0;
- }
-
- @Override
- protected boolean supportsContextId(String id) {
- return IDebugUIConstants.ID_DEBUG_VIEW.equals(id);
- }
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Wind River Systems - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.model.elements;
+
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IViewerUpdate;
+import org.eclipse.debug.ui.IDebugUIConstants;
+
+/**
+ * Default content provider for process objects. Even though process objects
+ * have no children by default, they still need a content provider to ensure
+ * proper display (see bug
+ *
+ * @since 3.6
+ */
+public class ProcessContentProvider extends ElementContentProvider {
+
+ @Override
+ protected Object[] getChildren(Object parent, int index, int length, IPresentationContext context, IViewerUpdate monitor) {
+ return EMPTY;
+ }
+
+ @Override
+ protected int getChildCount(Object element, IPresentationContext context, IViewerUpdate monitor) {
+ return 0;
+ }
+
+ @Override
+ protected boolean supportsContextId(String id) {
+ return IDebugUIConstants.ID_DEBUG_VIEW.equals(id);
+ }
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IColumnPresentation2.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IColumnPresentation2.java
index c74108a6a..fd045d05f 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IColumnPresentation2.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IColumnPresentation2.java
@@ -1,38 +1,38 @@
-/*******************************************************************************
- * Copyright (c) 2011 Texas Instruments and others.
+/*******************************************************************************
+ * Copyright (c) 2011 Texas Instruments 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
+ * 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:
- * Texas Instruments - initial API and implementation
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.viewers.model.provisional;
-
-/**
- * Extension to allow column presentation to specify initial column sizes in a
- * TreeModelViewer.
- *
- * @since 3.7
- *
- * @see TreeModelViewer
- */
-public interface IColumnPresentation2 extends IColumnPresentation {
-
- /**
- * Returns the initial column width for the column with the given identifier.
- *
- * @param id a column identifier included in <code>getAvailableColumns()</code>
- * @param treeWidgetWidth tree widget width
- * @param visibleColumnIds identifiers of visible columns
- * @return initial column width. Return -1 if this implementation does not decide the width
- * and let the caller to decide the width. The caller may make the initial width
- * be treeWidgetWidth / visibleColumnIds.length
- */
- int getInitialColumnWidth(String id, int treeWidgetWidth, String[] visibleColumnIds);
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Texas Instruments - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.viewers.model.provisional;
+
+/**
+ * Extension to allow column presentation to specify initial column sizes in a
+ * TreeModelViewer.
+ *
+ * @since 3.7
+ *
+ * @see TreeModelViewer
+ */
+public interface IColumnPresentation2 extends IColumnPresentation {
+
+ /**
+ * Returns the initial column width for the column with the given identifier.
+ *
+ * @param id a column identifier included in <code>getAvailableColumns()</code>
+ * @param treeWidgetWidth tree widget width
+ * @param visibleColumnIds identifiers of visible columns
+ * @return initial column width. Return -1 if this implementation does not decide the width
+ * and let the caller to decide the width. The caller may make the initial width
+ * be treeWidgetWidth / visibleColumnIds.length
+ */
+ int getInitialColumnWidth(String id, int treeWidgetWidth, String[] visibleColumnIds);
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IModelProxyFactory2.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IModelProxyFactory2.java
index 76d53b5e0..db0609bbc 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IModelProxyFactory2.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/model/provisional/IModelProxyFactory2.java
@@ -1,51 +1,51 @@
-/*******************************************************************************
- * Copyright (c) 2009 Freescale Semiconductor and others.
+/*******************************************************************************
+ * Copyright (c) 2009 Freescale Semiconductor 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
+ * 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:
- * Freescale Semiconductor - initial API and implementation � Bug 241336
- *******************************************************************************/
-package org.eclipse.debug.internal.ui.viewers.model.provisional;
-
-import org.eclipse.jface.viewers.TreePath;
-
-/**
- * A model proxy factory creates model proxies for elements based on
- * specific presentation contexts. A model proxy factory is provided for
- * a model element by registering a model proxy factory adapter for
- * an element.
- * <p>
- * This interface is an alternative to the {@link IModelProxyFactory}
- * interface. Unlike its predecessor <code>IModelProxyFactory2</code> allows
- * the full path to the tree element to be specified when creating an
- * <code>IModelProxy<code> instance. Using the full patch allows models to
- * provide proper model deltas even if the root element of this proxy is at
- * variable or unknown location in the viewer.
- * </p>
- * <p>
- * Clients may implement this interface.
- * </p>
- * @see IModelProxyFactory
- * @see IModelProxy
- * @see IModelDelta
- *
- * @since 3.6
- */
-public interface IModelProxyFactory2 {
- /**
- * Creates and returns a model proxy for the given element in the specified
- * context or <code>null</code> if none.
- *
- * @param input viewer input context
- * @param path to model element to create a model proxy for
- * @param context presentation context
- * @return model proxy or <code>null</code>
- */
- IModelProxy createTreeModelProxy(Object input, TreePath path, IPresentationContext context);
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Freescale Semiconductor - initial API and implementation � Bug 241336
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.viewers.model.provisional;
+
+import org.eclipse.jface.viewers.TreePath;
+
+/**
+ * A model proxy factory creates model proxies for elements based on
+ * specific presentation contexts. A model proxy factory is provided for
+ * a model element by registering a model proxy factory adapter for
+ * an element.
+ * <p>
+ * This interface is an alternative to the {@link IModelProxyFactory}
+ * interface. Unlike its predecessor <code>IModelProxyFactory2</code> allows
+ * the full path to the tree element to be specified when creating an
+ * <code>IModelProxy<code> instance. Using the full patch allows models to
+ * provide proper model deltas even if the root element of this proxy is at
+ * variable or unknown location in the viewer.
+ * </p>
+ * <p>
+ * Clients may implement this interface.
+ * </p>
+ * @see IModelProxyFactory
+ * @see IModelProxy
+ * @see IModelDelta
+ *
+ * @since 3.6
+ */
+public interface IModelProxyFactory2 {
+ /**
+ * Creates and returns a model proxy for the given element in the specified
+ * context or <code>null</code> if none.
+ *
+ * @param input viewer input context
+ * @param path to model element to create a model proxy for
+ * @param context presentation context
+ * @return model proxy or <code>null</code>
+ */
+ IModelProxy createTreeModelProxy(Object input, TreePath path, IPresentationContext context);
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointContainerProxy.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointContainerProxy.java
index 6bb79967a..ec9e20a17 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointContainerProxy.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointContainerProxy.java
@@ -1,58 +1,58 @@
-/*****************************************************************
- * Copyright (c) 2009 Texas Instruments and others
+/*****************************************************************
+ * Copyright (c) 2009 Texas Instruments 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
+ * 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:
- * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
- *****************************************************************/
-package org.eclipse.debug.internal.ui.viewers.update;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.model.IBreakpoint;
-import org.eclipse.debug.internal.ui.breakpoints.provisional.IBreakpointContainer;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.ICheckboxModelProxy;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.internal.ui.viewers.provisional.AbstractModelProxy;
-import org.eclipse.jface.viewers.TreePath;
-
-/**
- * Breakpoint container model proxy.
- *
- * @since 3.6
- */
-public class BreakpointContainerProxy extends AbstractModelProxy implements ICheckboxModelProxy {
-
- /**
- * The breakpoint container
- */
- private IBreakpointContainer fContainer;
-
- /**
- * Constructor.
- *
- * @param container the breakpoint container.
- */
- public BreakpointContainerProxy(IBreakpointContainer container) {
- fContainer = container;
- }
-
- @Override
- public boolean setChecked(IPresentationContext context, Object viewerInput, TreePath path, boolean checked) {
- boolean atLeastOne = false;
- IBreakpoint[] breakpoints = fContainer.getBreakpoints();
- for (int i = 0; i < breakpoints.length; ++i) {
- try {
- breakpoints[i].setEnabled(checked);
- atLeastOne = true;
- } catch (CoreException e) {}
- }
- return atLeastOne;
- }
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
+ *****************************************************************/
+package org.eclipse.debug.internal.ui.viewers.update;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.debug.core.model.IBreakpoint;
+import org.eclipse.debug.internal.ui.breakpoints.provisional.IBreakpointContainer;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.ICheckboxModelProxy;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.internal.ui.viewers.provisional.AbstractModelProxy;
+import org.eclipse.jface.viewers.TreePath;
+
+/**
+ * Breakpoint container model proxy.
+ *
+ * @since 3.6
+ */
+public class BreakpointContainerProxy extends AbstractModelProxy implements ICheckboxModelProxy {
+
+ /**
+ * The breakpoint container
+ */
+ private IBreakpointContainer fContainer;
+
+ /**
+ * Constructor.
+ *
+ * @param container the breakpoint container.
+ */
+ public BreakpointContainerProxy(IBreakpointContainer container) {
+ fContainer = container;
+ }
+
+ @Override
+ public boolean setChecked(IPresentationContext context, Object viewerInput, TreePath path, boolean checked) {
+ boolean atLeastOne = false;
+ IBreakpoint[] breakpoints = fContainer.getBreakpoints();
+ for (int i = 0; i < breakpoints.length; ++i) {
+ try {
+ breakpoints[i].setEnabled(checked);
+ atLeastOne = true;
+ } catch (CoreException e) {}
+ }
+ return atLeastOne;
+ }
+
+}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointProxy.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointProxy.java
index e62501e68..afa8a0d37 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointProxy.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/viewers/update/BreakpointProxy.java
@@ -1,54 +1,54 @@
-/*****************************************************************
- * Copyright (c) 2009 Texas Instruments and others
+/*****************************************************************
+ * Copyright (c) 2009 Texas Instruments 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
+ * 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:
- * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
- *****************************************************************/
-package org.eclipse.debug.internal.ui.viewers.update;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.model.IBreakpoint;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.ICheckboxModelProxy;
-import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
-import org.eclipse.debug.internal.ui.viewers.provisional.AbstractModelProxy;
-import org.eclipse.jface.viewers.TreePath;
-
-/**
- * Breakpoint model proxy.
- *
- * @since 3.6
- */
-public class BreakpointProxy extends AbstractModelProxy implements ICheckboxModelProxy {
-
- /**
- * Breakpoint object
- */
- protected IBreakpoint fBreakpoint;
-
- /**
- * Constructor.
- *
- * @param breakpoint the breakpoint for this model proxy
- */
- public BreakpointProxy(IBreakpoint breakpoint) {
- fBreakpoint = breakpoint;
- }
-
- @Override
- public boolean setChecked(IPresentationContext context, Object viewerInput, TreePath path, boolean checked) {
- try {
- fBreakpoint.setEnabled(checked);
- return fBreakpoint.isEnabled() == checked;
- } catch (CoreException e) {
- return false;
- }
- }
-
-}
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ * Contributors:
+ * Patrick Chuong (Texas Instruments) - Initial API and implementation (Bug 238956)
+ *****************************************************************/
+package org.eclipse.debug.internal.ui.viewers.update;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.debug.core.model.IBreakpoint;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.ICheckboxModelProxy;
+import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationContext;
+import org.eclipse.debug.internal.ui.viewers.provisional.AbstractModelProxy;
+import org.eclipse.jface.viewers.TreePath;
+
+/**
+ * Breakpoint model proxy.
+ *
+ * @since 3.6
+ */
+public class BreakpointProxy extends AbstractModelProxy implements ICheckboxModelProxy {
+
+ /**
+ * Breakpoint object
+ */
+ protected IBreakpoint fBreakpoint;
+
+ /**
+ * Constructor.
+ *
+ * @param breakpoint the breakpoint for this model proxy
+ */
+ public BreakpointProxy(IBreakpoint breakpoint) {
+ fBreakpoint = breakpoint;
+ }
+
+ @Override
+ public boolean setChecked(IPresentationContext context, Object viewerInput, TreePath path, boolean checked) {
+ try {
+ fBreakpoint.setEnabled(checked);
+ return fBreakpoint.isEnabled() == checked;
+ } catch (CoreException e) {
+ return false;
+ }
+ }
+
+}

Back to the top