@Override
    public boolean isAvailableImpl(@NotNull Project project, Editor editor, PsiFile file) {
        if (!myToken.isValid()) {
            return false;
        }
        final PsiFile psiFile = myToken.getContainingFile();
        assert psiFile != null;
        final PsiElement context = psiFile.getContext();
        return context != null && context.isValid();
    }
@Override
    public boolean isAvailableImpl(@NotNull Project project, Editor editor, PsiFile file)