org.sakaiproject.component.section.facade.impl.sakai21
Class AuthzSakaiImpl

java.lang.Object
  extended byorg.sakaiproject.component.section.facade.impl.sakai21.AuthzSakaiImpl
All Implemented Interfaces:
Authz

public class AuthzSakaiImpl
extends Object
implements Authz

Uses Sakai's SecurityService to determine the current user's site role, or consults the CourseSection membership to determine section role.

Author:
Josh Holtzman

Constructor Summary
AuthzSakaiImpl()
           
 
Method Summary
 boolean isSectionEnrollmentMangementAllowed(String userUid, String siteContext)
          The user must have either site.upd or site.upd.grp.mbrshp to update section enrollments in the Section Info tool.
 boolean isSectionManagementAllowed(String userUid, String siteContext)
          The user must have site.upd to update sections in the Section Info tool.
 boolean isSectionOptionsManagementAllowed(String userUid, String siteContext)
          The user must have site.upd to update section options in the Section Info tool.
 boolean isSectionTaManagementAllowed(String userUid, String siteContext)
          The user must have site.upd to update TA assignments in the Section Info tool, even though the framework doesn't require this (it would accept site.upd.grp.mbrshp).
 boolean isViewAllSectionsAllowed(String userUid, String siteContext)
          Even if a TA can't make changes to the sections or their enrollments, they can always view the sections and their enrollments.
 boolean isViewOwnSectionsAllowed(String userUid, String siteContext)
          The user must have access to the student marker function (section.role.student) to view their own section enrollments.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AuthzSakaiImpl

public AuthzSakaiImpl()
Method Detail

isSectionManagementAllowed

public boolean isSectionManagementAllowed(String userUid,
                                          String siteContext)
The user must have site.upd to update sections in the Section Info tool.

Specified by:
isSectionManagementAllowed in interface Authz
Parameters:
siteContext -
userUid - The user's uid
Returns:

isSectionOptionsManagementAllowed

public boolean isSectionOptionsManagementAllowed(String userUid,
                                                 String siteContext)
The user must have site.upd to update section options in the Section Info tool.

Specified by:
isSectionOptionsManagementAllowed in interface Authz
Parameters:
siteContext -
userUid - The user's uid
Returns:

isSectionTaManagementAllowed

public boolean isSectionTaManagementAllowed(String userUid,
                                            String siteContext)
The user must have site.upd to update TA assignments in the Section Info tool, even though the framework doesn't require this (it would accept site.upd.grp.mbrshp).

Specified by:
isSectionTaManagementAllowed in interface Authz
Parameters:
siteContext -
userUid - The user's uid
Returns:

isSectionEnrollmentMangementAllowed

public boolean isSectionEnrollmentMangementAllowed(String userUid,
                                                   String siteContext)
The user must have either site.upd or site.upd.grp.mbrshp to update section enrollments in the Section Info tool.

Specified by:
isSectionEnrollmentMangementAllowed in interface Authz
Parameters:
siteContext -
userUid - The user's uid
Returns:

isViewOwnSectionsAllowed

public boolean isViewOwnSectionsAllowed(String userUid,
                                        String siteContext)
The user must have access to the student marker function (section.role.student) to view their own section enrollments.

Specified by:
isViewOwnSectionsAllowed in interface Authz
Parameters:
userUid -
siteContext -
Returns:

isViewAllSectionsAllowed

public boolean isViewAllSectionsAllowed(String userUid,
                                        String siteContext)
Even if a TA can't make changes to the sections or their enrollments, they can always view the sections and their enrollments.

Specified by:
isViewAllSectionsAllowed in interface Authz
Parameters:
siteContext -
userUid - The user's uid
Returns: