Class WorkflowAction
- java.lang.Object
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable
@Deprecated public class WorkflowAction extends GeneratedWorkflowAction
Deprecated.since ages - as of release 4.3, please useWorkflowActionModel
Represents a real action which is created by a
WorkflowActionTemplate
. It holds a status signalizing the current state the action is in.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.GenericItem
GenericItem.GenericItemImpl
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.c2l.LocalizableItem
LocalizableItem.LocalizableItemImpl
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.ExtensibleItem
ExtensibleItem.ExtensibleItemImpl
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.Item
Item.AttributeFilter, Item.AttributeMode, Item.CachedGetter, Item.CachedSetter, Item.ItemAttributeMap, Item.ItemConstraint, Item.ItemImpl, Item.JaloCachedComputationException
-
-
Field Summary
-
Fields inherited from class de.hybris.platform.workflow.jalo.GeneratedWorkflowAction
ACTIVATED, ATTACHMENTITEMS, ATTACHMENTS, COMMENT, DECISIONS, DECISIONSHANDLER, DEFAULT_INITIAL_ATTRIBUTES, FIRSTACTIVATED, INCOMINGDECISIONS, INCOMINGLINKS, INCOMINGLINKSSTR, SELECTEDDECISION, STATUS, TEMPLATE, WORKFLOW, WORKFLOWACTIONITEMATTACHMENTRELATION_MARKMODIFIED, WORKFLOWACTIONITEMATTACHMENTRELATION_SRC_ORDERED, WORKFLOWACTIONITEMATTACHMENTRELATION_TGT_ORDERED, WORKFLOWACTIONLINKRELATION_MARKMODIFIED, WORKFLOWACTIONLINKRELATION_SRC_ORDERED, WORKFLOWACTIONLINKRELATION_TGT_ORDERED, WORKFLOWHANDLER, WORKFLOWPOS
-
Fields inherited from class de.hybris.platform.workflow.jalo.GeneratedAbstractWorkflowAction
ACTIONTYPE, CODE, DESCRIPTION, EMAILADDRESS, NAME, PREDECESSORS, PREDECESSORSSTR, PRINCIPALASSIGNED, RENDERERTEMPLATE, SENDEMAIL, SUCCESSORS, WORKFLOWACTIONCOMMENTS, WORKFLOWACTIONCOMMENTSHANDLER, WORKFLOWACTIONORDERINGRELATION_MARKMODIFIED, WORKFLOWACTIONORDERINGRELATION_SRC_ORDERED, WORKFLOWACTIONORDERINGRELATION_TGT_ORDERED
-
Fields inherited from class de.hybris.platform.jalo.c2l.LocalizableItem
LANGUAGE_FALLBACK_ENABLED
-
Fields inherited from class de.hybris.platform.jalo.Item
_CREATION_TIME_INTERNAL, _MODIFIED_TIME_INTERNAL, accessorLog, CREATION_TIME, DISABLE_ATTRIBUTE_CHECK, DISABLE_ITEMCHECK_BEFORE_REMOVABLE, EVEN, FEATURE_ACCESSMAP_QUALIFIER, HJMPTS, INITIAL_CREATION_FLAG, isJaloOnly, MODIFIED_TIME, NEGATIVE, NOT_FOUND, OWNER, PK, POSITIVE, SAVE_FROM_SERVICE_LAYER, staticTransientObjects, TYPE
-
Fields inherited from class de.hybris.platform.util.BridgeAbstraction
impl, tenant
-
-
Constructor Summary
Constructors Constructor Description WorkflowAction()
Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected void
activate()
Deprecated.Sets the status of this action to active if it is not disabled.void
checkIncomingLinks()
Deprecated.since ages - as of release 4.3, private method inWorkflowProcessingService
void
complete()
Deprecated.Sets the status tocomplete
and tries to activate all successors.protected Item
createItem(SessionContext ctx, ComposedType type, Item.ItemAttributeMap allAttributes)
Deprecated.Has to be implemented for each concrete subtype of item.void
decide()
Deprecated.since ages - as of release 4.3, please useWorkflowProcessingService.decideAction(WorkflowActionModel, de.hybris.platform.workflow.model.WorkflowDecisionModel)
void
disable()
Deprecated.Disables the action.static EnumerationValue
getActiveStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.IN_PROGRESS
java.util.List<Item>
getAttachmentItems(SessionContext ctx)
Deprecated.Generated method - Getter of theWorkflowAction.attachmentItems
attribute.static EnumerationValue
getCompletedStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.COMPLETED
WorkflowDecision
getDecisionByName(java.lang.String name)
Deprecated.Returns the decision with the given name, if this action has no such decision, returns null.long
getDecisionsCount()
Deprecated.since ages - as of release 4.3, useWorkflowActionModel.getDecisions()
static EnumerationValue
getDisabledStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.DISABLED
static EnumerationValue
getEndActionType()
Deprecated.since ages - as of release 4.3, please useWorkflowActionType.END
static EnumerationValue
getEndedByWorkflowStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.ENDED_THROUGH_END_OF_WORKFLOW
static EnumerationValue
getIdleStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.PENDING
java.util.List<Link>
getIncomingLinks(SessionContext ctx)
Deprecated.since ages - as of release 4.3, private method inWorkflowProcessingService
java.lang.String
getIncomingLinksStr(SessionContext ctx)
Deprecated.Generated method - Getter of theWorkflowAction.incomingLinksStr
attribute.static EnumerationValue
getNormalActionType()
Deprecated.since ages - as of release 4.3, please useWorkflowActionType.NORMAL
static EnumerationValue
getStartActionType()
Deprecated.since ages - as of release 4.3, please useWorkflowActionType.START
static EnumerationValue
getTerminatedStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.TERMINATED
protected void
idle()
Deprecated.Set the status of this action toidle
without further checks.boolean
isActive()
Deprecated.since ages - as of release 4.3, please use status comparisonboolean
isCompleted()
Deprecated.since ages - as of release 4.3, please useWorkflowActionService.isCompleted(de.hybris.platform.workflow.model.WorkflowActionModel)
boolean
isDisabled()
Deprecated.since ages - as of release 4.3, please use status comparisonboolean
isEndedByWorkflow()
Deprecated.since ages - as of release 4.3, please use status comparisonboolean
isUserAssignedPrincipal()
Deprecated.since ages - as of release 4.3, please useWorkflowActionService.isUserAssignedPrincipal(de.hybris.platform.workflow.model.WorkflowActionModel)
protected boolean
predecessorsCompleted()
Deprecated.since ages - Checks whether all predecessors are completed.void
reject()
Deprecated.since ages - Rejects the action.protected void
sendActivationEmail()
Deprecated.since ages - as of release 4.3, please useEmailService.createActivationEmail(de.hybris.platform.workflow.model.WorkflowActionModel)
void
tryActivate()
Deprecated.since ages - Tries to activate the action.protected void
tryActivatePredecessors()
Deprecated.since ages - Tries to activate all predecessors.protected void
tryActivateSuccessors()
Deprecated.since ages - Tries to activate all successors.-
Methods inherited from class de.hybris.platform.workflow.jalo.GeneratedWorkflowAction
addToAttachments, addToAttachments, addToDecisions, addToDecisions, addToIncomingDecisions, addToIncomingDecisions, getActivated, getActivated, getAttachmentItems, getAttachments, getAttachments, getAttachmentsCount, getAttachmentsCount, getComment, getComment, getDecisions, getDecisions, getDefaultAttributeModes, getFirstActivated, getFirstActivated, getIncomingDecisions, getIncomingDecisions, getIncomingDecisionsCount, getIncomingDecisionsCount, getIncomingLinks, getIncomingLinksStr, getSelectedDecision, getSelectedDecision, getStatus, getStatus, getTemplate, getTemplate, getWorkflow, getWorkflow, isMarkModifiedDisabled, removeFromAttachments, removeFromAttachments, removeFromDecisions, removeFromDecisions, removeFromIncomingDecisions, removeFromIncomingDecisions, setActivated, setActivated, setAttachments, setAttachments, setComment, setComment, setDecisions, setDecisions, setFirstActivated, setFirstActivated, setIncomingDecisions, setIncomingDecisions, setSelectedDecision, setSelectedDecision, setStatus, setStatus, setTemplate, setTemplate, setWorkflow, setWorkflow
-
Methods inherited from class de.hybris.platform.workflow.jalo.AbstractWorkflowAction
getInitialProperties, getNonInitialAttributes, getPredecessorsStr, setPrincipalAssigned, writeAutomatedComment, writeAutomatedComment
-
Methods inherited from class de.hybris.platform.workflow.jalo.GeneratedAbstractWorkflowAction
addToPredecessors, addToPredecessors, addToSuccessors, addToSuccessors, addToWorkflowActionComments, addToWorkflowActionComments, getActionType, getActionType, getAllDescription, getAllDescription, getAllName, getAllName, getCode, getCode, getDescription, getDescription, getEmailAddress, getEmailAddress, getName, getName, getPredecessors, getPredecessors, getPredecessorsCount, getPredecessorsCount, getPredecessorsStr, getPrincipalAssigned, getPrincipalAssigned, getRendererTemplate, getRendererTemplate, getSuccessors, getSuccessors, getSuccessorsCount, getSuccessorsCount, getWorkflowActionComments, getWorkflowActionComments, isSendEmail, isSendEmail, isSendEmailAsPrimitive, isSendEmailAsPrimitive, removeFromPredecessors, removeFromPredecessors, removeFromSuccessors, removeFromSuccessors, removeFromWorkflowActionComments, removeFromWorkflowActionComments, setActionType, setActionType, setAllDescription, setAllDescription, setAllName, setAllName, setCode, setCode, setDescription, setDescription, setEmailAddress, setEmailAddress, setName, setName, setPredecessors, setPredecessors, setPrincipalAssigned, setRendererTemplate, setRendererTemplate, setSendEmail, setSendEmail, setSendEmail, setSendEmail, setSuccessors, setSuccessors, setWorkflowActionComments, setWorkflowActionComments
-
Methods inherited from class de.hybris.platform.jalo.GenericItem
getImplementation, getRelatedItems, setRelatedItems
-
Methods inherited from class de.hybris.platform.jalo.c2l.LocalizableItem
getAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllValuesSessionContext, getLocalizedProperty, getLocalizedProperty, getLocalizedPropertyInternal, getLocalizedPropertyNames, getLocalizedPropertyNames, hasLanguage, isEmptyValue, isFallbackEnabled, removeLocalizedProperty, removeLocalizedProperty, setAllLocalizedProperties, setAllLocalizedProperties, setLocalizedProperty, setLocalizedProperty
-
Methods inherited from class de.hybris.platform.jalo.ExtensibleItem
createNonClassAccessor, getAllProperties, getAllProperties, getProperty, getProperty, getPropertyNames, getPropertyNames, removeProperty, removeProperty, setAllProperties, setAllProperties, setProperty, setProperty
-
Methods inherited from class de.hybris.platform.jalo.Item
addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addNegativePermission, addPermission, addPositivePermission, assureExtensionsLoaded, changeTypeAfterCreation, checkConstraint, checkItemPermission, checkMandatoryAttribute, checkMandatoryAttribute, checkPermission, checkPermission, checkRemovable, clearPermission, compareTo, ctx, doAfterRemove, doBeforeRemove, equals, getAccessorFor, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributesInternal, getAllLinkedItems, getAndCheckCacheBoundItem, getAttribute, getAttribute, getCacheBoundItem, getComposedType, getComposedTypePK, getCreationTime, getCurrentlyRemovingCount, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItemsCount, getLinkedItemsCount, getLinkedItemsCount, getModificationTime, getNegativePermissions, getOwner, getPermissionMap, getPermissions, getPersistenceVersion, getPK, getPositivePermissions, getRestrictedPrincipals, getSession, getSyncObject, getTenant, getTransientObject, getTransientObjectMap, hashCode, hasRegisteredClassAccessorFor, internal_registerClassAccessorFor, internal_registerNonClassAccessorFor, invalidateLocalCaches, isAlive, isCacheBound, isCurrentlyRemoving, isCurrentlyRemoving, isEmptyRelationValue, isInCreate, isInstanceOf, isItemCheckBeforeRemoveableDisabled, isRelationLocalizationFallbackEnabled, newInstance, notifyExtensionsAfterItemCreation, notifyExtensionsBeforeItemCreation, notifyItemRemoval, notifyManagerAboutItemRemoval, readResolve, registerAccessFor, registerAccessFor, registerJaloInvalidationListeners, remove, remove, removeItemCollection, removeItemCollection, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinks, removePartOfItems, removePartOfItems, setAllAttributes, setAllAttributes, setAllAttributesInternal, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAttribute, setAttribute, setAttributeFromString, setAttributeFromString, setCacheBound, setComposedType, setCreationTime, setImplementation, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setModificationTime, setNonInitialAttributes, setOwner, setPermissionsByMap, setTransientObject, setUseTA, toString, useTA, writeReplace
-
Methods inherited from class de.hybris.platform.util.BridgeAbstraction
setTenant
-
-
-
-
Method Detail
-
getStartActionType
@Deprecated public static EnumerationValue getStartActionType()
Deprecated.since ages - as of release 4.3, please useWorkflowActionType.START
Gets the constant value for the
start
actiontype.- Returns:
- constant for
start
actiontype
-
getNormalActionType
@Deprecated public static EnumerationValue getNormalActionType()
Deprecated.since ages - as of release 4.3, please useWorkflowActionType.NORMAL
Gets the constant value for the
normal
actiontype.- Returns:
- constant for
normal
actiontype
-
getEndActionType
@Deprecated public static EnumerationValue getEndActionType()
Deprecated.since ages - as of release 4.3, please useWorkflowActionType.END
Gets the constant value for the
end
actiontype.- Returns:
- constant for
end
actiontype
-
getActiveStatus
@Deprecated public static EnumerationValue getActiveStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.IN_PROGRESS
Gets the constant value for the
active
status.- Returns:
- constant for
active
status
-
getIdleStatus
@Deprecated public static EnumerationValue getIdleStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.PENDING
Gets the constant value for the
idle
status.- Returns:
- constant for
idle
status
-
getCompletedStatus
@Deprecated public static EnumerationValue getCompletedStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.COMPLETED
Gets the constant value for the
completed
status.- Returns:
- constant for
completed
status
-
getEndedByWorkflowStatus
@Deprecated public static EnumerationValue getEndedByWorkflowStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.ENDED_THROUGH_END_OF_WORKFLOW
Gets the constant value for the
endThroughEndOfWorkflow
status.- Returns:
- constant for
endThroughEndOfWorkflow
status
-
getDisabledStatus
@Deprecated public static EnumerationValue getDisabledStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.DISABLED
Gets the constant value for the
disabled
status.- Returns:
- constant for
disabled
status
-
getTerminatedStatus
@Deprecated public static EnumerationValue getTerminatedStatus()
Deprecated.since ages - as of release 4.3, please useWorkflowActionStatus.TERMINATED
Gets the constant value for the
terminated
status.- Returns:
- constant for
terminated
status
-
createItem
protected Item createItem(SessionContext ctx, ComposedType type, Item.ItemAttributeMap allAttributes) throws JaloBusinessException
Deprecated.Description copied from class:Item
Has to be implemented for each concrete subtype of item. This method is responsible for creating a new item instance ( by calling managers, ejb homes, etc. ) duringComposedType.newInstance(Map)
.In case this method uses any of the attribute values during creation it is required to override
Item.getNonInitialAttributes(SessionContext, ItemAttributeMap)
too.
Sn example:public static final String MY_ATTRIBUTE = "someAttribute"; ... protected Item createItem(SessionContext ctx, ComposedType type, Map allAttributes ) throws JaloBusinessException { MyManager man = ... return man.createMyItem( (String)allAttributes.get(MY_ATTRIBUTE) ); // here MY_ATTRIBUTE is used for creation, so it must not be set again } protected Map getNonInitialAttributes( SessionContext ctx, Map allAttributes ) { // let superclass remove its own initial attributes Map ret = super.getNonInitialAttributes( ctx, allAttributes ); // remove MY_ATTRIBUTE from all attributes since if has already been set ret.remove(MY_ATTRIBUTE); return ret; }
- Overrides:
createItem
in classGeneratedWorkflowAction
- Parameters:
ctx
- the current session context which this item is created withintype
- the actual item type ( since subtypes may not provide a own jalo class this may be different from the type which this method was implemented for )- Returns:
- the new item instance
- Throws:
JaloBusinessException
- indicates an error during creation - any changes will be rollbacked
-
activate
protected void activate()
Deprecated.Sets the status of this action to active if it is not disabled. Sets new status, new activated date, first activated flag optional and optional sends activation mail.
-
sendActivationEmail
@Deprecated protected void sendActivationEmail()
Deprecated.since ages - as of release 4.3, please useEmailService.createActivationEmail(de.hybris.platform.workflow.model.WorkflowActionModel)
Sends the activation mail.
-
idle
protected void idle()
Deprecated.Set the status of this action toidle
without further checks.
-
isDisabled
@Deprecated public boolean isDisabled()
Deprecated.since ages - as of release 4.3, please use status comparisonChecks whether the action is disabled.
- Returns:
- true if the action is disabled, false otherwise
-
isEndedByWorkflow
@Deprecated public boolean isEndedByWorkflow()
Deprecated.since ages - as of release 4.3, please use status comparison
-
isActive
@Deprecated public boolean isActive()
Deprecated.since ages - as of release 4.3, please use status comparisonChecks whether the action is active.
- Returns:
- true if the action is action, false otherwise
-
isCompleted
@Deprecated public boolean isCompleted()
Deprecated.since ages - as of release 4.3, please useWorkflowActionService.isCompleted(de.hybris.platform.workflow.model.WorkflowActionModel)
Checks whether the action is completed.
- Returns:
- true if the action is completed, false otherwise
-
disable
public void disable()
Deprecated.Disables the action.
-
tryActivate
@Deprecated public void tryActivate()
Deprecated.since ages - Tries to activate the action. If the action is already completed, it will try to activate its successors. If the action is not completed and all predecessors are completed the action will be activated.
-
predecessorsCompleted
@Deprecated protected boolean predecessorsCompleted()
Deprecated.since ages - Checks whether all predecessors are completed.- Returns:
- true if all predecessors are completed, false otherwise
-
tryActivateSuccessors
@Deprecated protected void tryActivateSuccessors()
Deprecated.since ages - Tries to activate all successors.
-
tryActivatePredecessors
@Deprecated protected void tryActivatePredecessors()
Deprecated.since ages - Tries to activate all predecessors.
-
complete
public void complete()
Deprecated.Sets the status tocomplete
and tries to activate all successors.
-
reject
@Deprecated public void reject()
Deprecated.since ages - Rejects the action. Sets the status toidle
and activates all predecessors.
-
checkIncomingLinks
@Deprecated public void checkIncomingLinks() throws JaloInvalidParameterException, JaloBusinessException
Deprecated.since ages - as of release 4.3, private method inWorkflowProcessingService
This method gets called by its predecessors in the workflow. It checks if its conditions for activation are met and calls the activate() method if so.
-
decide
@Deprecated public void decide()
Deprecated.since ages - as of release 4.3, please useWorkflowProcessingService.decideAction(WorkflowActionModel, de.hybris.platform.workflow.model.WorkflowDecisionModel)
completes the workflow action and activates the selected decision
- Throws:
WorkflowActionDecideException
- if user is not assigned principal but ignores it for automated workflow actions
-
getDecisionByName
public WorkflowDecision getDecisionByName(java.lang.String name)
Deprecated.Returns the decision with the given name, if this action has no such decision, returns null.- Parameters:
name
-- Returns:
- The WorkflowDecision with the given name. If there is no such WorkflowDecision it returns null.
-
getIncomingLinks
@Deprecated public java.util.List<Link> getIncomingLinks(SessionContext ctx)
Deprecated.since ages - as of release 4.3, private method inWorkflowProcessingService
Description copied from class:GeneratedWorkflowAction
Generated method - Getter of theWorkflowAction.incomingLinks
attribute.- Specified by:
getIncomingLinks
in classGeneratedWorkflowAction
- Returns:
- the incomingLinks
-
getIncomingLinksStr
public java.lang.String getIncomingLinksStr(SessionContext ctx)
Deprecated.Description copied from class:GeneratedWorkflowAction
Generated method - Getter of theWorkflowAction.incomingLinksStr
attribute.- Specified by:
getIncomingLinksStr
in classGeneratedWorkflowAction
- Returns:
- comma seperated string with all action with decisions linking on this action
-
getDecisionsCount
@Deprecated public long getDecisionsCount()
Deprecated.since ages - as of release 4.3, useWorkflowActionModel.getDecisions()
Returns the number of decisions of this workflow action
- Returns:
- number of decisions
-
getAttachmentItems
public java.util.List<Item> getAttachmentItems(SessionContext ctx)
Deprecated.Description copied from class:GeneratedWorkflowAction
Generated method - Getter of theWorkflowAction.attachmentItems
attribute.- Specified by:
getAttachmentItems
in classGeneratedWorkflowAction
- Returns:
- the attachmentItems
-
isUserAssignedPrincipal
@Deprecated public boolean isUserAssignedPrincipal()
Deprecated.since ages - as of release 4.3, please useWorkflowActionService.isUserAssignedPrincipal(de.hybris.platform.workflow.model.WorkflowActionModel)
checks if the user is a assigned principal for this action
- Returns:
- whether the user is a assigned principal
-
-