|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.hr.time.roles.TkUserRoles
public class TkUserRoles
TkUserRoles encapsulates the concept of roles for a single user and provides lookup methods for quick Role checking. This object will be stored in TkUser.
Method Summary | |
---|---|
boolean |
canSubmitTimesheet(String docId)
|
boolean |
canSubmitTimesheet(TimesheetDocument doc)
|
Set<String> |
getActiveAssignmentIds()
Accessor method to obtain the Set of active Assignment ids for the current employee. |
Set<Long> |
getApproverWorkAreas()
Provides a set of WorkArea names that this user is an approver for. |
Set<String> |
getDepartmentViewOnlyDepartments()
Provides a Set |
Set<String> |
getOrgAdminCharts()
Provides a Set |
Set<String> |
getOrgAdminDepartments()
Provides a Set |
String |
getPrincipalId()
|
Set<Long> |
getReviewerWorkAreas()
Provides a Set of WorkArea names that this user is a reviewer for. |
static TkUserRoles |
getUserRoles(String principalId)
|
boolean |
isActiveEmployee()
Does the current user have any active assignments? |
boolean |
isAnyApproverActive()
Does the current user have any active approver roles? Approver roles attach at the WorkArea level. |
boolean |
isApprover()
|
boolean |
isApproverForPerson(String principalId)
|
boolean |
isApproverForTimesheet(String docId)
|
boolean |
isApproverForTimesheet(TimesheetDocument doc)
Indicates whether or not the current can approve the provided timesheet. |
boolean |
isDepartmentAdmin()
|
boolean |
isDepartmentAdminForPerson(String principalId)
|
boolean |
isDeptViewOnly()
|
boolean |
isDeptViewOnlyForPerson(String principalId)
|
boolean |
isDocumentReadable(String documentId)
|
boolean |
isDocumentReadable(TimesheetDocument document)
|
boolean |
isDocumentWritable(String documentId)
|
boolean |
isDocumentWritable(TimesheetDocument document)
|
boolean |
isGlobalViewOnly()
Does the current user have the Global View Only role? |
boolean |
isLocationAdmin()
|
boolean |
isLocationAdminForPerson(String principalId)
|
boolean |
isReviewer()
|
boolean |
isSynchronous()
Does the current user have an assignment that is marked synchronous? |
boolean |
isSystemAdmin()
Is the current user a system administrator? |
boolean |
isTimesheetApprover()
Does the current user have any role that grants permission to approve timesheets? |
boolean |
isTimesheetReviewer()
|
boolean |
isTimesheetReviewerForPerson(String principalId)
|
void |
setAssignments(List<Assignment> assignments)
|
void |
setPrincipalId(String principalId)
|
void |
setRoles(List<TkRole> roles)
Place the TkRole objects in the provided List into their appropriate buckets for fast lookup. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static TkUserRoles getUserRoles(String principalId)
public boolean isLocationAdmin()
isLocationAdmin
in interface UserRoles
public boolean isDepartmentAdmin()
isDepartmentAdmin
in interface UserRoles
public String getPrincipalId()
getPrincipalId
in interface UserRoles
public void setPrincipalId(String principalId)
public Set<Long> getApproverWorkAreas()
UserRoles
getApproverWorkAreas
in interface UserRoles
public Set<Long> getReviewerWorkAreas()
UserRoles
getReviewerWorkAreas
in interface UserRoles
public Set<String> getOrgAdminDepartments()
UserRoles
getOrgAdminDepartments
in interface UserRoles
public Set<String> getOrgAdminCharts()
UserRoles
getOrgAdminCharts
in interface UserRoles
public Set<String> getDepartmentViewOnlyDepartments()
UserRoles
getDepartmentViewOnlyDepartments
in interface UserRoles
public Set<String> getActiveAssignmentIds()
getActiveAssignmentIds
in interface UserRoles
public boolean isSystemAdmin()
UserRoles
isSystemAdmin
in interface UserRoles
public boolean isGlobalViewOnly()
UserRoles
isGlobalViewOnly
in interface UserRoles
public boolean isDeptViewOnly()
isDeptViewOnly
in interface UserRoles
public boolean isSynchronous()
UserRoles
isSynchronous
in interface UserRoles
public boolean isReviewer()
public boolean isApprover()
public void setRoles(List<TkRole> roles)
roles
- A List of TkRole objects for the current user.public void setAssignments(List<Assignment> assignments)
public boolean isActiveEmployee()
UserRoles
isActiveEmployee
in interface UserRoles
public boolean isTimesheetApprover()
UserRoles
isTimesheetApprover
in interface UserRoles
public boolean isTimesheetReviewer()
isTimesheetReviewer
in interface UserRoles
public boolean isAnyApproverActive()
UserRoles
isAnyApproverActive
in interface UserRoles
public boolean isApproverForTimesheet(TimesheetDocument doc)
UserRoles
isApproverForTimesheet
in interface UserRoles
doc
- The TimesheetDocument in question.
public boolean isApproverForTimesheet(String docId)
isApproverForTimesheet
in interface UserRoles
public boolean isDocumentWritable(TimesheetDocument document)
isDocumentWritable
in interface UserRoles
public boolean isDocumentWritable(String documentId)
isDocumentWritable
in interface UserRoles
public boolean isDocumentReadable(String documentId)
isDocumentReadable
in interface UserRoles
public boolean isDocumentReadable(TimesheetDocument document)
isDocumentReadable
in interface UserRoles
public boolean canSubmitTimesheet(TimesheetDocument doc)
canSubmitTimesheet
in interface UserRoles
public boolean canSubmitTimesheet(String docId)
canSubmitTimesheet
in interface UserRoles
public boolean isApproverForPerson(String principalId)
isApproverForPerson
in interface UserRoles
public boolean isDepartmentAdminForPerson(String principalId)
isDepartmentAdminForPerson
in interface UserRoles
public boolean isDeptViewOnlyForPerson(String principalId)
isDeptViewOnlyForPerson
in interface UserRoles
public boolean isLocationAdminForPerson(String principalId)
isLocationAdminForPerson
in interface UserRoles
public boolean isTimesheetReviewerForPerson(String principalId)
isTimesheetReviewerForPerson
in interface UserRoles
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |