public class TaskDisplayProvider extends BaseFacesSessionBean
Modifier and Type | Field and Description |
---|---|
protected PortalItemModel |
m_taskDefinition
Task Type (definition)
|
protected List<SelectItem> |
mandatoryTaskStatusMap
Cached mandatory task map
|
protected Map<String,String> |
priorityMap
Cached task priorities map
|
protected static Map<String,String> |
s_statusIconMap
Cached task statuses icons map
|
protected static String |
SKIN_IMAGE_PREFIX |
protected Map<String,String> |
statusMap
Cached task statuses map
|
protected String |
taskInfoKey |
protected List<SelectItem> |
taskMandatoryStatus
Cached list of mandatory task status
|
protected SelectItem[] |
taskPriorityItems
Cached list of task priorities
|
protected SelectItem[] |
taskStatusItems
Cached list of task statuses
|
protected SelectItem[] |
taskStatusItemsWithBlank
Cached list of task statuses and empty entry
|
fExpireWithPageFlow
DATA_BINDING_CLIENTS, EMPTY_RESOURCES, OUTCOME_ERROR, OUTCOME_OK, resourcesProviders
Constructor and Description |
---|
TaskDisplayProvider() |
Modifier and Type | Method and Description |
---|---|
protected ListTableContentProvider |
convertListToDisplayListProvider(String[] principalIDs)
Converts list of principal IDs into ListTableContentProvider for displaying in the table
|
static ListTableContentProvider |
createListProvider(Map<String,String> aMap)
Helper method to create a ListTableContentProvider from a string map
|
static ListTableContentProvider |
createListProvider(String[] aString)
Helper method to create a ListTableContentProvider from a string map
|
ListTableContentProvider |
getAcceptedPrincipalsListProvider()
Returns task accepted principals list as ListTableContentProvider (can be displayed in the table)
|
ListTableContentProvider |
getAssignedPrincipalsListProvider()
Returns task assigned principals list as ListTableContentProvider (can be displayed in the table)
|
protected String |
getBoolDisplay(boolean boolValue)
Returns a boolean value as a localized true/false display string
|
String |
getCreatedByDisplayName()
Returns the display string for task createdBy property
|
Date |
getCreatedDate()
Returns task created datetime
|
String |
getCustomTaskID()
Returns customTaskID property of task
|
String |
getDelegatedDisplayName()
Returns true if task is delegated
|
Map<String,String> |
getDelegationDisplayMap()
Returns task delegations map populated with user display names instead of UIDs
|
ListTableContentProvider |
getDelegationListProvider()
Returns task delegation data as ListTableContentProvider for display in the table
|
String |
getDescription()
Returns taskDescription
|
String |
getErrorCode()
Returns task error code
|
String |
getErrorMsg()
Returns task error message
|
protected String |
getErrorString()
Returns localized value for "error"
|
Date |
getExirationDate()
Returns task expireDate
|
Date |
getLastAcceptedDate()
Returns task lastAcceptedDate
|
String |
getLastAcceptedDisplayName()
Returns display name for task lastAcceptedBy user
|
Date |
getLastModifiedDate()
Returns task lastModifiedDate datetime
|
String |
getLastModifiedDisplayName()
Returns display name for task lastModifiedBy user
|
List<SelectItem> |
getMandatoryTaskStatusMap() |
String |
getName()
Returns taskName
|
static String |
getPrincipalDisplayName(String principalID)
Returns principal display name based on its ID
|
protected String |
getPrincipalName(String principalID)
Returns name of the principal by ID
|
String |
getPriorityDisplayName()
Returns Task priority as a localized display string
|
Map<String,String> |
getPriorityMap()
Returns map of task priorities and their names (priority -> name)
|
String |
getProcessInstanceID()
Returns processInstanceID property of task
|
String |
getRunningIcon()
Returns relative path to the icon representing the current task running status
|
String |
getStatusDisplayName()
Returns Task status as a localized display string
|
String |
getStatusIcon()
Returns relative path to the icon representing the current task status
|
protected Map<String,String> |
getStatusIconMap()
Returns task statuses icons urls map (status -> url)
|
Map<String,String> |
getStatusMap()
Returns map of task statuses and their names (status -> name)
|
ITask |
getTask() |
String |
getTaskID()
Returns current task ID
|
int |
getTaskIDNumber()
Returns task ID as number (for sorting in the table)
|
ITaskInfo |
getTaskInfo()
Returns current task info
|
List<SelectItem> |
getTaskMandatoryStatus()
Returns mandatory task status as list of
SelectItem suitable for Dropdown controls |
SelectItem[] |
getTaskPriorityItems()
Returns task priorities as list of
SelectItem suitable for Dropdown controls |
SelectItem[] |
getTaskStatusItems()
Returns task statuses as list of
SelectItem suitable for Dropdown controls |
SelectItem[] |
getTaskStatusItemsWithBlank()
Returns task statuses plus empty value as list of
SelectItem suitable for Dropdown controls |
String |
getTaskTypeDisplayName()
Returns display name for task type
|
SelectItem[] |
getTaskTypeItems()
Returns task types as list of
SelectItem suitable for Dropdown controls |
static Map<String,String> |
getTaskTypeMap()
Returns map of all availablel task types
|
protected String |
getUnknownString()
Returns localized value for "unknown"
|
String |
isAcceptedByCurrentUser()
Determines if the current task accepted by the current user, as
a true/false String
|
boolean |
isActiveStatus()
Is the task considered "active" based on it's current status
|
boolean |
isCanOpenProcessInstance()
Determines if current user is allowed to open BPM Process Details page
|
boolean |
isCollaborationEnabled()
Returns true if collaboration is enabled for current task type
|
boolean |
isCommentingEnabled()
Returns true if commenting is enabled for the current task type
|
protected boolean |
isCurrentUserInUserIDArray(String[] userIdArray) |
boolean |
isDelegated()
Returns true if task is delegated
|
boolean |
isDelegatedFromCurrentUser()
Returns true if the task is delegated from the current user
|
boolean |
isDelegatedToCurrentUser()
Returns true if the task is delegated to the current user
|
protected static SelectItem[] |
mapToSelectItems(Map<?,?> sourceMap,
boolean switchValues)
Converts a map to an array of SelectItems
|
protected void |
release()
Override this method to release any resources associated with this session.
|
void |
reset()
Reset state to empty values
|
void |
setTask(ITask task)
Sets current task info from task
|
void |
setTaskID(String taskID)
Sets current task ID
|
void |
setTaskInfo(ITaskInfo taskInfo)
Sets current task info
|
static List<String> |
translateIdListToDisplay(List<String> principalIdList)
Returns list of principal display names from the list of principal IDs
|
getExpireWithPageFlow, setExpireWithPageFlow, valueBound, valueUnbound
createMethodBinding, createMethodExpression, createValueBinding, createValueExpression, createValueExpression, error, error, error, error, error, getBean, getFacesContext, getLocale, getResourceInputStream, getResources, getResourcesProvider, getRootCause, getStackTrace, getTreeAttribute, isUserInRole, log, log, log, putTreeAttribute, resetDataBindingClients, resolveDataBinding, resolveDataBinding, resolveExpression, setValue
protected PortalItemModel m_taskDefinition
protected SelectItem[] taskStatusItems
protected SelectItem[] taskStatusItemsWithBlank
protected SelectItem[] taskPriorityItems
protected String taskInfoKey
protected static final String SKIN_IMAGE_PREFIX
protected List<SelectItem> taskMandatoryStatus
protected List<SelectItem> mandatoryTaskStatusMap
public void setTask(ITask task)
public void setTaskInfo(ITaskInfo taskInfo)
public void setTaskID(String taskID)
public void reset()
public ITask getTask()
public ITaskInfo getTaskInfo()
public String getTaskID()
public int getTaskIDNumber()
public String getCustomTaskID()
public String getProcessInstanceID()
public String getName()
public String getDescription()
public String getStatusDisplayName()
public String getStatusIcon()
public String getRunningIcon()
public String getPriorityDisplayName()
public String getTaskTypeDisplayName()
public boolean isCanOpenProcessInstance()
public String isAcceptedByCurrentUser()
public String getDelegatedDisplayName()
public boolean isDelegated()
public boolean isCommentingEnabled() throws Exception
Exception
public boolean isCollaborationEnabled() throws Exception
Exception
public boolean isDelegatedToCurrentUser()
public boolean isDelegatedFromCurrentUser()
protected boolean isCurrentUserInUserIDArray(String[] userIdArray)
public Date getCreatedDate()
public String getCreatedByDisplayName()
public Date getLastModifiedDate()
public Date getLastAcceptedDate()
public String getLastModifiedDisplayName()
public String getLastAcceptedDisplayName()
public Date getExirationDate()
public ListTableContentProvider getAcceptedPrincipalsListProvider()
public ListTableContentProvider getAssignedPrincipalsListProvider()
protected String getPrincipalName(String principalID)
protected String getBoolDisplay(boolean boolValue)
protected String getUnknownString()
protected String getErrorString()
protected void release()
release
in class BaseFacesSessionBean
protected Map<String,String> getStatusIconMap()
public Map<String,String> getStatusMap()
public Map<String,String> getPriorityMap()
public List<SelectItem> getMandatoryTaskStatusMap()
public static Map<String,String> getTaskTypeMap()
protected static SelectItem[] mapToSelectItems(Map<?,?> sourceMap, boolean switchValues)
sourceMap
- - the map to convertswitchValues
- - true switch the key/value values in the created SelectItemprotected ListTableContentProvider convertListToDisplayListProvider(String[] principalIDs)
principalIDs
- list of principal IDs (names)public SelectItem[] getTaskStatusItems()
SelectItem
suitable for Dropdown controlspublic SelectItem[] getTaskStatusItemsWithBlank()
SelectItem
suitable for Dropdown controlspublic SelectItem[] getTaskPriorityItems()
SelectItem
suitable for Dropdown controlspublic List<SelectItem> getTaskMandatoryStatus()
SelectItem
suitable for Dropdown controlspublic SelectItem[] getTaskTypeItems()
SelectItem
suitable for Dropdown controlspublic boolean isActiveStatus()
public String getErrorCode()
public String getErrorMsg()
public Map<String,String> getDelegationDisplayMap()
public ListTableContentProvider getDelegationListProvider()
public static ListTableContentProvider createListProvider(Map<String,String> aMap)
public static ListTableContentProvider createListProvider(String[] aString)
public static String getPrincipalDisplayName(String principalID)
principalID
- principal ID