/** * @param entries the extended acl entries * @return a list of the proto representation of the named group actions */ public static List<Acl.NamedAclActions> getNamedGroupsProto(ExtendedACLEntries entries) { List<Acl.NamedAclActions> actions = new ArrayList<>(entries.getNamedGroupActions().size()); for (Map.Entry<String, AclActions> kv : entries.getNamedGroupActions().entrySet()) { Acl.NamedAclActions namedActions = Acl.NamedAclActions.newBuilder() .setName(kv.getKey()) .setActions(toProto(kv.getValue())) .build(); actions.add(namedActions); } return actions; } }