in src/main/java/org/apache/sling/testing/mock/jcr/MockUserManager.java [134:150]
Set<Authorizable> all(int searchType) throws RepositoryException { // NOSONAR
return authorizables.values().stream()
.filter(a -> {
boolean match;
if (PrincipalManager.SEARCH_TYPE_ALL == searchType) {
match = true;
} else if (PrincipalManager.SEARCH_TYPE_GROUP == searchType) {
match = a.isGroup();
} else if (PrincipalManager.SEARCH_TYPE_NOT_GROUP == searchType) {
match = !a.isGroup();
} else {
match = false;
}
return match;
})
.collect(Collectors.toSet());
}