// collect group struct entries / if any exist
Map groupMembership = new HashMap();
if (_groupsRootDoc != null) {
WGStructEntryList groupStructEntries = null;
WGContent rootContent = db.getContentByName(_groupsRootDoc);
if (rootContent != null) {
groupStructEntries = rootContent.getStructEntry().getChildEntries();
}
if (groupStructEntries == null) {
WGArea area = db.getArea(_groupsRootDoc);
if (area != null) {
groupStructEntries = area.getRootEntries();
}
}
if (groupStructEntries == null) {
throw new WGException("Root doc name '" + _groupsRootDoc + "' is neither the unique name of a content nor an area name. Please check if the default language " + db.getDefaultLanguage() + " of this database matches the language of group documents.");
}
// Recurse through group docs
Iterator structsIt = groupStructEntries.iterator();
while (structsIt.hasNext()) {
recurseGroupDocuments((WGStructEntry) structsIt.next(), groupMembership, newGroupInformation);
}
}
// Collect user struct entries {
WGStructEntryList structEntries = null;
WGContent rootContent = db.getContentByName(_userRootDoc);
if (rootContent != null) {
structEntries = rootContent.getStructEntry().getChildEntries();
}
if (structEntries == null) {
WGArea area = db.getArea(_userRootDoc);
if (area != null) {