public final ChaiUser getManager() throws ChaiOperationException, ChaiUnavailableException { final String mgrDN = this.readStringAttribute(ATTR_MANAGER); if (mgrDN == null) { return null; } return ChaiFactory.createChaiUser(mgrDN, this.getChaiProvider()); }
public final Set<ChaiGroup> getGroups() throws ChaiOperationException, ChaiUnavailableException { final Set<ChaiGroup> returnGroups = new HashSet<ChaiGroup>(); final Set<String> groups = this.readMultiStringAttribute(ChaiConstant.ATTR_LDAP_GROUP_MEMBERSHIP); for (final String group : groups) { returnGroups.add(ChaiFactory.createChaiGroup(group, this.getChaiProvider())); } return Collections.unmodifiableSet(returnGroups); }
public final Set<ChaiUser> getDirectReports() throws ChaiOperationException, ChaiUnavailableException { final Set<String> reportDNs = this.readMultiStringAttribute(ATTR_MANAGER); final Set<ChaiUser> reports = new HashSet<ChaiUser>(reportDNs.size()); for (final String reporteeDN : reportDNs) { reports.add(ChaiFactory.createChaiUser(reporteeDN, this.getChaiProvider())); } return Collections.unmodifiableSet(reports); }