Package com.appiancorp.suiteapi.process
Class ProcessModel.Descriptor
java.lang.Object
com.appiancorp.suiteapi.common.LocalizedIdentity
com.appiancorp.suiteapi.process.ProcessModel.Descriptor
- All Implemented Interfaces:
Serializable
- Enclosing class:
- ProcessModel
Inner class that holds the name, id, and description of a process model.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
Sort constant indicating that a grid ofProcessModel
s is sorted based on the description field.static final int
Sort constant indicating that a grid ofProcessModel
s is sorted based on the name field.static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
static final Integer
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGets the use that created this model.Gets the localized description of this model.int
Returns int representation of the Process Execution Environment.boolean
Gets the folder in which this model is saved.Gets the user by whom this model is currently locked.boolean
Determines whether the priority of this model can be chagned.Retrieve the model name, escaped into its Javascript String form (eg a tab becomes the characters '\\' and 't').int
Gets the object type, for use by UI components.Gets the set of permissions that the logged-in user has on this model.Gets the priority of this model.static int
getSortProperty
(String attribute_) Gets the sort property id that corresponds to the given attribute.Gets the time at which this model was created.Gets a pretty version of the time at which this model was created, useful for displaying.Gets the time at which this model was last updated.Gets a pretty version of the time at which this model was last updated, useful for displaying.getUuid()
Gets the universally unique identifier (uuid) for this model.Gets the version of this model.int
Gets the version status of this model.boolean
Determines whether or not this model is enabled.boolean
Determines whether this model is validated.void
setCreatorUsername
(String creatorUsername_) Sets the use that created this model.void
setDashboardId
(Long dashboardId_) void
setDescription
(LocaleString description_) Sets the localized description of the process model.void
setEnabled
(boolean enabled_) Sets whether or not this model is enabled.void
setExecutionEnvironment
(int executionEnvironment_) Set the execution environment in which the process will be run.void
setFavorite
(boolean favorite_) void
setFolderId
(Long folderId_) Sets the folder in which this model is saved.void
setLastModifiedUsername
(String lastModifiedUsername) void
setLockedBy
(String lockedBy_) Sets the user by whom this model is currently locked.void
setMutablePriority
(boolean mutablePriority_) Sets whether or not the priority of processes of this process model can be changedvoid
setObjectType
(int objectType_) Sets the object type for this model, which should always beAppianType.PROCESS_MODEL
.void
setPermissions
(ProcessModelPermissions permissions_) Sets the set of permissions that the logged-in user has on this model.void
setPriority
(Priority priority_) Sets the priority of this model.void
setTimeStampCreated
(Timestamp timeStampCreated_) Sets the time at which this model was created.void
setTimeStampUpdated
(Timestamp timeStampUpdated_) Sets the time at which this model was last updated.void
Sets the universally unique identifier (uuid) for this model.void
setValidated
(boolean validated_) Sets whether this model is validated.void
setVersion
(String version_) Gets the version of this model.void
setVersionStatus
(int versionStatus_) Sets the version status of this model.toString()
Returns a string representation of theLocalizedIdentity
.
-
Field Details
-
SORT_BY_NAME
public static final int SORT_BY_NAMESort constant indicating that a grid ofProcessModel
s is sorted based on the name field.- See Also:
-
SORT_BY_DESCRIPTION
public static final int SORT_BY_DESCRIPTIONSort constant indicating that a grid ofProcessModel
s is sorted based on the description field.- See Also:
-
SORT_PM_ID
-
SORT_PM_NAME
-
SORT_PM_DESCRIPTION
-
SORT_PM_VALIDATED
-
SORT_PM_LOCKEDBY
-
SORT_PM_VERSIONSTATUS
-
SORT_PM_VERSION
-
SORT_PM_CREATORUSERNAME
-
SORT_PM_TIMESTAMPCREATED
-
SORT_PM_TIMESTAMPUPDATED
-
SORT_PM_FOLDERID
-
SORT_PM_UUID
-
-
Constructor Details
-
Descriptor
public Descriptor()
-
-
Method Details
-
getNameEscapeJavascript
Retrieve the model name, escaped into its Javascript String form (eg a tab becomes the characters '\\' and 't'). -
getUuid
@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) public String getUuid()Gets the universally unique identifier (uuid) for this model. This identifier is important for comparing versions when importing and exporting models.- Returns:
- the uuid for this model.
-
setUuid
Sets the universally unique identifier (uuid) for this model. This identifier is important for comparing versions when importing and exporting models.- Parameters:
uuid_
- the uuid for this model, as aString
.
-
getTimeStampCreatedPretty
Gets a pretty version of the time at which this model was created, useful for displaying.- Returns:
- the time at which this model was created, in mm/dd/yyyy hh:mm xM format.
-
getTimeStampUpdatedPretty
Gets a pretty version of the time at which this model was last updated, useful for displaying.- Returns:
- the time at which this model was last updated, in mm/dd/yyyy hh:mm xM format.
-
getExecutionEnvironment
public int getExecutionEnvironment()Returns int representation of the Process Execution Environment. K Execution Environment: 0 EPEx Execution environment: 1- Returns:
- int corresponding to the process execution environment
-
setExecutionEnvironment
public void setExecutionEnvironment(int executionEnvironment_) Set the execution environment in which the process will be run. Return Illegal Argument Exception if int does not correspond with a defined execution environment- Parameters:
executionEnvironment_
- - int 0 for K; 1 for EPEx
-
isEnabled
public boolean isEnabled()Determines whether or not this model is enabled.- Returns:
true
if this model is enabled,false
otherwise.
-
setEnabled
public void setEnabled(boolean enabled_) Sets whether or not this model is enabled.- Parameters:
enabled_
-true
if this model is enabled,false
otherwise.
-
getPermissions
Gets the set of permissions that the logged-in user has on this model.- Returns:
- the permissions that the logged-in user has on this model.
-
setPermissions
Sets the set of permissions that the logged-in user has on this model.- Parameters:
permissions_
- the permissions that the logged-in user has on this model.
-
getFolderId
Gets the folder in which this model is saved.- Returns:
- the id of folder in which this model is saved.
-
setFolderId
Sets the folder in which this model is saved.- Parameters:
folderId_
- the id of the folder in which this model is saved.
-
isValidated
public boolean isValidated()Determines whether this model is validated.- Returns:
true
if this model is validated,false
otherwise.
-
setValidated
public void setValidated(boolean validated_) Sets whether this model is validated.- Parameters:
validated_
-true
if this model is validated,false
otherwise.
-
getLockedBy
Gets the user by whom this model is currently locked.- Returns:
- the username of the user by whom this model is locked, or
null
if this model is unlocked.
-
setLockedBy
Sets the user by whom this model is currently locked.- Parameters:
lockedBy_
- the username of the user by whom this model is locked, ornull
if this model is unlocked.
-
getVersion
Gets the version of this model.- Returns:
- the version of the process model, as a String holding a dot-separated number (such as 1.3.0).
-
setVersion
Gets the version of this model.- Parameters:
version_
- the version of the process model, as a String holding a dot-separated number (such as 1.3.0).
-
getTimeStampCreated
Gets the time at which this model was created.- Returns:
- the time the process model was created.
-
setTimeStampCreated
Sets the time at which this model was created.- Parameters:
timeStampCreated_
- the time the process model was created.
-
getTimeStampUpdated
Gets the time at which this model was last updated.- Returns:
- the time the process model was last updated.
-
setTimeStampUpdated
Sets the time at which this model was last updated.- Parameters:
timeStampUpdated_
- the time the process model was last updated.
-
getCreatorUsername
Gets the use that created this model.- Returns:
- the username of the user that created this model.
-
setCreatorUsername
Sets the use that created this model.- Parameters:
creatorUsername_
- the username of the user that created this model.
-
getVersionStatus
public int getVersionStatus()Gets the version status of this model.- Returns:
- the status of this version, as one of the
STATUS_XXX
constants.
-
setVersionStatus
public void setVersionStatus(int versionStatus_) Sets the version status of this model.- Parameters:
versionStatus_
- the status of this version, as one of theSTATUS_XXX
constants.
-
getDescription
Gets the localized description of this model.- Returns:
- a description of this model.
-
setDescription
Sets the localized description of the process model.- Parameters:
description_
- a description of this model.
-
getSortProperty
Gets the sort property id that corresponds to the given attribute.- Parameters:
attribute_
- the name of a property of the model descriptor- Returns:
- the id of the sort column for the attribute, as one of the
SORT_XXX
constants.
-
getObjectType
public int getObjectType()Gets the object type, for use by UI components. The object type is alwaysAppianType.PROCESS_MODEL
.- Returns:
TypedVariable.PROCESS_MODEL
.
-
setObjectType
public void setObjectType(int objectType_) Sets the object type for this model, which should always beAppianType.PROCESS_MODEL
.- Parameters:
objectType_
- the object type for this model, which should always beTypedVariable.PROCESS_MODEL
.
-
getDashboardId
-
setDashboardId
-
getFavorite
public boolean getFavorite() -
setFavorite
public void setFavorite(boolean favorite_) -
toString
Description copied from class:LocalizedIdentity
Returns a string representation of theLocalizedIdentity
. In general, the toString method returns a string that "textually represents" this object. Note that the name value will be the encode representation.- Overrides:
toString
in classLocalizedIdentity
- Returns:
- String representation of the object
-
getLastModifiedUsername
-
setLastModifiedUsername
-
getPriority
Gets the priority of this model.- Returns:
- the priority of this model.
-
setPriority
Sets the priority of this model.- Parameters:
priority_
- the priority of this model.
-
getMutablePriority
public boolean getMutablePriority()Determines whether the priority of this model can be chagned.- Returns:
true
if the priority can be change,false
if it cannot be changed.
-
setMutablePriority
public void setMutablePriority(boolean mutablePriority_) Sets whether or not the priority of processes of this process model can be changed- Parameters:
mutablePriority_
-true
if the priority of processes of this model can be changed,false
if the priority cannot be changed.
-