PsiMethodPattern (final boolean isConstructor) { return with(new PatternCondition<PsiMethod>("constructor") { @Override public boolean accepts(@NotNull final PsiMethod method, final ProcessingContext context) { return method.isConstructor() == isConstructor; } }); }