@Override
  public boolean isAcceptable(Object element, PsiElement context) {
    if (!(element instanceof PsiModifierListOwner)) return false;

    PsiModifierList list = ((PsiModifierListOwner)element).getModifierList();
    if (list != null) {
      for (ModifierRestriction psiModifier : myModifierRestrictions) {
        boolean shouldHave = psiModifier.isSet;
        if (shouldHave != list.hasModifierProperty(psiModifier.modifierName)) {
          return false;
        }
      }
    }

    return true;
  }
@Override
  public boolean isAcceptable(Object element, PsiElement context)