Experimenter e = iQuery.execute(new UserQ(new Parameters() .addId(experimenterId))); if (e == null) { throw new ApiUsageException("No such user: " + experimenterId); }  int count = e.sizeOfGroupExperimenterMap(); if (count < 1) { return new ExperimenterGroup[] {}; }  return (ExperimenterGroup[]) e.linkedExperimenterGroupList().toArray( new ExperimenterGroup[count]);
List<ExperimenterGroup> groups = iQuery.findAllByQuery("select g from ExperimenterGroup as g left " + "outer join g.groupExperimenterMap as map left outer " + "join map.child as e where e.id = :id", new Parameters().addId(experimenterId)); return (ExperimenterGroup[]) groups.toArray( new ExperimenterGroup[groups.size()]);
	public ExperimenterGroup[] containedGroups(Long experimenterId) {		Experimenter e = iQuery.execute(new UserQ(new Parameters()				.addId(experimenterId)));		if (e == null) {			throw new ApiUsageException("No such user: " + experimenterId);		}		int count = e.sizeOfGroupExperimenterMap();		if (count < 1) {			return new ExperimenterGroup[] {};		}		return (ExperimenterGroup[]) e.linkedExperimenterGroupList().toArray(				new ExperimenterGroup[count]);	}