Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.platform.computedgroups
Class AbstractAttributeBasedGroupComputer

java.lang.Object
  extended by org.nuxeo.ecm.platform.computedgroups.AbstractGroupComputer
      extended by org.nuxeo.ecm.platform.computedgroups.AbstractAttributeBasedGroupComputer
All Implemented Interfaces:
GroupComputer
Direct Known Subclasses:
CompanyGroupComputer

public abstract class AbstractAttributeBasedGroupComputer
extends AbstractGroupComputer

Base class for GroupComputer implementation that uses User attribute to compute groups.

Author:
Thierry Delprat

Constructor Summary
AbstractAttributeBasedGroupComputer()
           
 
Method Summary
 java.util.List<java.lang.String> getAllGroupIds()
          Return all group ids.
 java.util.List<java.lang.String> getGroupMembers(java.lang.String groupName)
          Returns the members for a give group.
 java.util.List<java.lang.String> getGroupsForUser(NuxeoPrincipalImpl nuxeoPrincipal)
          Returns the group names for a give User.
 java.util.List<java.lang.String> getParentsGroupNames(java.lang.String groupName)
          Return parent groups.
 java.util.List<java.lang.String> getSubGroupsNames(java.lang.String groupName)
          Returns children groups.
 java.util.List<java.lang.String> searchGroups(java.util.Map<java.lang.String,java.io.Serializable> filter, java.util.HashSet<java.lang.String> fulltext)
          Default implementation that searches on all ids for a match.
 
Methods inherited from class org.nuxeo.ecm.platform.computedgroups.AbstractGroupComputer
hasGroup
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractAttributeBasedGroupComputer

public AbstractAttributeBasedGroupComputer()
Method Detail

getAllGroupIds

public java.util.List<java.lang.String> getAllGroupIds()
                                                throws java.lang.Exception
Description copied from interface: GroupComputer
Return all group ids. If you class can not efficiently compute this list, you can return an empty list. In this case you need to implement the searchGroups method.

Throws:
java.lang.Exception

getGroupMembers

public java.util.List<java.lang.String> getGroupMembers(java.lang.String groupName)
                                                 throws java.lang.Exception
Description copied from interface: GroupComputer
Returns the members for a give group.

Throws:
java.lang.Exception

getGroupsForUser

public java.util.List<java.lang.String> getGroupsForUser(NuxeoPrincipalImpl nuxeoPrincipal)
                                                  throws java.lang.Exception
Description copied from interface: GroupComputer
Returns the group names for a give User.

Throws:
java.lang.Exception

getParentsGroupNames

public java.util.List<java.lang.String> getParentsGroupNames(java.lang.String groupName)
                                                      throws java.lang.Exception
Description copied from interface: GroupComputer
Return parent groups.

Throws:
java.lang.Exception

getSubGroupsNames

public java.util.List<java.lang.String> getSubGroupsNames(java.lang.String groupName)
                                                   throws java.lang.Exception
Description copied from interface: GroupComputer
Returns children groups.

Throws:
java.lang.Exception

searchGroups

public java.util.List<java.lang.String> searchGroups(java.util.Map<java.lang.String,java.io.Serializable> filter,
                                                     java.util.HashSet<java.lang.String> fulltext)
                                              throws java.lang.Exception
Description copied from class: AbstractGroupComputer
Default implementation that searches on all ids for a match.

Specified by:
searchGroups in interface GroupComputer
Overrides:
searchGroups in class AbstractGroupComputer
Throws:
java.lang.Exception

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.