@Override
    @Nullable
    public String getName() {
      final PsiPatternVariable variable = JavaPsiPatternUtil.getPatternVariable(pattern);
      return variable != null ? variable.getName() : null;
    }
@Override
    @Nullable
    public String getName()