@Override
  public boolean isValidInContext(PsiElement element) {
    if (element instanceof PsiMethod && !element.isPhysical()) {
      return false;
    }
    else {
      return super.isValidInContext(element);
    }
  }
@Override
  public boolean isValidInContext(PsiElement element)