boolean (@NotNull PsiMethod method) { final String methodName = method.getName(); final Pattern methodNamePattern = getMethodNamePattern(); if ((methodNamePattern != null) && methodNamePattern.matcher(methodName).matches()) { return true; } final PsiType returnType = method.getReturnType(); if (returnType == null) { return false; } final Pattern patternTypePattern = getMethodTypePattern(); final String methodType = returnType.getCanonicalText(); return (patternTypePattern != null) && methodTypePattern.matcher(methodType).matches(); }