Index: editor/tools/plugins/com.google.dart.engine.services/src/com/google/dart/engine/services/internal/correction/SelectionAnalyzer.java |
=================================================================== |
--- editor/tools/plugins/com.google.dart.engine.services/src/com/google/dart/engine/services/internal/correction/SelectionAnalyzer.java (revision 19029) |
+++ editor/tools/plugins/com.google.dart.engine.services/src/com/google/dart/engine/services/internal/correction/SelectionAnalyzer.java (working copy) |
@@ -13,6 +13,7 @@ |
*/ |
package com.google.dart.engine.services.internal.correction; |
+import com.google.common.annotations.VisibleForTesting; |
import com.google.common.collect.ImmutableList; |
import com.google.common.collect.Lists; |
import com.google.dart.engine.ast.ASTNode; |
@@ -89,6 +90,20 @@ |
} |
/** |
+ * Notifies that selection ends in given {@link ASTNode}. |
+ */ |
+ @VisibleForTesting |
+ public void handleSelectionEndsIn(ASTNode node) { |
+ } |
+ |
+ /** |
+ * Notifies that selection starts in given {@link ASTNode}. |
+ */ |
+ @VisibleForTesting |
+ public void handleSelectionStartsIn(ASTNode node) { |
+ } |
+ |
+ /** |
* @return <code>true</code> if there are {@link ASTNode} fully covered by the selection |
* {@link SourceRange}. |
*/ |
@@ -96,6 +111,14 @@ |
return selectedNodes != null && !selectedNodes.isEmpty(); |
} |
+ /** |
+ * Resets selected nodes. |
+ */ |
+ @VisibleForTesting |
+ public void reset() { |
+ selectedNodes = null; |
+ } |
+ |
@Override |
public Void visitNode(ASTNode node) { |
SourceRange nodeRange = rangeNode(node); |
@@ -141,25 +164,6 @@ |
} |
/** |
- * Notifies that selection ends in given {@link ASTNode}. |
- */ |
- protected void handleSelectionEndsIn(ASTNode node) { |
- } |
- |
- /** |
- * Notifies that selection starts in given {@link ASTNode}. |
- */ |
- protected void handleSelectionStartsIn(ASTNode node) { |
- } |
- |
- /** |
- * Resets selected nodes. |
- */ |
- protected void reset() { |
- selectedNodes = null; |
- } |
- |
- /** |
* @return <code>true</code> if there was no selected nodes yet. |
*/ |
private boolean isFirstNode() { |