From: fvicente Date: Wed, 30 Jul 2003 01:36:38 +0000 (+0000) Subject: First submit for debug plugin X-Git-Url: http://git.phpeclipse.com First submit for debug plugin --- diff --git a/net.sourceforge.phpeclipse.debug.ui/.classpath b/net.sourceforge.phpeclipse.debug.ui/.classpath index bc6db00..b8be25f 100644 --- a/net.sourceforge.phpeclipse.debug.ui/.classpath +++ b/net.sourceforge.phpeclipse.debug.ui/.classpath @@ -35,6 +35,7 @@ - + + diff --git a/net.sourceforge.phpeclipse.debug.ui/plugin.xml b/net.sourceforge.phpeclipse.debug.ui/plugin.xml index afc5472..3337c36 100644 --- a/net.sourceforge.phpeclipse.debug.ui/plugin.xml +++ b/net.sourceforge.phpeclipse.debug.ui/plugin.xml @@ -17,12 +17,12 @@ + - - + + + + + + + + + + + + + + + + - + + + + + diff --git a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugModelPresentation.java b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugModelPresentation.java new file mode 100644 index 0000000..bce950a --- /dev/null +++ b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugModelPresentation.java @@ -0,0 +1,200 @@ +/********************************************************************** +Copyright (c) 2000, 2002 IBM Corp. and others. +All rights reserved. This program and the accompanying materials +are made available under the terms of the Common Public License v1.0 +which accompanies this distribution, and is available at +http://www.eclipse.org/legal/cpl-v10.html + +Contributors: + IBM Corporation - Initial implementation + Vicente Fernando - www.alfersoft.com.ar +**********************************************************************/ +package net.sourceforge.phpdt.internal.debug.ui; + +import java.util.HashMap; + +import net.sourceforge.phpdt.internal.debug.ui.PHPDebugUiPlugin; +import net.sourceforge.phpdt.internal.debug.core.breakpoints.PHPLineBreakpoint; +import net.sourceforge.phpdt.internal.debug.core.model.IPHPDebugTarget; +import net.sourceforge.phpdt.internal.debug.core.model.PHPStackFrame; +import net.sourceforge.phpdt.internal.debug.core.model.PHPThread; +import net.sourceforge.phpdt.internal.debug.core.model.PHPVariable; +import net.sourceforge.phpdt.internal.debug.core.model.PHPValue; +import org.eclipse.core.resources.IFile; +import org.eclipse.core.resources.IMarker; +import org.eclipse.core.runtime.CoreException; +import org.eclipse.debug.core.DebugPlugin; +import org.eclipse.debug.core.model.IValue; +import org.eclipse.debug.core.model.IBreakpoint; +import org.eclipse.debug.ui.IDebugModelPresentation; +import org.eclipse.debug.ui.IValueDetailListener; +import org.eclipse.debug.ui.DebugUITools; +import org.eclipse.debug.ui.IDebugUIConstants; +import org.eclipse.jface.viewers.LabelProvider; +import org.eclipse.swt.graphics.Image; +import org.eclipse.ui.IEditorDescriptor; +import org.eclipse.ui.IEditorInput; +import org.eclipse.ui.IEditorRegistry; +import org.eclipse.ui.PlatformUI; +import org.eclipse.ui.part.FileEditorInput; + +/** + * @see IDebugModelPresentation + */ +public class PHPDebugModelPresentation extends LabelProvider implements IDebugModelPresentation { + + protected HashMap fAttributes= new HashMap(3); + + public PHPDebugModelPresentation() { + super(); + } + /** + * @see IDebugModelPresentation#getEditorId(IEditorInput, Object) + */ + public String getEditorId(IEditorInput input, Object inputObject) { + IEditorRegistry registry= PlatformUI.getWorkbench().getEditorRegistry(); + IEditorDescriptor descriptor= registry.getDefaultEditor(input.getName()); + if (descriptor != null) + return descriptor.getId(); + + return null; + } + /** + * @see IDebugModelPresentation#setAttribute(String, Object) + */ + public void setAttribute(String id, Object value) { + if (value == null) { + return; + } + fAttributes.put(id, value); + } + + /** + * @see IDebugModelPresentation#getEditorInput(Object) + */ + public IEditorInput getEditorInput(Object item) { + + if (item instanceof PHPLineBreakpoint) { + IBreakpoint bp= (IBreakpoint)item; + IMarker ma= bp.getMarker(); + IFile eclipseFile = PHPDebugUiPlugin.getWorkspace().getRoot().getFileForLocation(ma.getResource().getLocation()); + if (eclipseFile == null) { + return null; + } + return new FileEditorInput(eclipseFile); + } + return null; + } + + /** + * @see IDebugModelPresentation#getImage(Object) + */ + public Image getImage(Object element) { + if (element instanceof PHPLineBreakpoint) { + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_BREAKPOINT); + } else if (element instanceof IMarker) { + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_BREAKPOINT); + } else if (element instanceof PHPStackFrame || element instanceof PHPThread || element instanceof IPHPDebugTarget) { + return getDebugElementImage(element); + } else if (element instanceof PHPVariable) { + return getVariableImage((PHPVariable)element); + } else if (element instanceof PHPValue) { + return getValueImage((PHPValue)element); + } + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_BREAKPOINT); + } + + private Image getVariableImage(PHPVariable phpVar) { + if (phpVar != null) { + if (phpVar.isLocal()) + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_VARIABLE); + if (phpVar.isHashValue()) + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_VARIABLE); + } + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_VARIABLE); + } + + private Image getValueImage(PHPValue phpVar) { + if (phpVar != null) { + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_VARIABLE); + } + return DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_VARIABLE); + } + + /** + * @see IDebugModelPresentation#getText(Object) + */ + public String getText(Object element) { + try { + if (element instanceof PHPLineBreakpoint) { + return getBreakpointText((IBreakpoint)element); + } else if (element instanceof PHPVariable) { + PHPVariable phpVar= (PHPVariable) element; + return phpVar.toString(); + } + } catch (CoreException e) { + return PHPDebugUiMessages.getString("PHPDebugModelPresentation."); //$NON-NLS-1$ + } + return null; + } + + /** + * @see IDebugModelPresentation#computeDetail(IValue, IValueDetailListener) + */ + public void computeDetail(IValue value, IValueDetailListener listener) { + return; + } + + protected IBreakpoint getBreakpoint(IMarker marker) { + return DebugPlugin.getDefault().getBreakpointManager().getBreakpoint(marker); + } + + protected String getBreakpointText(IBreakpoint breakpoint) throws CoreException { + if (breakpoint instanceof PHPLineBreakpoint) { + return getLineBreakpointText((PHPLineBreakpoint) breakpoint); + } + return ""; //$NON-NLS-1$ + } + + protected String getLineBreakpointText(PHPLineBreakpoint breakpoint) throws CoreException { + + StringBuffer label= new StringBuffer(); + + label.append(breakpoint.getMarker().getResource().getFullPath()); + label.append(" ["); //$NON-NLS-1$ + label.append(PHPDebugUiMessages.getString("PHPDebugModelPresentation.line")); //$NON-NLS-1$ + label.append(' '); + label.append(breakpoint.getLineNumber()); + label.append(']'); + + return label.toString(); + } + + /** + * Returns the image associated with the given element or null + * if none is defined. + */ + protected Image getDebugElementImage(Object element) { + Image image= null; + if (element instanceof PHPThread) { + PHPThread thread = (PHPThread)element; + if (thread.isSuspended()) { + image= DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_THREAD_SUSPENDED); + } else if (thread.isTerminated()) { + image= DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_THREAD_TERMINATED); + } else { + image= DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_THREAD_RUNNING); + } + } else if (element instanceof PHPStackFrame) { + image= DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_STACKFRAME); + } else if (element instanceof IPHPDebugTarget) { + IPHPDebugTarget debugTarget=(IPHPDebugTarget) element; + if (debugTarget.isTerminated()) { + image= DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_DEBUG_TARGET_TERMINATED); + } else { + image= DebugUITools.getImage(IDebugUIConstants.IMG_OBJS_DEBUG_TARGET); + } + } + return image; + } +} diff --git a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugUiMessages.properties b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugUiMessages.properties index ec9e132..fe37ee0 100644 --- a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugUiMessages.properties +++ b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPDebugUiMessages.properties @@ -50,3 +50,9 @@ PHPInterpreterPreferencePage.EditInterpreterDialog.addInterpreter.title=Add Inte PHPInterpreterPreferencePage.EditInterpreterDialog.editInterpreter.title=Edit Interpreter PHPBasePreferencePage.label=General Properties + +PHPManageBreakpointRulerAction.AddBreakpoint=Add Breakpoint +PHPManageBreakpointRulerAction.RemoveBreakpoint=Remove Breakpoint + +PHPDebugModelPresentation.= +PHPDebugModelPresentation.line=line: diff --git a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPSourceLocator.java b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPSourceLocator.java index fd31b85..8ff3848 100644 --- a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPSourceLocator.java +++ b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/PHPSourceLocator.java @@ -2,7 +2,7 @@ package net.sourceforge.phpdt.internal.debug.ui; import net.sourceforge.phpdt.internal.launching.PHPLaunchConfigurationAttribute; import net.sourceforge.phpeclipse.PHPeclipsePlugin; - +import net.sourceforge.phpdt.internal.debug.core.model.PHPStackFrame; import org.eclipse.core.resources.IFile; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IStatus; @@ -49,15 +49,14 @@ public class PHPSourceLocator implements IPersistableSourceLocator, ISourcePrese * @see org.eclipse.debug.core.model.ISourceLocator#getSourceElement(IStackFrame) */ public Object getSourceElement(IStackFrame stackFrame) { - return null; - //return ((PHPStackFrame) stackFrame).getFileName(); + return ((PHPStackFrame) stackFrame).getFileName(); } /** * @see org.eclipse.debug.ui.ISourcePresentation#getEditorId(IEditorInput, Object) */ public String getEditorId(IEditorInput input, Object element) { - return PlatformUI.getWorkbench().getEditorRegistry().getDefaultEditor((String) element).getId(); + return PlatformUI.getWorkbench().getEditorRegistry().getDefaultEditor((String)element).getId(); } /** diff --git a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/actions/PHPManageBreakpointRulerAction.java b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/actions/PHPManageBreakpointRulerAction.java new file mode 100644 index 0000000..c284e8e --- /dev/null +++ b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/actions/PHPManageBreakpointRulerAction.java @@ -0,0 +1,275 @@ +/********************************************************************** +Copyright (c) 2000, 2002 IBM Corp. and others. +All rights reserved. This program and the accompanying materials +are made available under the terms of the Common Public License v1.0 +which accompanies this distribution, and is available at +http://www.eclipse.org/legal/cpl-v10.html + +Contributors: + IBM Corporation - Initial implementation + Vicente Fernando - www.alfersoft.com.ar +**********************************************************************/ +package net.sourceforge.phpdt.internal.debug.ui.actions; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; + +import net.sourceforge.phpdt.debug.core.PHPDebugModel; +import net.sourceforge.phpdt.internal.debug.ui.PHPDebugUiMessages; +import org.eclipse.core.resources.IFile; +import org.eclipse.core.resources.IMarker; +import org.eclipse.core.resources.IResource; +import org.eclipse.core.resources.IWorkspaceRoot; +import org.eclipse.core.resources.ResourcesPlugin; +import org.eclipse.core.resources.IContainer; +import org.eclipse.core.runtime.CoreException; +import org.eclipse.debug.core.DebugException; +import org.eclipse.debug.core.DebugPlugin; +import org.eclipse.debug.core.IBreakpointManager; +import org.eclipse.debug.core.model.IBreakpoint; +import org.eclipse.jface.action.Action; +import org.eclipse.jface.text.BadLocationException; +import org.eclipse.jface.text.IDocument; +import org.eclipse.jface.text.IRegion; +import org.eclipse.jface.text.Position; +import org.eclipse.jface.text.source.IAnnotationModel; +import org.eclipse.jface.text.source.IVerticalRulerInfo; +import org.eclipse.ui.IEditorInput; +import org.eclipse.ui.IFileEditorInput; +import org.eclipse.ui.texteditor.AbstractMarkerAnnotationModel; +import org.eclipse.ui.texteditor.IDocumentProvider; +import org.eclipse.ui.texteditor.ITextEditor; +import org.eclipse.ui.texteditor.IUpdate; + +public class PHPManageBreakpointRulerAction extends Action implements IUpdate { + + private IVerticalRulerInfo fRuler; + private ITextEditor fTextEditor; + private String fMarkerType; + private List fMarkers; + + private String fAddLabel; + private String fRemoveLabel; + + public PHPManageBreakpointRulerAction(IVerticalRulerInfo ruler, ITextEditor editor) { + fRuler= ruler; + fTextEditor= editor; + fMarkerType= IBreakpoint.BREAKPOINT_MARKER; + fAddLabel= PHPDebugUiMessages.getString("PHPManageBreakpointRulerAction.AddBreakpoint"); //$NON-NLS-1$ + fRemoveLabel= PHPDebugUiMessages.getString("PHPManageBreakpointRulerAction.RemoveBreakpoint"); //$NON-NLS-1$ + } + + /** + * Returns the resource for which to create the marker, + * or null if there is no applicable resource. + * + * @return the resource for which to create the marker or null + */ + protected IResource getResource() { + IEditorInput input= fTextEditor.getEditorInput(); + + IResource resource= (IResource) input.getAdapter(IFile.class); + + if (resource == null) { + resource= (IResource) input.getAdapter(IResource.class); + } + + return resource; + } + + /** + * Checks whether a position includes the ruler's line of activity. + * + * @param position the position to be checked + * @param document the document the position refers to + * @return true if the line is included by the given position + */ + protected boolean includesRulerLine(Position position, IDocument document) { + + if (position != null) { + try { + int markerLine= document.getLineOfOffset(position.getOffset()); + int line= fRuler.getLineOfLastMouseButtonActivity(); + if (line == markerLine) { + return true; + } + } catch (BadLocationException x) { + } + } + + return false; + } + + /** + * Returns this action's vertical ruler info. + * + * @return this action's vertical ruler + */ + protected IVerticalRulerInfo getVerticalRulerInfo() { + return fRuler; + } + + /** + * Returns this action's editor. + * + * @return this action's editor + */ + protected ITextEditor getTextEditor() { + return fTextEditor; + } + + /** + * Returns the AbstractMarkerAnnotationModel of the editor's input. + * + * @return the marker annotation model + */ + protected AbstractMarkerAnnotationModel getAnnotationModel() { + IDocumentProvider provider= fTextEditor.getDocumentProvider(); + IAnnotationModel model= provider.getAnnotationModel(fTextEditor.getEditorInput()); + if (model instanceof AbstractMarkerAnnotationModel) { + return (AbstractMarkerAnnotationModel) model; + } + return null; + } + + /** + * Returns the IDocument of the editor's input. + * + * @return the document of the editor's input + */ + protected IDocument getDocument() { + IDocumentProvider provider= fTextEditor.getDocumentProvider(); + return provider.getDocument(fTextEditor.getEditorInput()); + } + + /** + * @see IUpdate#update() + */ + public void update() { + fMarkers= getMarkers(); + setText(fMarkers.isEmpty() ? fAddLabel : fRemoveLabel); + } + + /** + * @see Action#run() + */ + public void run() { + if (fMarkers.isEmpty()) { + addMarker(); + } else { + removeMarkers(fMarkers); + } + } + + protected List getMarkers() { + + List breakpoints= new ArrayList(); + + IResource resource= getResource(); + IDocument document= getDocument(); + AbstractMarkerAnnotationModel model= getAnnotationModel(); + + if (model != null) { + try { + + IMarker[] markers= null; + if (resource instanceof IFile) + markers= resource.findMarkers(IBreakpoint.BREAKPOINT_MARKER, true, IResource.DEPTH_INFINITE); + else { + IWorkspaceRoot root= ResourcesPlugin.getWorkspace().getRoot(); + markers= root.findMarkers(IBreakpoint.BREAKPOINT_MARKER, true, IResource.DEPTH_INFINITE); + } + + if (markers != null) { + IBreakpointManager breakpointManager= DebugPlugin.getDefault().getBreakpointManager(); + int iFe =0; + for (iFe= 0; iFe < markers.length; iFe++) { + IBreakpoint breakpoint= breakpointManager.getBreakpoint(markers[iFe]); + if (breakpoint != null && breakpointManager.isRegistered(breakpoint) && + includesRulerLine(model.getMarkerPosition(markers[iFe]), document)) + breakpoints.add(markers[iFe]); + } + } + } catch (CoreException x) { + System.out.println(x.getStatus()); +// JDIDebugUIPlugin.log(x.getStatus()); + } + } + return breakpoints; + } + + protected void addMarker() { + + //IResource resource= getResource(); + IEditorInput editorInput= getTextEditor().getEditorInput(); + IDocument document= getDocument(); + //IBreakpointManager breakpointManager= DebugPlugin.getDefault().getBreakpointManager(); + + int rulerLine= getVerticalRulerInfo().getLineOfLastMouseButtonActivity(); + // create the marker + try { + // Falta verificar si la ubicación del Breakpoint es válida + int lineNumber= rulerLine + 1; + + if (lineNumber > 0) { + if (!PHPDebugModel.lineBreakpointExists(lineNumber)) { + Map attributes = new HashMap(10); + IRegion line= document.getLineInformation(lineNumber - 1); + int start= line.getOffset(); + int lenline= line.getLength(); + //int end= start + ((lenline > 0)?lenline:0); + int end= start + lenline; + + //PHPDebugModel.createLineBreakpoint(getResource(), lineNumber, start, end, 0, true, attributes); + PHPDebugModel.createLineBreakpoint(((IFileEditorInput) editorInput).getFile(), lineNumber, start, end, 0, true, attributes); + + } + } + } catch (DebugException e) { + System.out.println("Error"); +// JDIDebugUIPlugin.errorDialog(ActionMessages.getString("ManageBreakpointRulerAction.error.adding.message1"), e); //$NON-NLS-1$ + } catch (CoreException e) { + System.out.println("Error"); +// JDIDebugUIPlugin.errorDialog(ActionMessages.getString("ManageBreakpointRulerAction.error.adding.message1"), e); //$NON-NLS-1$ + } catch (BadLocationException e) { + System.out.println("Error"); +// JDIDebugUIPlugin.errorDialog(ActionMessages.getString("ManageBreakpointRulerAction.error.adding.message1"), e); //$NON-NLS-1$ + } + } + + protected void removeMarkers(List markers) { + IBreakpointManager breakpointManager= DebugPlugin.getDefault().getBreakpointManager(); + try { + Iterator e= markers.iterator(); + while (e.hasNext()) { + IBreakpoint breakpoint= breakpointManager.getBreakpoint((IMarker) e.next()); + breakpointManager.removeBreakpoint(breakpoint, true); + } + } catch (CoreException e) { + } + } + + public IResource getUnderlyingResource(String fName) { + IResource parentResource = getResource(); //fParent.getUnderlyingResource(); + if (parentResource == null) { + return null; + } + int type = parentResource.getType(); + if (type == IResource.FOLDER || type == IResource.PROJECT) { + IContainer folder = (IContainer) parentResource; + IResource resource = folder.findMember(fName); + if (resource == null) { + //throw newNotPresentException(); + return null; + } else { + return resource; + } + } else { + return parentResource; + } + } + +} diff --git a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/actions/PHPManageBreakpointRulerActionDelegate.java b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/actions/PHPManageBreakpointRulerActionDelegate.java new file mode 100644 index 0000000..f374e92 --- /dev/null +++ b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/actions/PHPManageBreakpointRulerActionDelegate.java @@ -0,0 +1,27 @@ +/********************************************************************** +Copyright (c) 2000, 2002 IBM Corp. and others. +All rights reserved. This program and the accompanying materials +are made available under the terms of the Common Public License v1.0 +which accompanies this distribution, and is available at +http://www.eclipse.org/legal/cpl-v10.html + +Contributors: + IBM Corporation - Initial implementation + Vicente Fernando - www.alfersoft.com.ar +**********************************************************************/ +package net.sourceforge.phpdt.internal.debug.ui.actions; + +import org.eclipse.jface.action.IAction; +import org.eclipse.jface.text.source.IVerticalRulerInfo; +import org.eclipse.ui.texteditor.AbstractRulerActionDelegate; +import org.eclipse.ui.texteditor.ITextEditor; + +public class PHPManageBreakpointRulerActionDelegate extends AbstractRulerActionDelegate { + + /** + * @see AbstractRulerActionDelegate#createAction() + */ + protected IAction createAction(ITextEditor editor, IVerticalRulerInfo rulerInfo) { + return new PHPManageBreakpointRulerAction(rulerInfo, editor); + } +} diff --git a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/launcher/PHPArgumentsTab.java b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/launcher/PHPArgumentsTab.java index 7ba79ba..d96b9f6 100644 --- a/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/launcher/PHPArgumentsTab.java +++ b/net.sourceforge.phpeclipse.debug.ui/src/net/sourceforge/phpdt/internal/debug/ui/launcher/PHPArgumentsTab.java @@ -79,10 +79,10 @@ public class PHPArgumentsTab extends AbstractLaunchConfigurationTab { } public void setDefaults(ILaunchConfigurationWorkingCopy configuration) { - setUseDefaultWorkingDirectory(true); + //setUseDefaultWorkingDirectory(true); configuration.setAttribute(PHPLaunchConfigurationAttribute.WORKING_DIRECTORY, PHPDebugUiConstants.DEFAULT_WORKING_DIRECTORY); // set hidden attribute - //configuration.setAttribute(ILaunchConfiguration.ATTR_SOURCE_LOCATOR_ID, "net.sourceforge.phpdt.internal.debug.ui.PHPSourceLocator") ; + configuration.setAttribute(ILaunchConfiguration.ATTR_SOURCE_LOCATOR_ID, "net.sourceforge.phpdt.debug.ui.PHPSourceLocator") ; } public void initializeFrom(ILaunchConfiguration configuration) {