Interface ComposeLogic
-
public interface ComposeLogic
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intcountUsersByGroup(String groupId)Get the number of users in a group.intcountUsersByRole(String role)Gets the numbers of users in a role.List<EmailRole>getEmailGroups()Get a list of groups available for this toolList<EmailRole>getEmailRoles()Read the tool config and build the email roles that are specifiedList<EmailRole>getEmailSections()Get the sections as by the section info toolStringgetGroupAwareRole()Get group-aware role which is set in sakai.properties e.g.StringgetGroupAwareRoleDefault()// OOTB(Out of the box) Sakai defaultsList<org.sakaiproject.user.api.User>getUsers()List<org.sakaiproject.user.api.User>getUsersByGroup(String groupId)Retrieve members for the current site that are of a certain group/sectionList<org.sakaiproject.user.api.User>getUsersByRole(String role)Retrieve members for the current site that are of a certain role.
-
-
-
Method Detail
-
getEmailRoles
List<EmailRole> getEmailRoles() throws org.sakaiproject.authz.api.GroupNotDefinedException
Read the tool config and build the email roles that are specified- Returns:
- return EmailRoles (called from getEmailGroups())
- Throws:
org.sakaiproject.authz.api.GroupNotDefinedException
-
getEmailGroups
List<EmailRole> getEmailGroups() throws org.sakaiproject.exception.IdUnusedException
Get a list of groups available for this tool- Returns:
- Throws:
org.sakaiproject.exception.IdUnusedException
-
getEmailSections
List<EmailRole> getEmailSections() throws org.sakaiproject.exception.IdUnusedException
Get the sections as by the section info tool- Returns:
- Throws:
org.sakaiproject.exception.IdUnusedException
-
getGroupAwareRole
String getGroupAwareRole()
Get group-aware role which is set in sakai.properties e.g. "mailsender.group.aware.role=Student,access"- Returns:
- return the String of group-aware role name
-
getGroupAwareRoleDefault
String getGroupAwareRoleDefault()
// OOTB(Out of the box) Sakai defaults- Returns:
- return default group-aware role by type if type=course, return Student. if type=project, return access.
-
getUsersByRole
List<org.sakaiproject.user.api.User> getUsersByRole(String role) throws org.sakaiproject.exception.IdUnusedException
Retrieve members for the current site that are of a certain role.- Parameters:
role-- Returns:
- List of
Users that are sorted by last name, first name. - Throws:
org.sakaiproject.exception.IdUnusedException
-
countUsersByRole
int countUsersByRole(String role)
Gets the numbers of users in a role.- Parameters:
role-- Returns:
-
getUsersByGroup
List<org.sakaiproject.user.api.User> getUsersByGroup(String groupId) throws org.sakaiproject.exception.IdUnusedException
Retrieve members for the current site that are of a certain group/section- Parameters:
groupId-- Returns:
- Throws:
org.sakaiproject.exception.IdUnusedException
-
countUsersByGroup
int countUsersByGroup(String groupId)
Get the number of users in a group.- Parameters:
groupId-- Returns:
-
getUsers
List<org.sakaiproject.user.api.User> getUsers() throws org.sakaiproject.exception.IdUnusedException
- Throws:
org.sakaiproject.exception.IdUnusedException
-
-