static @NonNull Permission allOf(final @NonNull Collection<@NonNull Permission> permissions) {
        final Set<Permission> objects = new HashSet<>();
        for (final Permission permission : permissions) {
            if (permission instanceof AndPermission) {
                objects.addAll(permission.permissions());
            } else {
                objects.add(permission);
            }
        }
        return new AndPermission(objects);
    }
Creates a new AND permission that evaluates to {@code true} if all the given {@code permissions} evaluate to {@code true}.

@param permissions permissions to join
@return the permission
cloud-core/src/main/java/org/incendo/cloud/permission/Permission.java