|
Lines 12-20
Link Here
|
| 12 |
|
12 |
|
| 13 |
import org.eclipse.core.resources.IMarker; |
13 |
import org.eclipse.core.resources.IMarker; |
| 14 |
import org.eclipse.core.runtime.CoreException; |
14 |
import org.eclipse.core.runtime.CoreException; |
|
|
15 |
import org.eclipse.debug.core.DebugPlugin; |
| 16 |
import org.eclipse.debug.core.IBreakpointManager; |
| 17 |
import org.eclipse.debug.core.model.IBreakpoint; |
| 15 |
import org.eclipse.jdt.core.dom.AST; |
18 |
import org.eclipse.jdt.core.dom.AST; |
| 16 |
import org.eclipse.jdt.core.dom.ASTParser; |
19 |
import org.eclipse.jdt.core.dom.ASTParser; |
| 17 |
import org.eclipse.jdt.core.dom.CompilationUnit; |
20 |
import org.eclipse.jdt.core.dom.CompilationUnit; |
|
|
21 |
import org.eclipse.jdt.debug.core.IJavaPatternBreakpoint; |
| 22 |
import org.eclipse.jdt.debug.core.IJavaStratumLineBreakpoint; |
| 18 |
import org.eclipse.jdt.internal.debug.ui.actions.ValidBreakpointLocationLocator; |
23 |
import org.eclipse.jdt.internal.debug.ui.actions.ValidBreakpointLocationLocator; |
| 19 |
import org.eclipse.jface.text.BadLocationException; |
24 |
import org.eclipse.jface.text.BadLocationException; |
| 20 |
import org.eclipse.jface.text.IDocument; |
25 |
import org.eclipse.jface.text.IDocument; |
|
Lines 68-73
Link Here
|
| 68 |
if(position.isDeleted()) { |
73 |
if(position.isDeleted()) { |
| 69 |
return false; |
74 |
return false; |
| 70 |
} |
75 |
} |
|
|
76 |
IBreakpointManager manager = DebugPlugin.getDefault().getBreakpointManager(); |
| 77 |
IBreakpoint breakpoint = manager.getBreakpoint(marker); |
| 78 |
if (breakpoint instanceof IJavaStratumLineBreakpoint || breakpoint instanceof IJavaPatternBreakpoint) { |
| 79 |
return true; |
| 80 |
} |
| 71 |
ASTParser parser = ASTParser.newParser(AST.JLS3); |
81 |
ASTParser parser = ASTParser.newParser(AST.JLS3); |
| 72 |
parser.setSource(document.get().toCharArray()); |
82 |
parser.setSource(document.get().toCharArray()); |
| 73 |
CompilationUnit unit = (CompilationUnit) parser.createAST(null); |
83 |
CompilationUnit unit = (CompilationUnit) parser.createAST(null); |