public interface SakaiFacade
This is an interface to provides all necessary methods, which are depend on the Sakai Services. This will allow the separation of Signup Tool and the Sakai Tools
| Modifier and Type | Field and Description |
|---|---|
static String |
GROUP_PREFIX |
static String |
GROUP_PROP_SIGNUP_IGNORE |
static String |
GROUP_PROP_SITEINFO_VISIBLE |
static String |
NO_LOCATION |
static String |
REALM_ID_FOR_LOGIN_REQUIRED_ONLY |
static String |
SIGNUP_ATTEND |
static String |
SIGNUP_ATTEND_ALL |
static String |
SIGNUP_CREATE_GROUP |
static String |
SIGNUP_CREATE_GROUP_ALL |
static String |
SIGNUP_CREATE_SITE
Can create meetings in site and groups in that site*
|
static String |
SIGNUP_DELETE_GROUP |
static String |
SIGNUP_DELETE_GROUP_ALL |
static String |
SIGNUP_DELETE_SITE |
static String |
SIGNUP_UPDATE_GROUP |
static String |
SIGNUP_UPDATE_GROUP_ALL |
static String |
SIGNUP_UPDATE_SITE |
static String |
SIGNUP_VIEW |
static String |
SIGNUP_VIEW_ALL |
static String |
STUDENT_ROLE_ID |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addUsersToGroup(Collection<String> userIds,
String siteId,
String groupId,
String timeslottoGroup)
Add the users to the given group in the given site
|
boolean |
checkForGroup(String siteId,
String groupId)
Check if a group with the given id exists
|
boolean |
checkForUser(String userId)
Does this user exist in the system?
|
String |
createGroup(String siteId,
String title,
String description,
List<String> userUuids)
Create a group in the specified site with the given title and description and optionally, a list of user uuids to populate it.
|
Calendar |
getAdditionalCalendar(String siteId) |
List<SignupUser> |
getAllPossbileCoordinatorsOnFastTrack(SignupMeeting meeting)
get all coordinators, who have create meeting permission in the event/meeting
This method is much efficient and fast.
|
List<SignupUser> |
getAllPossibleAttendees(SignupMeeting meeting)
get all users, who have permission to attend the meeting
|
List<SignupUser> |
getAllPossibleCoordinators(SignupMeeting meeting)
get all coordinators, who have create meeting permission in the event/meeting
|
List<SignupUser> |
getAllUsers(SignupMeeting meeting)
get all users, who have joined in the event/meeting
|
Calendar |
getCalendar(String siteId)
get Calendar for this specific siteId
|
Calendar |
getCalendarById(String calendarId)
get Calendar object by calendar unique Id
|
ContentHostingService |
getContentHostingService()
get a ContentHostingService from one of the Sakai services
|
String |
getCurrentLocationId()
get current site Id
|
String |
getCurrentPageId()
get current pageId,which is an unique id
|
String |
getCurrentUserId()
get current userId
|
FormattedText |
getFormattedText() |
Group |
getGroup(String siteId,
String groupId)
get group object accourding to the siteId and groupId
|
List<String> |
getGroupMembers(String siteId,
String groupId)
Get the list of users in a group
|
String |
getLocationTitle(String locationId)
get current site title
|
ServerConfigurationService |
getServerConfigurationService()
get ServerConfigurationService object
|
SignupUser |
getSignupUser(SignupMeeting meeting,
String userId)
get the user, who has permission to attend the meeting
|
SiteService |
getSiteService()
set a Sakai SiteService
|
String |
getSiteSignupPageId(String siteId)
get site-signup pageId,which is an unique id *
|
TimeService |
getTimeService()
get a TimeService object from one of the Sakai services
|
ToolManager |
getToolManager()
get the ToolManager object.
|
User |
getUser(String userId)
get the User object
|
User |
getUserByEid(String eid)
Find a user by their eid.
|
User |
getUserByEmail(String email)
Get a user by email address.
|
String |
getUserDisplayLastFirstName(String userId)
Get the display name for a user by their unique id
|
String |
getUserDisplayName(String userId)
Get the display name for a user by their unique id
|
String |
getUserId(String eid)
get internal user id
|
List<String> |
getUserPublishedSiteIds(String userId)
get all the published sites, which user joins in
|
User |
getUserQuietly(String userId)
get the User object but do not log any messages.
|
Collection<User> |
getUsersByEmail(String email)
Find users by an email address.
|
List<SignupSite> |
getUserSites(String userId)
get all the sites, which user joins in
|
List<User> |
getUsersWithPermission(String permission)
Get a list of users in the current site that have the given permission
|
boolean |
hasPermissionToCreate(SignupMeeting meeting,
String userId)
test whether a user has permission to create a meeting in a meeting
|
boolean |
isAllowedGroup(String userId,
String permission,
String siteId,
String groupId)
Check if this user has access to the group in the site
|
boolean |
isAllowedSite(String userId,
String permission,
String siteId)
Check if this user has access to the site
|
boolean |
isCsvExportEnabled()
Is csv export enabled?
|
boolean |
isUserAdmin(String userId)
check to see if the user is Admin
|
void |
popSecurityAdvisor(SecurityAdvisor advisor)
Pop the specified security advisor
|
SecurityAdvisor |
pushAllowCalendarEdit(Calendar calendar)
Allow calendar.revise.any for the current user
|
SecurityAdvisor |
pushSecurityAdvisor()
Standard privileged push for the current user
|
boolean |
removeUserFromGroup(String userId,
String siteId,
String groupId)
Remove the user from the given group in the given site
|
boolean |
synchonizeGroupTitle(String siteId,
String groupId,
String newTitle)
Synchronize the group title if group title has not been modified directly via Site-Info tool
|
static final String NO_LOCATION
static final String SIGNUP_VIEW
static final String SIGNUP_VIEW_ALL
static final String SIGNUP_ATTEND
static final String SIGNUP_ATTEND_ALL
static final String SIGNUP_CREATE_SITE
static final String SIGNUP_CREATE_GROUP
static final String SIGNUP_CREATE_GROUP_ALL
static final String SIGNUP_DELETE_SITE
static final String SIGNUP_DELETE_GROUP
static final String SIGNUP_DELETE_GROUP_ALL
static final String SIGNUP_UPDATE_SITE
static final String SIGNUP_UPDATE_GROUP
static final String SIGNUP_UPDATE_GROUP_ALL
static final String STUDENT_ROLE_ID
static final String REALM_ID_FOR_LOGIN_REQUIRED_ONLY
static final String GROUP_PREFIX
static final String GROUP_PROP_SITEINFO_VISIBLE
static final String GROUP_PROP_SIGNUP_IGNORE
boolean isUserAdmin(String userId)
userId - userId the internal user id (not username)String getCurrentUserId()
String getUserDisplayLastFirstName(String userId)
userId - the current sakai user id (not username)String getUserDisplayName(String userId)
userId - the current sakai user id (not username)String getCurrentLocationId()
String getLocationTitle(String locationId)
locationId - a unique id which represents the current location of the user
(entity reference)boolean isAllowedSite(String userId, String permission, String siteId)
userId - the internal user id (not username)permission - function like signup.viewsiteId - site context idboolean isAllowedGroup(String userId, String permission, String siteId, String groupId)
userId - the internal user id (not username)permission - function like signup.create.groupsiteId - site context idgroupId - group context idToolManager getToolManager()
List<String> getUserPublishedSiteIds(String userId)
userId - userId the internal user id (not username)List<SignupSite> getUserSites(String userId)
userId - userId the internal user id (not username)String getUserId(String eid) throws UserNotDefinedException
eid - a unique id (enterprise Id)UserNotDefinedException - throw if user is not foundUser getUser(String userId)
userId - a sakai internal user IdUser getUserQuietly(String userId)
userId - a sakai internal user Idboolean checkForUser(String userId)
userId - List<SignupUser> getAllPossibleCoordinators(SignupMeeting meeting)
meeting - a SignupMeeting objectList<SignupUser> getAllPossbileCoordinatorsOnFastTrack(SignupMeeting meeting)
meeting - a SignupMeeting objectboolean hasPermissionToCreate(SignupMeeting meeting, String userId)
meeting - userId - List<SignupUser> getAllUsers(SignupMeeting meeting)
meeting - a SignupMeeting objectList<SignupUser> getAllPossibleAttendees(SignupMeeting meeting)
meeting - a SignupMeeting objectCalendar getCalendar(String siteId) throws PermissionException
siteId - a unique id which represents the current sitenull if something went very wrongPermissionException - throw if user has no permissionCalendar getCalendarById(String calendarId) throws PermissionException
calendarId - a unique Calendar Idnull if something went very wrongPermissionException - throw if user has no permissionGroup getGroup(String siteId, String groupId) throws IdUnusedException
siteId - a unique id which represents the current sitegroupId - a unique id which represents the current groupIdUnusedException - throw if siteId or groupId is not foundServerConfigurationService getServerConfigurationService()
SiteService getSiteService()
String getCurrentPageId()
String getSiteSignupPageId(String siteId)
siteId - a unique site IdTimeService getTimeService()
ContentHostingService getContentHostingService()
SignupUser getSignupUser(SignupMeeting meeting, String userId)
meeting - a SignupMeeting objectuserId - userId the internal user id (not username)List<User> getUsersWithPermission(String permission)
permission - the permission to checkCollection<User> getUsersByEmail(String email)
email - User getUserByEmail(String email)
email - User getUserByEid(String eid)
eid - boolean isCsvExportEnabled()
SecurityAdvisor pushAllowCalendarEdit(Calendar calendar)
SecurityAdvisor pushSecurityAdvisor()
void popSecurityAdvisor(SecurityAdvisor advisor)
String createGroup(String siteId, String title, String description, List<String> userUuids)
siteId - site to create this group intitle - group titledescription - group descriptionuserIds - list of users to populate the group with, optional.boolean addUsersToGroup(Collection<String> userIds, String siteId, String groupId, String timeslottoGroup)
userIds - Collection of users, could be a single usersiteId - id of the sitegroupId - id of the groupboolean removeUserFromGroup(String userId, String siteId, String groupId)
userId - uuid of the usersiteId - id of the sitegroupId - id of the groupList<String> getGroupMembers(String siteId, String groupId)
siteId - id of the sitegroupId - id of the groupboolean checkForGroup(String siteId, String groupId)
siteId - id of the sitegroupId - id of the groupboolean synchonizeGroupTitle(String siteId, String groupId, String newTitle)
siteId - id of the sitegroupId - id of the groupnewTitle - new group titleCalendar getAdditionalCalendar(String siteId) throws PermissionException
PermissionExceptionFormattedText getFormattedText()
Copyright © 2003–2020 Sakai Project. All rights reserved.