void (CompletionParameters params, final GroovyCompletionConsumer result) { for (final TypeConstraint info : getExpectedTypeInfos(params)) { Consumer<LookupElement> consumer = result::consume; PsiType type = info.getType(); PsiType defType = info.getDefaultType(); boolean searchInheritors = params.getInvocationCount() > 1; if (type instanceof PsiClassType) { new GroovyMembersGetter((PsiClassType)type, params).processMembers(searchInheritors, consumer); } if (!defType.equals(type) && defType instanceof PsiClassType) { new GroovyMembersGetter((PsiClassType)defType, params).processMembers(searchInheritors, consumer); } } }