X-Git-Url: http://git.phpeclipse.com diff --git a/net.sourceforge.phpeclipse.debug.core/src/net/sourceforge/phpdt/internal/debug/core/breakpoints/PHPLineBreakpoint.java b/net.sourceforge.phpeclipse.debug.core/src/net/sourceforge/phpdt/internal/debug/core/breakpoints/PHPLineBreakpoint.java index 75a3c1f..804b2d8 100644 --- a/net.sourceforge.phpeclipse.debug.core/src/net/sourceforge/phpdt/internal/debug/core/breakpoints/PHPLineBreakpoint.java +++ b/net.sourceforge.phpeclipse.debug.core/src/net/sourceforge/phpdt/internal/debug/core/breakpoints/PHPLineBreakpoint.java @@ -34,6 +34,11 @@ public class PHPLineBreakpoint extends PHPBreakpoint implements IBreakpoint, ILi public PHPLineBreakpoint(IResource resource, int lineNumber, int charStart, int charEnd, int hitCount, boolean add, Map attributes) throws DebugException { this(resource, lineNumber, charStart, charEnd, hitCount, add, attributes, PHP_LINE_BREAKPOINT); } + + public PHPLineBreakpoint(IResource resource, int lineNumber, int hitCount, boolean add, Map attributes) throws DebugException { + this(resource, lineNumber, -1, -1, hitCount, add, attributes, PHP_LINE_BREAKPOINT); + } + protected PHPLineBreakpoint(final IResource resource, final int lineNumber, final int charStart, final int charEnd, final int hitCount, final boolean add, final Map attributes, final String markerType) throws DebugException { IWorkspaceRunnable wr= new IWorkspaceRunnable() { @@ -54,13 +59,17 @@ public class PHPLineBreakpoint extends PHPBreakpoint implements IBreakpoint, ILi }; run(wr); } + public void addLineBreakpointAttributes(Map attributes, String modelIdentifier, boolean enabled, int lineNumber, int charStart, int charEnd) { attributes.put(IBreakpoint.ID, modelIdentifier); attributes.put(IBreakpoint.ENABLED, new Boolean(enabled)); attributes.put(IMarker.LINE_NUMBER, new Integer(lineNumber)); - attributes.put(IMarker.CHAR_START, new Integer(charStart)); - attributes.put(IMarker.CHAR_END, new Integer(charEnd)); + if (charStart!=-1) + { + attributes.put(IMarker.CHAR_START, new Integer(charStart)); + attributes.put(IMarker.CHAR_END, new Integer(charEnd)); + } attributes.put(TYPE_NAME, "typeName"); }