Class ApprovalContextUtil
java.lang.Object
com.evolveum.midpoint.schema.util.cases.ApprovalContextUtil
TODO clean up these formatting methods
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
appendNumber
(Integer stageNumber, Integer stageCount, StringBuilder sb) static @NotNull WorkItemEventCauseInformationType
static WorkItemDelegationEventType
createDelegationEvent
(WorkItemEscalationLevelType newEscalation, List<ObjectReferenceType> assigneesBefore, List<ObjectReferenceType> delegatedTo, @NotNull WorkItemDelegationMethodType method, WorkItemEventCauseInformationType causeInformation, PrismContext prismContext) static @NotNull WorkItemEscalationLevelType
createEscalationLevelInformation
(DelegateWorkItemActionType delegateAction) static List<EvaluatedPolicyRuleType>
getAllRules
(SchemaAttachedPolicyRulesType policyRules) static ApprovalContextType
static ApprovalContextType
getApprovalContext
(CaseWorkItemType workItem) static @NotNull ApprovalContextType
getApprovalContextRequired
(@NotNull CaseType currentCase) static ApprovalSchemaType
static @NotNull List<SchemaAttachedPolicyRuleType>
getAttachedPolicyRules
(ApprovalContextType actx, int order) static String
getBriefDiagInfo
(CaseType aCase) static OperationBusinessContextType
getBusinessContext
(CaseType aCase) static CaseType
static @Nullable String
getCompleteStageInfo
(CaseType aCase) static ApprovalStageDefinitionType
static @NotNull ApprovalStageDefinitionType
static @Nullable String
getEscalationLevelInfo
(AbstractWorkItemType workItem) static String
static Integer
static <T extends CaseEventType>
List<T>static <T extends CaseEventType>
List<T>getEventsForCurrentStage
(@NotNull CaseType aCase, @NotNull Class<T> clazz) static ObjectReferenceType
getObjectRef
(PrismContainerValue<CaseWorkItemType> workItem) static ObjectReferenceType
getObjectRef
(CaseWorkItemType workItem) static @Nullable WorkItemOperationKindType
static String
static String
static String
getRequesterComment
(CaseType aCase) static ObjectReferenceType
getRequesterRef
(PrismContainerValue<CaseWorkItemType> workItem) static ObjectReferenceType
getRequesterRef
(CaseWorkItemType workItem) static @NotNull List<EvaluatedPolicyRuleType>
getRulesForStage
(ApprovalContextType actx, Integer stageNumber) static List<List<EvaluatedPolicyRuleType>>
static Integer
static ApprovalStageDefinitionType
getStageDefinition
(ApprovalContextType actx, int stageNumber) static String
static String
getStageDisplayName
(CaseType aCase) static String
getStageDisplayName
(CaseWorkItemType workItem) static @Nullable String
getStageInfo
(CaseType aCase) static @Nullable String
getStageInfo
(CaseWorkItemType workItem) static String
getStageInfo
(Integer stageNumber, Integer stageCount, String stageName, String stageDisplayName) static String
getStageInfoTODO
(Integer stageNumber) static String
getStageName
(CaseType aCase) static int
getStageNumberRequired
(@NotNull CaseType aCase) static XMLGregorianCalendar
getStartTimestamp
(PrismContainerValue<CaseWorkItemType> workItem) static XMLGregorianCalendar
getStartTimestamp
(CaseWorkItemType workItem) static String
static ObjectReferenceType
getTargetRef
(PrismContainerValue<CaseWorkItemType> workItem) static ObjectReferenceType
getTargetRef
(CaseWorkItemType workItem) static <T extends WorkItemEventType>
List<T>getWorkItemEvents
(@NotNull CaseType aCase, long workItemId, Class<T> clazz) static String
getWorkItemStageDisplayName
(CaseWorkItemType workItem) static @Nullable String
getWorkItemStageInfo
(CaseWorkItemType workItem) static String
getWorkItemStageName
(CaseWorkItemType workItem) static boolean
static boolean
static boolean
isInStageBeforeLastOne
(CaseType aCase) static void
normalizeStages
(ApprovalSchemaType schema) static List<ApprovalStageDefinitionType>
sortAndCheckStages
(ApprovalSchemaType schema)
-
Constructor Details
-
ApprovalContextUtil
public ApprovalContextUtil()
-
-
Method Details
-
getStageInfo
-
getWorkItemStageInfo
-
getStageInfo
-
getWorkItemStageName
-
getWorkItemStageDisplayName
-
getStageName
-
getStageDisplayName
-
getApprovalSchema
-
getStageCount
-
getStageDisplayName
-
getStageInfo
-
getEscalationLevelInfo
-
getEscalationLevelInfo
-
isClosed
-
isClosed
-
getCompleteStageInfo
-
appendNumber
-
getAttachedPolicyRules
@NotNull public static @NotNull List<SchemaAttachedPolicyRuleType> getAttachedPolicyRules(ApprovalContextType actx, int order) -
getCurrentStageDefinitionRequired
@NotNull public static @NotNull ApprovalStageDefinitionType getCurrentStageDefinitionRequired(CaseType aCase) -
getCurrentStageDefinition
-
getStageNumberRequired
-
getStageDefinition
public static ApprovalStageDefinitionType getStageDefinition(ApprovalContextType actx, int stageNumber) -
getEventsForCurrentStage
public static <T extends CaseEventType> List<T> getEventsForCurrentStage(@NotNull @NotNull CaseType aCase, @NotNull @NotNull Class<T> clazz) -
getEvents
public static <T extends CaseEventType> List<T> getEvents(@NotNull @NotNull CaseType aCase, @NotNull @NotNull Class<T> clazz) -
getWorkItemEvents
public static <T extends WorkItemEventType> List<T> getWorkItemEvents(@NotNull @NotNull CaseType aCase, long workItemId, Class<T> clazz) -
getBriefDiagInfo
-
getStageDiagName
-
normalizeStages
-
sortAndCheckStages
-
getBusinessContext
-
getStageInfoTODO
-
getApprovalContext
-
getCase
-
getApprovalContext
-
getObjectRef
-
getObjectRef
-
getTargetRef
-
getTargetRef
-
getRequesterRef
-
getRequesterRef
-
getStartTimestamp
-
getStartTimestamp
public static XMLGregorianCalendar getStartTimestamp(PrismContainerValue<CaseWorkItemType> workItem) -
getEscalationLevelNumber
-
createCause
@NotNull public static @NotNull WorkItemEventCauseInformationType createCause(AbstractWorkItemActionType action) -
getOperationKind
@Nullable public static @Nullable WorkItemOperationKindType getOperationKind(AbstractWorkItemActionType action) -
createEscalationLevelInformation
@NotNull public static @NotNull WorkItemEscalationLevelType createEscalationLevelInformation(DelegateWorkItemActionType delegateAction) -
createDelegationEvent
public static WorkItemDelegationEventType createDelegationEvent(WorkItemEscalationLevelType newEscalation, List<ObjectReferenceType> assigneesBefore, List<ObjectReferenceType> delegatedTo, @NotNull @NotNull WorkItemDelegationMethodType method, WorkItemEventCauseInformationType causeInformation, PrismContext prismContext) -
isInStageBeforeLastOne
-
getProcessName
-
getTargetName
-
getOutcome
-
getAllRules
-
getRulesPerStage
-
getRulesForStage
@NotNull public static @NotNull List<EvaluatedPolicyRuleType> getRulesForStage(ApprovalContextType actx, Integer stageNumber) -
getApprovalContextRequired
@NotNull public static @NotNull ApprovalContextType getApprovalContextRequired(@NotNull @NotNull CaseType currentCase) -
getRequesterComment
-