@Override @Nullable public SmartPointerElementInfo createElementInfo(@NotNull final PsiElement element, @NotNull PsiFile containingFile) { if (element instanceof ImplicitVariable) { return new ImplicitVariableInfo((ImplicitVariable) element, containingFile.getProject()); } return null; }
@Override public PsiElement restoreElement() { ImplicitVariable myVar = (ImplicitVariable)super.restoreElement(); PsiIdentifier psiIdentifier = myVar.getNameIdentifier(); if (psiIdentifier == null || psiIdentifier.isValid()) return myVar; return null; }
@Override public Segment getRange() { ImplicitVariable myVar = (ImplicitVariable)super.restoreElement(); PsiIdentifier psiIdentifier = myVar.getNameIdentifier(); if (psiIdentifier == null || !psiIdentifier.isValid()) return null; return psiIdentifier.getTextRange(); }
@Override @Nullable public SmartPointerElementInfo createElementInfo(@NotNull final PsiElement element) { if (element instanceof ImplicitVariable && element.isValid()) { return new ImplicitVariableInfo((ImplicitVariable) element, element.getProject()); } return null; }
@Override public void visitImplicitVariable(ImplicitVariable variable) { mVisitor.report("ImplicitVariable", variable.getText(), variable); super.visitLocalVariable(variable); }
private ImplicitVariableInfo(@NotNull ImplicitVariable var, @NotNull Project project) { super(project, var); }
public ImplicitVariableInfo(@NotNull ImplicitVariable var, @NotNull Project project) { super(project, var); }