Package de.xima.fc.entities
Class AWorkflowElement<TElement extends IWorkflowElementEntity,TSearchTerm extends AWorkflowElementSearchTerm<TElement>>
- java.lang.Object
-
- de.xima.cmn.dao.model.AEntity<Long>
-
- de.xima.fc.entities.AbstractEntity
-
- de.xima.fc.entities.AbstractLockableEntity
-
- de.xima.fc.entities.AWorkflowElement<TElement,TSearchTerm>
-
- Type Parameters:
TElement- Type of the workflow element entity.TSearchTerm- Type of the workflow element search term entity.
- All Implemented Interfaces:
de.xima.cmn.dao.interfaces.IEntity<Long>,de.xima.cmn.dao.interfaces.ILockableEntity<Long>,IDescriptionProviding,ILockingVersionProviding,INameProviding,ITransferable,ITransferableEntity,ITransferableLockableEntity,IUUIDEntity,IActiveFlagProviding,ICustomParametersProviding,IElementKeyProviding,IElementSearchTermsProviding,IIdProviding<Long>,IUuidProviding,IVersionedCustomParametersProviding,IWorkflowElementEntity,IWorkflowElementTypeProviding,Serializable,Comparable<de.xima.cmn.dao.interfaces.IEntity<Long>>
- Direct Known Subclasses:
WorkflowNode,WorkflowTrigger
@MappedSuperclass public abstract class AWorkflowElement<TElement extends IWorkflowElementEntity,TSearchTerm extends AWorkflowElementSearchTerm<TElement>> extends AbstractLockableEntity implements IUUIDEntity, IWorkflowElementEntity
Base class for workflow elements, i.e. nodes and triggers.- Since:
- 7.0.0
- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanactivestatic StringATTR_ACTIVEJPA attribute name for theisActive()field.static StringATTR_CUSTOM_PARAMETERSJPA attribute name for thegetCustomParameters()field.static StringATTR_CUSTOM_PARAMETERS_VERSIONJPA attribute name for thegetCustomParametersVersion()field.static StringATTR_DESCRIPTIONJPA attribute name for thegetDescription()field.static StringATTR_SEARCH_TERMSJPA attribute name for theIElementSearchTermsProviding.getSearchTerms()field.static StringATTR_TASKJPA attribute name for thegetTask()field.static StringATTR_TYPEJPA attribute name for thegetType()field.static StringCOL_ACTIVEDatabase column name for theisActive()field.static StringCOL_CUSTOM_PARAMETERSDatabase column name for thegetCustomParameters()field.static StringCOL_CUSTOM_PARAMETERS_VERSIONDatabase column name for thegetCustomParametersVersion()field.static StringCOL_DESCRIPTIONDatabase column name for thegetDescription()field.static StringCOL_NAMEDatabase column name for thegetName()field.static StringCOL_TASKDatabase column name for thegetTask()field.static StringCOL_TYPEDatabase column name for thegetType()field.protected @NotNull @JsonObject StringcustomParametersprotected @NotNull StringcustomParametersVersionprotected @Size(max=1020) Stringdescriptionprotected @Size(max=100) Stringnameprotected @NotNull List<TSearchTerm>searchTermsprotected @NotNull WorkflowTasktaskprotected @NotEmpty Stringtypeprotected @NotNull UUIDuuid-
Fields inherited from class de.xima.fc.entities.AbstractLockableEntity
COL_LOCKINGVERSION, lockingVersion
-
Fields inherited from class de.xima.fc.entities.AbstractEntity
COL_ID, id
-
Fields inherited from interface de.xima.fc.entities.interfaces.IDescriptionProviding
ATTR_BESCHREIBUNG
-
Fields inherited from interface de.xima.fc.entities.interfaces.INameProviding
ATTR_NAME
-
Fields inherited from interface de.xima.fc.entities.interfaces.ITransferableEntity
IMPORT_ID, INVALID_ID
-
Fields inherited from interface de.xima.fc.entities.interfaces.IUUIDEntity
ATTR_UUID, COL_UUID, INVALID_UUID, INVALID_UUID_OBJECT, NULL_SAFE_UUID_TYPE, NULLABLE_UUID_TYPE, TYPE_NAME_UUID
-
-
Constructor Summary
Constructors Constructor Description AWorkflowElement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TElementcloneBasics()StringgetBeschreibung()StringgetCustomParameters()StringgetCustomParametersVersion()StringgetDescription()StringgetName()WorkflowTaskgetTask()StringgetType()UUIDgetUuid()StringgetUUID()Gets the UUID (universal unique identifier) that uniquely identifies this type of entity.UUIDgetUUIDObject()Gets the UUID (universal unique identifier) that uniquely identifies this type of entity.booleanisActive()voidsetActive(boolean active)voidsetCustomParameters(String customParameters)voidsetCustomParametersVersion(String customParametersVersion)voidsetDescription(String description)voidsetName(String name)voidsetSearchTerms(List<TSearchTerm> searchTerms)voidsetTask(WorkflowTask task)voidsetType(String type)voidsetUUID(String uuid)Sets the UUID (universal unique identifier) that uniquely identifies this type of entity.voidsetUUIDObject(UUID uuid)-
Methods inherited from class de.xima.fc.entities.AbstractLockableEntity
entityHasChanged, getLockingVersion, setLockingVersion, toString
-
Methods inherited from class de.xima.fc.entities.AbstractEntity
asIntValue, isPersisted, setId, setId
-
Methods inherited from class de.xima.cmn.dao.model.AEntity
compareTo, equals, getDBTableName, hashCode
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface de.xima.fc.interfaces.workflow.ICustomParametersProviding
getCustomParametersJson
-
Methods inherited from interface de.xima.fc.interfaces.workflow.IElementKeyProviding
getKey
-
Methods inherited from interface de.xima.fc.interfaces.workflow.IElementSearchTermsProviding
getSearchTerms
-
Methods inherited from interface de.xima.fc.interfaces.workflow.IIdProviding
getId
-
Methods inherited from interface de.xima.fc.interfaces.workflow.IWorkflowElementEntity
setCustomParametersJson
-
-
-
-
Field Detail
-
ATTR_ACTIVE
public static final String ATTR_ACTIVE
JPA attribute name for theisActive()field.- See Also:
- Constant Field Values
-
ATTR_CUSTOM_PARAMETERS
public static final String ATTR_CUSTOM_PARAMETERS
JPA attribute name for thegetCustomParameters()field.- See Also:
- Constant Field Values
-
ATTR_CUSTOM_PARAMETERS_VERSION
public static final String ATTR_CUSTOM_PARAMETERS_VERSION
JPA attribute name for thegetCustomParametersVersion()field.- See Also:
- Constant Field Values
-
ATTR_DESCRIPTION
public static final String ATTR_DESCRIPTION
JPA attribute name for thegetDescription()field.- See Also:
- Constant Field Values
-
ATTR_SEARCH_TERMS
public static final String ATTR_SEARCH_TERMS
JPA attribute name for theIElementSearchTermsProviding.getSearchTerms()field.- See Also:
- Constant Field Values
-
ATTR_TASK
public static final String ATTR_TASK
JPA attribute name for thegetTask()field.- See Also:
- Constant Field Values
-
ATTR_TYPE
public static final String ATTR_TYPE
JPA attribute name for thegetType()field.- See Also:
- Constant Field Values
-
COL_ACTIVE
public static final String COL_ACTIVE
Database column name for theisActive()field.- See Also:
- Constant Field Values
-
COL_CUSTOM_PARAMETERS
public static final String COL_CUSTOM_PARAMETERS
Database column name for thegetCustomParameters()field.- See Also:
- Constant Field Values
-
COL_CUSTOM_PARAMETERS_VERSION
public static final String COL_CUSTOM_PARAMETERS_VERSION
Database column name for thegetCustomParametersVersion()field.- See Also:
- Constant Field Values
-
COL_DESCRIPTION
public static final String COL_DESCRIPTION
Database column name for thegetDescription()field.- See Also:
- Constant Field Values
-
COL_NAME
public static final String COL_NAME
Database column name for thegetName()field.- See Also:
- Constant Field Values
-
COL_TASK
public static final String COL_TASK
Database column name for thegetTask()field.- See Also:
- Constant Field Values
-
COL_TYPE
public static final String COL_TYPE
Database column name for thegetType()field.- See Also:
- Constant Field Values
-
active
protected boolean active
-
customParameters
@NotNull @JsonObject protected @NotNull @JsonObject String customParameters
-
customParametersVersion
@NotNull protected @NotNull String customParametersVersion
-
description
@Size(max=1020) protected @Size(max=1020) String description
-
name
@Size(max=100) protected @Size(max=100) String name
-
searchTerms
@NotNull protected @NotNull List<TSearchTerm extends AWorkflowElementSearchTerm<TElement>> searchTerms
-
task
@NotNull protected @NotNull WorkflowTask task
-
type
@NotEmpty protected @NotEmpty String type
-
uuid
@NotNull protected @NotNull UUID uuid
-
-
Method Detail
-
cloneBasics
public TElement cloneBasics()
- Returns:
- A new workflow element instance with all fields that do not reference other entities copied from this instance.
-
getBeschreibung
public String getBeschreibung()
- Specified by:
getBeschreibungin interfaceIDescriptionProviding
-
getCustomParameters
public String getCustomParameters()
- Specified by:
getCustomParametersin interfaceICustomParametersProviding- Returns:
- A JSON string holding the custom parameters.
-
getCustomParametersVersion
public String getCustomParametersVersion()
- Specified by:
getCustomParametersVersionin interfaceIVersionedCustomParametersProviding- Returns:
- The version of the custom parameters. You can, for example, store the version of the product that create the custom parameters here. Then you can use this to update the the parameters for later product versions.
-
getDescription
public String getDescription()
- Specified by:
getDescriptionin interfaceIDescriptionProviding- Returns:
- A human-readable description for this object.
-
getName
public String getName()
- Specified by:
getNamein interfaceINameProviding- Returns:
- The name of this object.
-
getTask
public WorkflowTask getTask()
- Returns:
- The task to which this workflow element belongs.
-
getType
public String getType()
- Specified by:
getTypein interfaceIWorkflowElementTypeProviding- Returns:
- The type of this workflow element. See
EWorkflowEventNameandEWorkflowNodeKindfor a list of built-in types.
-
getUuid
public UUID getUuid()
- Specified by:
getUuidin interfaceIUuidProviding- Returns:
- The UUID that identifies this instance.
-
getUUID
public String getUUID()
Description copied from interface:IUUIDEntityGets the UUID (universal unique identifier) that uniquely identifies this type of entity. Whether the UUID must be globally unique or only with within a context depends on the type of entity. Common contexts are for exampleclient scopesorproject scope.- Specified by:
getUUIDin interfaceIUUIDEntity- Returns:
- The UUID of the entity.
-
getUUIDObject
public UUID getUUIDObject()
Description copied from interface:IUUIDEntityGets the UUID (universal unique identifier) that uniquely identifies this type of entity. Whether the UUID must be globally unique or only with within a context depends on the type of entity. Common contexts are for exampleclient scopesorproject scope.- Specified by:
getUUIDObjectin interfaceIUUIDEntity- Returns:
- A unique identifier for this workflow element. This ID must be unique at least among all elements of the
WorkflowProcessto which this element belongs.
-
isActive
public boolean isActive()
- Specified by:
isActivein interfaceIActiveFlagProviding- Returns:
- {code true} if this instance is considered active, enabled etc. The exact meaning depends on the type.
-
setActive
public void setActive(boolean active)
- Parameters:
active- Whether this workflow element is active. Inactive elements are not processed.
-
setCustomParameters
public void setCustomParameters(String customParameters)
- Specified by:
setCustomParametersin interfaceIWorkflowElementEntity- Parameters:
customParameters- The custom parameters JSON string that is then returned byICustomParametersProviding.getCustomParameters().
-
setCustomParametersVersion
public void setCustomParametersVersion(String customParametersVersion)
- Specified by:
setCustomParametersVersionin interfaceIVersionedCustomParametersProviding- Parameters:
customParametersVersion- The custom parameters version string that is then returned byIVersionedCustomParametersProviding.getCustomParametersVersion().
-
setDescription
public void setDescription(String description)
- Parameters:
description- The human-readable description of this workflow element.
-
setName
public void setName(String name)
- Parameters:
name- The name of this workflow element.
-
setSearchTerms
public void setSearchTerms(List<TSearchTerm> searchTerms)
- Parameters:
searchTerms- A list of search terms for filtering database queries.
-
setTask
public void setTask(WorkflowTask task)
- Parameters:
task- The task to which this workflow element belongs.
-
setType
public void setType(String type)
- Parameters:
type- The type of this workflow element. SeeEWorkflowEventNameandEWorkflowNodeKindfor a list of built-in types.
-
setUUID
public void setUUID(String uuid)
Description copied from interface:IUUIDEntitySets the UUID (universal unique identifier) that uniquely identifies this type of entity. Whether the UUID must be globally unique or only with within a context depends on the type of entity. Common contexts are for exampleclient scopesorproject scope.- Specified by:
setUUIDin interfaceIUUIDEntity- Parameters:
uuid- The UUID of the entity.
-
setUUIDObject
public void setUUIDObject(UUID uuid)
- Parameters:
uuid- A unique identifier for this workflow element. This ID must be unique at least among all elements of theWorkflowProcessto which this element belongs.
-
-