Package com.evolveum.midpoint.cases.api
Interface CaseManager
-
public interface CaseManager
TODO specify and clean-up error handling
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description void
cancelCase(@NotNull String caseOid, @NotNull Task task, @NotNull OperationResult parentResult)
Cancels a case and its subcases.void
claimWorkItem(@NotNull WorkItemId workItemId, @NotNull Task task, @NotNull OperationResult result)
Claims an unassigned work item.void
cleanupCases(@NotNull CleanupPolicyType closedCasesPolicy, @NotNull RunningTask task, @NotNull OperationResult opResult)
Deletes obsolete cases, as specified in the policy.void
completeWorkItem(@NotNull WorkItemId workItemId, @NotNull AbstractWorkItemOutputType output, @Nullable WorkItemEventCauseInformationType causeInformation, @NotNull Task task, @NotNull OperationResult parentResult)
Completes a work item.PerformerCommentsFormatter
createPerformerCommentsFormatter(PerformerCommentsFormattingType formatting)
void
delegateWorkItem(@NotNull WorkItemId workItemId, @NotNull WorkItemDelegationRequestType delegationRequest, @NotNull Task task, @NotNull OperationResult parentResult)
Delegates a work item.void
deleteCase(@NotNull String caseOid, @NotNull Task task, @NotNull OperationResult parentResult)
Cancels and deletes a case and its subcases.boolean
isCurrentUserAuthorizedToClaim(CaseWorkItemType workItem)
boolean
isCurrentUserAuthorizedToDelegate(CaseWorkItemType workItem, Task task, OperationResult result)
boolean
isCurrentUserAuthorizedToSubmit(CaseWorkItemType workItem, Task task, OperationResult result)
default boolean
isEnabled()
Deprecated.void
registerCaseEventCreationListener(@NotNull CaseEventCreationListener listener)
void
releaseWorkItem(@NotNull WorkItemId workItemId, @NotNull Task task, @NotNull OperationResult result)
Releases claimed work item.
-
-
-
Method Detail
-
completeWorkItem
void completeWorkItem(@NotNull @NotNull WorkItemId workItemId, @NotNull @NotNull AbstractWorkItemOutputType output, @Nullable @Nullable WorkItemEventCauseInformationType causeInformation, @NotNull @NotNull Task task, @NotNull @NotNull OperationResult parentResult) throws SecurityViolationException, SchemaException, ObjectNotFoundException, ExpressionEvaluationException, CommunicationException, ConfigurationException
Completes a work item.
-
claimWorkItem
void claimWorkItem(@NotNull @NotNull WorkItemId workItemId, @NotNull @NotNull Task task, @NotNull @NotNull OperationResult result) throws ObjectNotFoundException, SecurityViolationException, SchemaException, ObjectAlreadyExistsException, CommunicationException, ConfigurationException, ExpressionEvaluationException
Claims an unassigned work item.
-
releaseWorkItem
void releaseWorkItem(@NotNull @NotNull WorkItemId workItemId, @NotNull @NotNull Task task, @NotNull @NotNull OperationResult result) throws SecurityViolationException, ObjectNotFoundException, SchemaException, ObjectAlreadyExistsException, CommunicationException, ConfigurationException, ExpressionEvaluationException
Releases claimed work item.
-
delegateWorkItem
void delegateWorkItem(@NotNull @NotNull WorkItemId workItemId, @NotNull @NotNull WorkItemDelegationRequestType delegationRequest, @NotNull @NotNull Task task, @NotNull @NotNull OperationResult parentResult) throws SecurityViolationException, ObjectNotFoundException, SchemaException, ExpressionEvaluationException, CommunicationException, ConfigurationException
Delegates a work item.
-
cancelCase
void cancelCase(@NotNull @NotNull String caseOid, @NotNull @NotNull Task task, @NotNull @NotNull OperationResult parentResult) throws SchemaException, ObjectNotFoundException, ObjectAlreadyExistsException, SecurityViolationException, CommunicationException, ConfigurationException, ExpressionEvaluationException
Cancels a case and its subcases. Carries out the authorization.
-
deleteCase
void deleteCase(@NotNull @NotNull String caseOid, @NotNull @NotNull Task task, @NotNull @NotNull OperationResult parentResult) throws SchemaException, ObjectNotFoundException, ObjectAlreadyExistsException, SecurityViolationException, CommunicationException, ConfigurationException, ExpressionEvaluationException
Cancels and deletes a case and its subcases. Carries out authorization but only for subcases. For the root it is expected that this is done by the caller (usually the ChangeExecutor).
-
cleanupCases
void cleanupCases(@NotNull @NotNull CleanupPolicyType closedCasesPolicy, @NotNull @NotNull RunningTask task, @NotNull @NotNull OperationResult opResult) throws CommonException
Deletes obsolete cases, as specified in the policy. This method removes parent case object with all its children cases. Authorizations are taken care by using model API to fetch and delete the cases.- Parameters:
closedCasesPolicy
- specifies which tasks are to be deleted, e.g. how old they have to betask
- task, within which context the cleanup executes (used to test for interruptions)- Throws:
CommonException
- When the root cases cannot be searched for. Exceptions during actual deletion or when searching for subcases are not re-thrown (to allow processing as much cases as possible).
-
isEnabled
@Deprecated default boolean isEnabled()
Deprecated.
-
registerCaseEventCreationListener
void registerCaseEventCreationListener(@NotNull @NotNull CaseEventCreationListener listener)
-
isCurrentUserAuthorizedToSubmit
boolean isCurrentUserAuthorizedToSubmit(CaseWorkItemType workItem, Task task, OperationResult result) throws ObjectNotFoundException, ExpressionEvaluationException, CommunicationException, ConfigurationException, SecurityViolationException
-
isCurrentUserAuthorizedToClaim
boolean isCurrentUserAuthorizedToClaim(CaseWorkItemType workItem)
-
isCurrentUserAuthorizedToDelegate
boolean isCurrentUserAuthorizedToDelegate(CaseWorkItemType workItem, Task task, OperationResult result) throws ObjectNotFoundException, ExpressionEvaluationException, CommunicationException, ConfigurationException, SecurityViolationException
-
createPerformerCommentsFormatter
PerformerCommentsFormatter createPerformerCommentsFormatter(PerformerCommentsFormattingType formatting)
-
-