protected class BasicRefactoringTool.ClassNameRenamer extends BasicRefactoringTool.AbstractRenamer
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
newClassName
The current name of the class to rename.
|
protected java.lang.String |
oldClassName
The new name of the class.
|
textEdits| Constructor and Description |
|---|
BasicRefactoringTool.ClassNameRenamer(java.lang.String oldClassName,
java.lang.String newClassName)
Creates a new
ClassNameRenamer. |
| Modifier and Type | Method and Description |
|---|---|
void |
visit(CollectionValuedPathExpression expression)
Visits the
CollectionValuedPathExpression expression. |
void |
visit(ConstructorExpression expression)
Visits the
ConstructorExpression expression. |
protected void |
visit(Expression expression,
java.lang.String value,
int extraOffset)
Visits the given
and if its value is the same as the old class name or
if the value represents an inner class of that old class name, then the given StateObjectUpdater will be notified to replace the value. |
void |
visit(StateFieldPathExpression expression)
Visits the
StateFieldPathExpression expression. |
addTextEdit, addTextEdit, buildTextEdit, repositionvisitvisit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visitprotected final java.lang.String newClassName
protected final java.lang.String oldClassName
public BasicRefactoringTool.ClassNameRenamer(java.lang.String oldClassName,
java.lang.String newClassName)
ClassNameRenamer.oldClassName - The current name of the class to renamenewClassName - The new name of the classpublic void visit(CollectionValuedPathExpression expression)
CollectionValuedPathExpression expression.visit in interface ExpressionVisitorvisit in class AnonymousExpressionVisitorexpression - The Expression to visitpublic void visit(ConstructorExpression expression)
ConstructorExpression expression.visit in interface ExpressionVisitorvisit in class AnonymousExpressionVisitorexpression - The Expression to visitprotected void visit(Expression expression, java.lang.String value, int extraOffset)
and if its value is the same as the old class name or
if the value represents an inner class of that old class name, then the given StateObjectUpdater will be notified to replace the value.expression - The that is being visitedextraOffset - Additional offset that will be added to the given Expression's
offset, which is the length of the string representation of what is before itvalue - The value to check if it's the old class nameupdater - The StateObjectUpdater is notified when to replace the valuepublic void visit(StateFieldPathExpression expression)
StateFieldPathExpression expression.visit in interface ExpressionVisitorvisit in class AnonymousExpressionVisitorexpression - The Expression to visit