Method rename

This commit is contained in:
Alexey Sedunov
2013-12-23 20:26:53 +04:00
parent fbb03afc0f
commit d00b17c621
4 changed files with 6 additions and 6 deletions
@@ -85,7 +85,7 @@ abstract class JetNamedDeclarationStub<T extends NamedStub> extends JetDeclarati
@NotNull
@Override
public SearchScope getUseScope() {
JetElement enclosingBlock = JetPsiUtil.getEnclosingBlockForLocalDeclaration(this);
JetElement enclosingBlock = JetPsiUtil.getEnclosingElementForLocalDeclaration(this);
if (enclosingBlock != null) {
return new LocalSearchScope(enclosingBlock);
}
@@ -1005,7 +1005,7 @@ public class JetPsiUtil {
}
@Nullable
public static JetElement getEnclosingBlockForLocalDeclaration(@Nullable JetNamedDeclaration declaration) {
public static JetElement getEnclosingElementForLocalDeclaration(@Nullable JetNamedDeclaration declaration) {
if (declaration instanceof JetTypeParameter || declaration instanceof JetParameter) {
declaration = PsiTreeUtil.getParentOfType(declaration, JetNamedDeclaration.class);
}
@@ -1021,7 +1021,7 @@ public class JetPsiUtil {
}
public static boolean isLocal(@NotNull JetNamedDeclaration declaration) {
return getEnclosingBlockForLocalDeclaration(declaration) != null;
return getEnclosingElementForLocalDeclaration(declaration) != null;
}
@Nullable
@@ -27,9 +27,9 @@ public abstract class KotlinCallTreeStructure extends HierarchyTreeStructure {
this.scopeType = scopeType;
}
protected static JetElement getEnclosingBlockForLocalDeclaration(PsiElement element) {
protected static JetElement getEnclosingElementForLocalDeclaration(PsiElement element) {
return element instanceof JetNamedDeclaration
? JetPsiUtil.getEnclosingBlockForLocalDeclaration((JetNamedDeclaration) element)
? JetPsiUtil.getEnclosingElementForLocalDeclaration((JetNamedDeclaration) element)
: null;
}
@@ -215,7 +215,7 @@ public abstract class KotlinCallerMethodsTreeStructure extends KotlinCallTreeStr
}
public static KotlinCallerMethodsTreeStructure newInstance(@NotNull Project project, @NotNull PsiElement element, String scopeType) {
JetElement codeBlockForLocalDeclaration = getEnclosingBlockForLocalDeclaration(element);
JetElement codeBlockForLocalDeclaration = getEnclosingElementForLocalDeclaration(element);
if (codeBlockForLocalDeclaration != null) return new WithLocalRoot(project, element, scopeType, codeBlockForLocalDeclaration);
PsiMethod representativeMethod = getRepresentativePsiMethod(element);