CompletionResultSet (@NotNull CompletionResultSet result, @NotNull String prefix) { CompletionResultSet resultWithMatcher = result.withPrefixMatcher(new PlainPrefixMatcher(prefix)); if (!myCaseSensitive) resultWithMatcher = resultWithMatcher.caseInsensitive(); return resultWithMatcher; }