@Override protected boolean createReturnFlowInfo(ReturnStatement node) { // Make sure that the whole return statement is selected or located before the selection. return node.getStartPosition() + node.getLength() <= fSelection.getExclusiveEnd(); } protected ASTNode getLoopNode() {
@Override protected boolean createReturnFlowInfo(ReturnStatement node) { // Make sure that the whole return statement is selected or located before the selection. return node.getStartPosition() + node.getLength() <= fSelection.getExclusiveEnd(); }
protected boolean createReturnFlowInfo(ReturnStatement node) { // Make sure that the whole return statement is selected or located before the selection. return node.getStartPosition() + node.getLength() <= fSelection.getExclusiveEnd(); } protected ASTNode getLoopNode() {
@Override protected boolean createReturnFlowInfo(ReturnStatement node) { // Make sure that the whole return statement is selected or located before the selection. return node.getStartPosition() + node.getLength() <= fSelection.getExclusiveEnd(); } protected ASTNode getLoopNode() {
private Selection adjustSelection(char[] characters, Selection selection, int end) { int newEnd= selection.getInclusiveEnd(); for(int i= selection.getExclusiveEnd(); i <= end; i++) { char ch= characters[i]; if (ch != '\n' && ch != '\r') break; newEnd++; } return Selection.createFromStartEnd(selection.getOffset(), newEnd); }
private Selection adjustSelection(char[] characters, Selection selection, int end) { int newEnd= selection.getInclusiveEnd(); for(int i= selection.getExclusiveEnd(); i <= end; i++) { char ch= characters[i]; if (ch != '\n' && ch != '\r') break; newEnd++; } return Selection.createFromStartEnd(selection.getOffset(), newEnd); }
private Selection adjustSelection(char[] characters, Selection selection, int end) { int newEnd= selection.getInclusiveEnd(); for(int i= selection.getExclusiveEnd(); i <= end; i++) { char ch= characters[i]; if (ch != '\n' && ch != '\r') break; newEnd++; } return Selection.createFromStartEnd(selection.getOffset(), newEnd); }
public boolean visit(MethodDeclaration node) { Block body= node.getBody(); if (body == null) return false; Selection selection= getSelection(); int nodeStart= body.getStartPosition(); int nodeExclusiveEnd= nodeStart + body.getLength(); // if selection node inside of the method body ignore method if (!(nodeStart < selection.getOffset() && selection.getExclusiveEnd() < nodeExclusiveEnd)) return false; return super.visit(node); }
@Override public boolean visit(MethodDeclaration node) { Block body= node.getBody(); if (body == null) return false; Selection selection= getSelection(); int nodeStart= body.getStartPosition(); int nodeExclusiveEnd= nodeStart + body.getLength(); // if selection node inside of the method body ignore method if (!(nodeStart < selection.getOffset() && selection.getExclusiveEnd() < nodeExclusiveEnd)) return false; return super.visit(node); }
@Override public boolean visit(MethodDeclaration node) { Block body= node.getBody(); if (body == null) return false; Selection selection= getSelection(); int nodeStart= body.getStartPosition(); int nodeExclusiveEnd= nodeStart + body.getLength(); // if selection node inside of the method body ignore method if (!(nodeStart < selection.getOffset() && selection.getExclusiveEnd() < nodeExclusiveEnd)) return false; return super.visit(node); }
@Override public boolean visit(MethodDeclaration node) { Block body = node.getBody(); if (body == null) { return false; } Selection selection = getSelection(); int nodeStart = body.getStartPosition(); int nodeExclusiveEnd = nodeStart + body.getLength(); // if selection node inside of the method body ignore method if (!(nodeStart < selection.getOffset() && selection.getExclusiveEnd() < nodeExclusiveEnd)) { return false; } return super.visit(node); }
Selection selection= getSelection(); int selectionStart= selection.getOffset(); int selectionExclusiveEnd= selection.getExclusiveEnd(); int lambdaStart= node.getStartPosition(); int lambdaExclusiveEnd= lambdaStart + node.getLength();
Selection selection = getSelection(); int selectionStart = selection.getOffset(); int selectionExclusiveEnd = selection.getExclusiveEnd(); int lambdaStart = node.getStartPosition(); int lambdaExclusiveEnd = lambdaStart + node.getLength();
Selection selection= getSelection(); int selectionStart= selection.getOffset(); int selectionExclusiveEnd= selection.getExclusiveEnd(); int lambdaStart= node.getStartPosition(); int lambdaExclusiveEnd= lambdaStart + node.getLength();