Get list of groups from group path.

@param groups Array of zero or more ancestor groups from root to parent.
@return List of HDF5 groups
517194
public List<String> getGroups(String... groups) {
        synchronized (Hdf5Archive.LOCK_OBJECT) {
            if (groups.length == 0)
                return getObjects(this.file, H5O_TYPE_GROUP);
            Group[] groupArray = openGroups(groups);
            List<String> ls = getObjects(groupArray[groupArray.length - 1], H5O_TYPE_GROUP);
            closeGroups(groupArray);
            return ls;
        }
    }
1012534
private Iterator<IEntityGroup> getMemberGroups() throws GroupsException {

        Set<IEntityGroup> rslt = new HashSet<>();
        for (IGroupMember child : getChildren()) {
            if (child.isGroup()) {
                rslt.add((IEntityGroup) child);
            }
        }

        return rslt.iterator();
    }
106783
public GroupResources groupResources() {
        if (groups.get() == null) {
            groups.compareAndSet(null, new GroupResourcesImpl(this));
        }
        return groups.get();
    }
1161536
public void setGroups(java.util.Collection<GroupSummary> groups) {
        if (groups == null) {
            this.groups = null;
            return;
        }

        this.groups = new java.util.ArrayList<GroupSummary>(groups);
    }
1038284
public List<Group> getGroupsInPathProfile(
        int profileId, int pathId) {
        ArrayList<Group> groupsInProfile = new ArrayList<Group>();
        ArrayList<Group> allGroups = new ArrayList<Group>(findAllGroups());
        int[] groupIds = Utils.arrayFromStringOfIntegers(getGroupIdsInPathProfile(profileId,
                                                                                  pathId));
        // get all the groups, then remove the ones != group ids, leaving us
        // with all the groups in the profile
        for (int j = 0; j < allGroups.size(); j++) {
            for (int i = 0; i < groupIds.length; i++) {
                if (allGroups.get(j).getId() == groupIds[i]) {
                    groupsInProfile.add(allGroups.get(j));
                }
            }
        }
        return groupsInProfile;
    }
548346
public void setGroups(java.util.Collection<GroupInformation> groups) {
        if (groups == null) {
            this.groups = null;
            return;
        }

        this.groups = new java.util.ArrayList<GroupInformation>(groups);
    }
1252989
@Override
    public Set<IEntityGroup> getParentGroups() throws GroupsException {

        final EntityIdentifier cacheKey = getUnderlyingEntityIdentifier();
        Element element = parentGroupsCache.get(cacheKey);

        if (element == null) {
            final Set<IEntityGroup> groups = buildParentGroupsSet();
            element = new Element(cacheKey, groups);
            parentGroupsCache.put(element);
        }

        @SuppressWarnings("unchecked")
        final Set<IEntityGroup> rslt = (Set<IEntityGroup>) element.getObjectValue();
        return rslt;
    }
853135
public List<String> findObjectsInGroup(String groupName) {
        if (getObjectGroups().containsKey(groupName)) {
            return getObjectGroups().get(groupName);
        } else {
            return Collections.emptyList();
        }
    }
306092
@Override
    public java.util.Iterator findMemberGroups(IEntityGroup group) throws GroupsException {
        String[] keys = findMemberGroupKeys(group); // No foreign groups here.
        List groups = new ArrayList(keys.length);
        for (int i = 0; i < keys.length; i++) {
            groups.add(find(keys[i]));
        }
        return groups.iterator();
    }
55705
protected List<CmsGroup> getGroups() throws CmsException {

        List<CmsGroup> groups = new ArrayList<CmsGroup>();
        if (getParamUser() != null) {
            groups.addAll(getCms().getGroupsOfUser(getParamUser(), false));
        } else {
            groups.addAll(OpenCms.getRoleManager().getManageableGroups(getCms(), "", true));
        }
        if (getParamFlags() != null) {
            int flags = Integer.parseInt(getParamFlags());
            CmsPrincipal.filterFlag(groups, flags);
        }
        if ((getParamOufqn() != null) && !getParamOufqn().equals("null")) {
            Iterator<CmsGroup> groupsIter = groups.iterator();
            while (groupsIter.hasNext()) {
                CmsGroup group = groupsIter.next();
                if (!group.getOuFqn().startsWith(getParamOufqn())) {
                    groupsIter.remove();
                }
            }
        }
        return groups;
    }
119494
@Override
    public List<T> getAll(final String... ids) {
        if (ids == null || ids.length == 0) {
            return Collections.<T> emptyList();
        }

        // delegate to internal method that partitions the list into smaller groups and aggregates
        // the result
        return getAll(Lists.newArrayList(ids));
    }
1229626
public Group getGroupByName(String name) {
        List<Group> groups = getGroupsByName(name, true);

        if (!groups.isEmpty()) {
            return groups.get(0);
        }

        return null;
    }
989786
function getAllEntries(groups) {
    return groups.reduce(function(current, group) {
        const theseEntries = group.getEntries();
        const subEntries = getAllEntries(group.getGroups());
        if (theseEntries.length > 0) {
            current = current.concat(theseEntries);
        }
        if (subEntries.length > 0) {
            current = current.concat(subEntries);
        }
        return current;
    }, []);
}
772061
public List<GROUP> getGroups(List<RESOURCE> resources) {

        List<RESOURCE> sortedResources = new ArrayList<RESOURCE>(resources);
        Collections.sort(sortedResources, new SortingComparator());
        Map<Long, Integer> daysMap = computeDaysForResources(sortedResources);
        Map<GroupAge, List<RESOURCE>> resourcesByAge = partitionPublishResourcesByAge(sortedResources, daysMap);
        List<List<RESOURCE>> youngGroups = partitionYoungResources(resourcesByAge.get(GroupAge.young));
        List<List<RESOURCE>> mediumGroups = partitionMediumResources(resourcesByAge.get(GroupAge.medium), daysMap);
        List<RESOURCE> oldGroup = resourcesByAge.get(GroupAge.old);
        List<GROUP> resultGroups = new ArrayList<GROUP>();
        for (List<RESOURCE> groupRes : youngGroups) {
            String name = getPublishGroupName(groupRes, GroupAge.young);
            resultGroups.add(createGroup(name, groupRes));
        }
        for (List<RESOURCE> groupRes : mediumGroups) {
            String name = getPublishGroupName(groupRes, GroupAge.medium);
            resultGroups.add(createGroup(name, groupRes));
        }
        if (!oldGroup.isEmpty()) {
            String oldName = getPublishGroupName(oldGroup, GroupAge.old);
            resultGroups.add(createGroup(oldName, oldGroup));
        }
        return resultGroups;
    }
748165
@Override
	public List<String> getJobGroups() throws SchedulerException {
		List<String> groups = scheduler.getJobGroupNames();
		Collections.sort(groups);
		return groups;
	}
339149
public static List<Group> filterLigands(List<Group> allGroups) {

		List<Group> groups = new ArrayList<Group>();
		for (Group g : allGroups) {

			if ( g.isPolymeric())
				continue;

			if (!g.isWater()) {
				groups.add(g);
			}
		}

		return groups;
	}
69128
public java.util.Iterator findParentGroups(IEntityGroup group) throws GroupsException {
        String memberKey = group.getLocalKey();
        String serviceName = group.getServiceName().toString();
        Integer type = EntityTypesLocator.getEntityTypes().getEntityIDFromType(group.getLeafType());
        return findParentGroupsForGroup(serviceName, memberKey, type.intValue());
    }