Interface ProcessDesignService

All Superinterfaces:
ContextSensitiveSingletonService, Service

public interface ProcessDesignService extends ContextSensitiveSingletonService
The ProcessDesignService is used for creating and modifying ProcessModel which are organized by storing them in ProcessModelFolder objects. It also contains methods for handling the security of these objects. It mainly deals with the design of Process Models whereas the ProcessExecutionService deals with all aspects of starting and maintaining instances of a ProcessModel (Process).

A ProcessModelFolder can be created and modified with this service. Process models are organized into folders in the process model pickers.

ProcessModel objects created by this service can be run using the ProcessExecutionService.

When a ProcessModel is being designed it is considered a draft. When a designer is satisfied with their design he or she may save the ProcessModel using updateProcessModel(ProcessModel) and create a new version using versionProcessModel(ProcessModel). When a ProcessModel is first versioned it is given the version "1.0" and all subsequent versions are incremented by 1.0. Versions of a ProcessModel cannot be run until they are published, and a ProcessModel version cannot be published unless it is valid. A ProcessModel can be validated using the validateProcessModel(ProcessModel) method.

A ProcessModel can be locked by a user so that no other users can edit the ProcessModel. However, a User can attempt to override the lock placed on a ProcessModel by another User by calling lockProcessModel(Long,boolean) or unlockProcessModel(Long,boolean) and setting the override boolean to true.

In addition to regular ProcessNode objects a ProcessModel can contain other ProcessModel objects through sub and linked processes.
A sub-process is a node which contains a ProcessModel. This node is considered a single node by the parent ProcessModel. When a sub-process node is reached during process execution the sub-process is started and the sub-process node is considered active. The node does not complete until the sub-process has completed.
A linked-process is a node which starts an instance of a ProcessModel. Once the linked-process has been started the linked-process node is considered complete by the parent Process.

As mentioned above, this service contains methods relating to the security and permissions of various objects. The permissions which can be obtained through this service include: getPermissionsForFolder(Long), #getPermissionsForPalette(Long), getPermissionsForProcessApplication(), and getPermissionsForProcessModel(Long). These methods should be used when determining which actions a User can perform on the corresponding object. Permissions are obtained through ProcessModelPermissions. These may be referenced to determine whether a user has sufficient privileges to perform a particular action.

Methods of service classes can all throw the unchecked exception ServiceException if any system-level error (for example, server failure) occurs, and will in general throw a checked exception (InvalidXXXException) when an entity to be retrieved is inaccessible, instead of returning null. Exceptions to this paradigm (including the use of ResultList as described below) are noted. All checked exceptions extend AppianException.

It may be necessary to retrieve a subset of results as opposed to an entire collection, and also to sort the subset by some property of the returned object. "Paging" methods which return a ResultPage are provided in certain instances for this purpose. The ResultPage will contain the sorted subset of results (via Result.getResults()), and the total number of items in the available result set (via ResultPage.getAvailableItems()).

It may also be necessary to retrieve some results, even if all results cannot be retrieved (for instance, some of the entities corresponding to a list of entity IDs may no longer exist). Methods which return a ResultList are provided for this purpose. The Result.getResults() method in this case will return all results which can be retrieved. In addition, there will be a list of result codes (ResultList.getResultCodes()) that represent the successful retrieval of an entity, or, if the entity could not be retrieved, the reason for the failure. See the CODE_XXX constants in ResultList for details.

See Also:
  • Field Details

    • DOES_NOT_RECURSE

      static final int DOES_NOT_RECURSE
      Indicates that there is no recursion in the process model, the subprocess model, or between the process model and sub-process model
      See Also:
    • PARENT_PROCESS_RECURSES

      static final int PARENT_PROCESS_RECURSES
      Indicates that the parent process model recurses (including the situation where the parent recurses through addition of the sub-process model)
      See Also:
    • SUBPROCESS_RECURSES

      static final int SUBPROCESS_RECURSES
      Indicates that any sub-process of the parent process recurses
      See Also:
    • EMBEDDED

      static final int EMBEDDED
      Sub-process is embedded in the parent process
      See Also:
    • INDEPENDENT

      static final int INDEPENDENT
      Sub-process is independent of the parent process
      See Also:
    • ALL

      static final int ALL
      All possible sub-process states
      See Also:
    • UNPUBLISHED_CHILDREN_VIEW_PERMISSIONS

      static final Integer UNPUBLISHED_CHILDREN_VIEW_PERMISSIONS
      Get unpublished children failed because the user did not have view permissions
    • UNPUBLISHED_CHILDREN_INVALID

      static final Integer UNPUBLISHED_CHILDREN_INVALID
      Get unpublished children failed because the process model specified did not exist
    • UNPUBLISHED_CHILDREN_PUBLISH_PERMISSIONS

      static final Integer UNPUBLISHED_CHILDREN_PUBLISH_PERMISSIONS
      Get unpublished children failed because the process model specified did not exist
    • UNPUBLISHED_CHILDREN_SUCCESS

      static final Integer UNPUBLISHED_CHILDREN_SUCCESS
      Get unpublished children failed because the user did not have publish permissions
    • createProcessModel$UPDATES

      static final boolean createProcessModel$UPDATES
      See Also:
    • updateProcessModel$UPDATES

      static final boolean updateProcessModel$UPDATES
      See Also:
    • getProcessModel$UPDATES

      static final boolean getProcessModel$UPDATES
      See Also:
    • exportProcessModel$UPDATES

      static final boolean exportProcessModel$UPDATES
      See Also:
    • listProcessModels$UPDATES

      static final boolean listProcessModels$UPDATES
      See Also:
    • getActivityClassSchemas$UPDATES

      static final boolean getActivityClassSchemas$UPDATES
      See Also:
    • getActivityClassSchema$UPDATES

      static final boolean getActivityClassSchema$UPDATES
      See Also:
    • getACSchemaByLocalId$UPDATES

      static final boolean getACSchemaByLocalId$UPDATES
      See Also:
    • startProcess$UPDATES

      static final boolean startProcess$UPDATES
      See Also:
    • startProcessWithPriority$UPDATES

      static final boolean startProcessWithPriority$UPDATES
      See Also:
    • initiateProcess$UPDATES

      static final boolean initiateProcess$UPDATES
      See Also:
    • getProcessModelsForGroup$UPDATES

      static final boolean getProcessModelsForGroup$UPDATES
      See Also:
    • getProcessModelDetails$UPDATES

      static final boolean getProcessModelDetails$UPDATES
      See Also:
    • getFormConfig$UPDATES

      static final boolean getFormConfig$UPDATES
      See Also:
    • getFormConfigForVersion$UPDATES

      static final boolean getFormConfigForVersion$UPDATES
      See Also:
    • isStartFormCapable$UPDATES

      static final boolean isStartFormCapable$UPDATES
      See Also:
    • getMyProcessModels$UPDATES

      static final boolean getMyProcessModels$UPDATES
      See Also:
    • getProcessModelsICanStart$UPDATES

      static final boolean getProcessModelsICanStart$UPDATES
      See Also:
    • getProcessModels$UPDATES

      static final boolean getProcessModels$UPDATES
      See Also:
    • getProcessModelParameters$UPDATES

      static final boolean getProcessModelParameters$UPDATES
      See Also:
    • getVisibleProcessVariables$UPDATES

      static final boolean getVisibleProcessVariables$UPDATES
      See Also:
    • getAssigneePoolACSchemas$UPDATES

      static final boolean getAssigneePoolACSchemas$UPDATES
      See Also:
    • getAssignmentPoolACSchemas$UPDATES

      static final boolean getAssignmentPoolACSchemas$UPDATES
      See Also:
    • activateUserSession$UPDATES

      static final boolean activateUserSession$UPDATES
      See Also:
    • getEscalationACSchemas$UPDATES

      static final boolean getEscalationACSchemas$UPDATES
      See Also:
    • deleteProcessModel$UPDATES

      static final boolean deleteProcessModel$UPDATES
      See Also:
    • deleteProcessModels$UPDATES

      static final boolean deleteProcessModels$UPDATES
      See Also:
    • getProcessModelDescriptor$UPDATES

      static final boolean getProcessModelDescriptor$UPDATES
      See Also:
    • getRecursiveRelationship$UPDATES

      static final boolean getRecursiveRelationship$UPDATES
      See Also:
    • getSubProcessModelDescriptorsForProcessModel$UPDATES

      static final boolean getSubProcessModelDescriptorsForProcessModel$UPDATES
      See Also:
    • getSynchronousSubProcessModelDescriptorsForProcessModel$UPDATES

      static final boolean getSynchronousSubProcessModelDescriptorsForProcessModel$UPDATES
      See Also:
    • getProcessModelDescriptorsContainingSubProcessModel$UPDATES

      static final boolean getProcessModelDescriptorsContainingSubProcessModel$UPDATES
      See Also:
    • getProcessModelDescriptorsContainingSynchronousSubProcessModel$UPDATES

      static final boolean getProcessModelDescriptorsContainingSynchronousSubProcessModel$UPDATES
      See Also:
    • getTopLevelProcessModelDescriptorsForSubProcessModel$UPDATES

      static final boolean getTopLevelProcessModelDescriptorsForSubProcessModel$UPDATES
      See Also:
    • getTopLevelProcessModelDescriptorsForSynchronousSubProcessModel$UPDATES

      static final boolean getTopLevelProcessModelDescriptorsForSynchronousSubProcessModel$UPDATES
      See Also:
    • getLinkProcessModelDescriptorsForProcessModel$UPDATES

      static final boolean getLinkProcessModelDescriptorsForProcessModel$UPDATES
      See Also:
    • getAsynchronousSubProcessModelDescriptorsForProcessModel$UPDATES

      static final boolean getAsynchronousSubProcessModelDescriptorsForProcessModel$UPDATES
      See Also:
    • getProcessModelDescriptorsContainingLinkProcessModel$UPDATES

      static final boolean getProcessModelDescriptorsContainingLinkProcessModel$UPDATES
      See Also:
    • getProcessModelDescriptorsContainingAsynchronousSubProcessModel$UPDATES

      static final boolean getProcessModelDescriptorsContainingAsynchronousSubProcessModel$UPDATES
      See Also:
    • getTopLevelProcessModelDescriptorsForLinkProcessModel$UPDATES

      static final boolean getTopLevelProcessModelDescriptorsForLinkProcessModel$UPDATES
      See Also:
    • getTopLevelProcessModelDescriptorsForAsynchronousSubProcessModel$UPDATES

      static final boolean getTopLevelProcessModelDescriptorsForAsynchronousSubProcessModel$UPDATES
      See Also:
    • getSecurityForProcessApplication$UPDATES

      static final boolean getSecurityForProcessApplication$UPDATES
      See Also:
    • setSecurityForProcessApplication$UPDATES

      static final boolean setSecurityForProcessApplication$UPDATES
      See Also:
    • getSecurityForProcessModel$UPDATES

      static final boolean getSecurityForProcessModel$UPDATES
      See Also:
    • setSecurityForProcessModel$UPDATES

      static final boolean setSecurityForProcessModel$UPDATES
      See Also:
    • setActorsInRolesForProcessApplication$UPDATES

      static final boolean setActorsInRolesForProcessApplication$UPDATES
      See Also:
    • setActorsInRolesForProcessModel$UPDATES

      static final boolean setActorsInRolesForProcessModel$UPDATES
      See Also:
    • getPermissionsForProcessApplication$UPDATES

      static final boolean getPermissionsForProcessApplication$UPDATES
      See Also:
    • getPermissionsForProcessModel$UPDATES

      static final boolean getPermissionsForProcessModel$UPDATES
      See Also:
    • getPermissionsForProcessModels$UPDATES

      static final boolean getPermissionsForProcessModels$UPDATES
      See Also:
    • getPriority$UPDATES

      static final boolean getPriority$UPDATES
      See Also:
    • getDefaultPriority$UPDATES

      static final boolean getDefaultPriority$UPDATES
      See Also:
    • setDefaultPriority$UPDATES

      static final boolean setDefaultPriority$UPDATES
      See Also:
    • getPriorityOfProcessModel$UPDATES

      static final boolean getPriorityOfProcessModel$UPDATES
      See Also:
    • setPriorityOfProcessModel$UPDATES

      static final boolean setPriorityOfProcessModel$UPDATES
      See Also:
    • lockProcessModel$UPDATES

      static final boolean lockProcessModel$UPDATES
      See Also:
    • getProcessModelVersion$UPDATES

      static final boolean getProcessModelVersion$UPDATES
      See Also:
    • exportProcessModelVersion$UPDATES

      static final boolean exportProcessModelVersion$UPDATES
      See Also:
    • versionProcessModel$UPDATES

      static final boolean versionProcessModel$UPDATES
      See Also:
    • getProcessModelsForFolder$UPDATES

      static final boolean getProcessModelsForFolder$UPDATES
      See Also:
    • getChildFolders$UPDATES

      static final boolean getChildFolders$UPDATES
      See Also:
    • getTopLevelFolders$UPDATES

      static final boolean getTopLevelFolders$UPDATES
      See Also:
    • getVersionsForProcessModel$UPDATES

      static final boolean getVersionsForProcessModel$UPDATES
      See Also:
    • setActorsInRolesForFolder$UPDATES

      static final boolean setActorsInRolesForFolder$UPDATES
      See Also:
    • unlockProcessModel$UPDATES

      static final boolean unlockProcessModel$UPDATES
      See Also:
    • unlockProcessModels$UPDATES

      static final boolean unlockProcessModels$UPDATES
      See Also:
    • getFolder$UPDATES

      static final boolean getFolder$UPDATES
      See Also:
    • getFolders$UPDATES

      static final boolean getFolders$UPDATES
      See Also:
    • startProcessVersion$UPDATES

      static final boolean startProcessVersion$UPDATES
      See Also:
    • getProcessModelProperties$UPDATES

      static final boolean getProcessModelProperties$UPDATES
      See Also:
    • getMaximumNumberOfNotes$UPDATES

      static final boolean getMaximumNumberOfNotes$UPDATES
      See Also:
    • getMaximumNumberOfAttachments$UPDATES

      static final boolean getMaximumNumberOfAttachments$UPDATES
      See Also:
    • getUnpublishedChildrenForProcessModel$UPDATES

      static final boolean getUnpublishedChildrenForProcessModel$UPDATES
      See Also:
    • getParentsForProcessModel$UPDATES

      static final boolean getParentsForProcessModel$UPDATES
      See Also:
    • getParentsOfUnpublishedChildrenForProcessModel$UPDATES

      static final boolean getParentsOfUnpublishedChildrenForProcessModel$UPDATES
      See Also:
    • publishProcessModel$UPDATES

      static final boolean publishProcessModel$UPDATES
      See Also:
    • saveAndPublishProcessModel$UPDATES

      static final boolean saveAndPublishProcessModel$UPDATES
      See Also:
    • getVisibleProcessVariablesForVersion$UPDATES

      static final boolean getVisibleProcessVariablesForVersion$UPDATES
      See Also:
    • getProcessModelParametersForVersion$UPDATES

      static final boolean getProcessModelParametersForVersion$UPDATES
      See Also:
    • getCountProcessModelParametersForVersion$UPDATES

      static final boolean getCountProcessModelParametersForVersion$UPDATES
      See Also:
    • updateFolder$UPDATES

      static final boolean updateFolder$UPDATES
      See Also:
    • createFolder$UPDATES

      static final boolean createFolder$UPDATES
      See Also:
    • disableProcessModel$UPDATES

      static final boolean disableProcessModel$UPDATES
      See Also:
    • enableProcessModel$UPDATES

      static final boolean enableProcessModel$UPDATES
      See Also:
    • deleteFolders$UPDATES

      static final boolean deleteFolders$UPDATES
      See Also:
    • deleteFolder$UPDATES

      static final boolean deleteFolder$UPDATES
      See Also:
    • updateFolders$UPDATES

      static final boolean updateFolders$UPDATES
      See Also:
    • updateProcessModelsWithDescriptors$UPDATES

      static final boolean updateProcessModelsWithDescriptors$UPDATES
      See Also:
    • getSecurityForFolder$UPDATES

      static final boolean getSecurityForFolder$UPDATES
      See Also:
    • setSecurityForFolder$UPDATES

      static final boolean setSecurityForFolder$UPDATES
      See Also:
    • getProcessModelDescriptors$UPDATES

      static final boolean getProcessModelDescriptors$UPDATES
      See Also:
    • getProcessModelsLatestPublishedDescriptors$UPDATES

      static final boolean getProcessModelsLatestPublishedDescriptors$UPDATES
      See Also:
    • getProcessModelVersionDescriptor$UPDATES

      static final boolean getProcessModelVersionDescriptor$UPDATES
      See Also:
    • moveProcessModel$UPDATES

      static final boolean moveProcessModel$UPDATES
      See Also:
    • moveFolder$UPDATES

      static final boolean moveFolder$UPDATES
      See Also:
    • getPermissionsForFolder$UPDATES

      static final boolean getPermissionsForFolder$UPDATES
      See Also:
    • getPermissionsForFolders$UPDATES

      static final boolean getPermissionsForFolders$UPDATES
      See Also:
    • setInheritanceForFolder$UPDATES

      static final boolean setInheritanceForFolder$UPDATES
      See Also:
    • deleteProcessModelVersion$UPDATES

      static final boolean deleteProcessModelVersion$UPDATES
      See Also:
    • getBusinessEntity$UPDATES

      static final boolean getBusinessEntity$UPDATES
      See Also:
    • createBusinessEntity$UPDATES

      static final boolean createBusinessEntity$UPDATES
      See Also:
    • updateBusinessEntity$UPDATES

      static final boolean updateBusinessEntity$UPDATES
      See Also:
    • getProcessModelWebServices$UPDATES

      static final boolean getProcessModelWebServices$UPDATES
      See Also:
    • createProcessModelWebService$UPDATES

      static final boolean createProcessModelWebService$UPDATES
      See Also:
    • deleteProcessModelWebService$UPDATES

      static final boolean deleteProcessModelWebService$UPDATES
      See Also:
    • getProcessStartingInfo$UPDATES

      static final boolean getProcessStartingInfo$UPDATES
      See Also:
    • getProcessModelByUuid$UPDATES

      static final boolean getProcessModelByUuid$UPDATES
      See Also:
    • getProcessModelIdByUuid$UPDATES

      static final boolean getProcessModelIdByUuid$UPDATES
      See Also:
    • getProcessModelsAndDescendants$UPDATES

      static final boolean getProcessModelsAndDescendants$UPDATES
      See Also:
    • getProcessModelsForFolderStartableOnly$UPDATES

      static final boolean getProcessModelsForFolderStartableOnly$UPDATES
      See Also:
    • validateProcessModel$UPDATES

      static final boolean validateProcessModel$UPDATES
      See Also:
    • validateProcessModelVersion$UPDATES

      static final boolean validateProcessModelVersion$UPDATES
      See Also:
    • isProcessModelLocked$UPDATES

      static final boolean isProcessModelLocked$UPDATES
      See Also:
    • getProcessModelLatestPublishedVersion$UPDATES

      static final boolean getProcessModelLatestPublishedVersion$UPDATES
      See Also:
    • getProcessModelLatestPublishedVersionDescriptor$UPDATES

      static final boolean getProcessModelLatestPublishedVersionDescriptor$UPDATES
      See Also:
    • getACInstanceIdsForLocalIds$UPDATES

      static final boolean getACInstanceIdsForLocalIds$UPDATES
      See Also:
    • getACPInstanceIdsForLocalIds$UPDATES

      static final boolean getACPInstanceIdsForLocalIds$UPDATES
      See Also:
    • notifyUserCreation$UPDATES

      static final boolean notifyUserCreation$UPDATES
      See Also:
    • notifyUsersCreation$UPDATES

      static final boolean notifyUsersCreation$UPDATES
      See Also:
    • validateGroupMembership$UPDATES

      static final boolean validateGroupMembership$UPDATES
      See Also:
    • updateUsernames$UPDATES

      static final boolean updateUsernames$UPDATES
      See Also:
    • commitUpdateUsernames$UPDATES

      static final boolean commitUpdateUsernames$UPDATES
      See Also:
    • rollbackUpdateUsernames$UPDATES

      static final boolean rollbackUpdateUsernames$UPDATES
      See Also:
    • setApplicationAdministratorGroup$UPDATES

      static final boolean setApplicationAdministratorGroup$UPDATES
      See Also:
    • reloadProperties$UPDATES

      static final boolean reloadProperties$UPDATES
      See Also:
    • validate$UPDATES

      static final boolean validate$UPDATES
      See Also:
    • setSiteLocaleSettings$UPDATES

      static final boolean setSiteLocaleSettings$UPDATES
      See Also:
    • getEventsForProcessModelPaging$UPDATES

      static final boolean getEventsForProcessModelPaging$UPDATES
      See Also:
    • findEventsPaging$UPDATES

      static final boolean findEventsPaging$UPDATES
      See Also:
    • getEventOrProcessModelNames$UPDATES

      static final boolean getEventOrProcessModelNames$UPDATES
      See Also:
    • getProcessModelIdsByUuids$UPDATES

      static final boolean getProcessModelIdsByUuids$UPDATES
      See Also:
    • getEmailAttachmentFolderIdForPm$UPDATES

      static final boolean getEmailAttachmentFolderIdForPm$UPDATES
      See Also:
    • getPmIdForEvent$UPDATES

      static final boolean getPmIdForEvent$UPDATES
      See Also:
    • getEventsByPersistentId$UPDATES

      static final boolean getEventsByPersistentId$UPDATES
      See Also:
    • setDashboardPageForProcessModel$UPDATES

      static final boolean setDashboardPageForProcessModel$UPDATES
      See Also:
    • getDashboardPageForProcessModel$UPDATES

      static final boolean getDashboardPageForProcessModel$UPDATES
      See Also:
    • removeDashboardPageForProcessModel$UPDATES

      static final boolean removeDashboardPageForProcessModel$UPDATES
      See Also:
    • addProcessModelToFavorites$UPDATES

      static final boolean addProcessModelToFavorites$UPDATES
      See Also:
    • removeProcessModelFromFavorites$UPDATES

      static final boolean removeProcessModelFromFavorites$UPDATES
      See Also:
    • handleMessages$UPDATES

      static final boolean handleMessages$UPDATES
      See Also:
    • validateUsernames$UPDATES

      static final boolean validateUsernames$UPDATES
      See Also:
    • getProcessVariablesForModel$UPDATES

      static final boolean getProcessVariablesForModel$UPDATES
      See Also:
    • getCurrentNotePaths$UPDATES

      static final boolean getCurrentNotePaths$UPDATES
      See Also:
    • setCurrentNotePaths$UPDATES

      static final boolean setCurrentNotePaths$UPDATES
      See Also:
    • getExpressionDependencies$UPDATES

      static final boolean getExpressionDependencies$UPDATES
      See Also:
    • evaluateExpressionInVariableContext$UPDATES

      static final boolean evaluateExpressionInVariableContext$UPDATES
      See Also:
    • evaluateExpression$UPDATES

      static final boolean evaluateExpression$UPDATES
      See Also:
    • externalizeExpression$UPDATES

      static final boolean externalizeExpression$UPDATES
      See Also:
    • internalizeExpression$UPDATES

      static final boolean internalizeExpression$UPDATES
      See Also:
    • getRuleIdReferences$UPDATES

      static final boolean getRuleIdReferences$UPDATES
      See Also:
    • getRuleUuidReferences$UPDATES

      static final boolean getRuleUuidReferences$UPDATES
      See Also:
    • evaluateRule$UPDATES

      static final boolean evaluateRule$UPDATES
      See Also:
    • setProcessDashboardPageForProcessModel$UPDATES

      static final boolean setProcessDashboardPageForProcessModel$UPDATES
      See Also:
    • getProcessDashboardPageForProcessModel$UPDATES

      static final boolean getProcessDashboardPageForProcessModel$UPDATES
      See Also:
    • removeProcessDashboardPageForProcessModel$UPDATES

      static final boolean removeProcessDashboardPageForProcessModel$UPDATES
      See Also:
    • getLingeringTasksForProcessModel$UPDATES

      static final boolean getLingeringTasksForProcessModel$UPDATES
      See Also:
    • validateTypedValues$UPDATES

      static final boolean validateTypedValues$UPDATES
      See Also:
    • setTimeZone$UPDATES

      static final boolean setTimeZone$UPDATES
      See Also:
    • setTimeZoneSameAs$UPDATES

      static final boolean setTimeZoneSameAs$UPDATES
      See Also:
  • Method Details

    • createProcessModel

      Creates a ProcessModel in the database using the input parameter. The database generates primary keys and reconstitutes the model to create the return value.

      In order to create a model at least the following fields must be populated:

      For each process variable, the following fields must be populated: key, value, type, and multiple

      For each process node, the following fields must be populated: id, guiId, ownerId, ownerName, groupOwnerId, groupOwnerName, icon, paletteIcon, x, y, activityClass, preActivities (can be an empty array), postActivities (can be an empty array), connections (can be an empty array), notify, assign (if the node is attended), confirmationUrl (populated by default), schedule, escalations (can be an empty array), multipleInstance, notes (can be an empty array), attachments (can be an empty array), priority, targetCompletion (populated by default), and targetLag (populated by default).

      Within each process node, in the assign member, the following fields must be populated: assignees, multipleInstanceAssigneeType, assignmentFunction, and assignmentPosition

      Within each process node, in the activity class member, the following fields must be populated: acSchemaId, localId, parameters (can be an empty list), customParameters (can be an empty list), unattended, runAs (if it is unattended), outputExpressions (can be an empty list), formConfig (if it is attended), and helperClass.

      Within each activity class, for each activity class parameter, the following fields must be populated: acpSchemaId, expression, and validationMessages

      Parameters:
      pm_ - the ProcessModel to create
      Returns:
      the created ProcessModel, with IDs populated.
      Throws:
      PrivilegeException - if the current user does not have permission to perform this action
      InvalidFolderException - if the ProcessModelFolder does not exist
      InvalidPriorityException - if the Priority does not exist
      InvalidUserException - if any user referenced in the ProcessModel does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      DuplicateUuidException - if the UUID of the process model already exists
    • updateProcessModel

      Updates a process model in the database based on the input parameter. The database generates primary keys and reconstitutes the model to create the return value. The id and uuid fields are only used for retrieving the model and cannot be changed since they are assigned by the server in the first place.

      In order to update a model at least the following fields must be populated:

      For each process variable, the following fields must be populated: key, value, type, and multiple

      For each process node, the following fields must be populated: id, guiId, ownerId, ownerName, groupOwnerId, groupOwnerName, icon, paletteIcon, x, y, activityClass, preActivities (can be an empty array), postActivities (can be an empty array), connections (can be an empty array), notify, assign (if the node is attended), confirmationUrl (populated by default), schedule, escalations (can be an empty array), multipleInstance, notes (can be an empty array), attachments (can be an empty array), priority, targetCompletion (populated by default), and targetLag (populated by default).

      Within each process node, in the assign member, the following fields must be populated: assignees.

      Within each process node, in the activity class member, the following fields must be populated: acSchemaId, localId, parameters (can be an empty list), customParameters (can be an empty list), unattended, runAs (if it is unattended), outputExpressions (can be an empty list), formConfig (if it is attended), and helperClass.

      Within each activity class, for each activity class parameter, the following fields must be populated: acpSchemaId, expression, and validationMessages.

      Parameters:
      pm_ - the processModel to update
      Returns:
      the updated process model
      Throws:
      InvalidProcessModelException - if the process model does not exist
      PrivilegeException - if the user does not have privileges to update the process model
      LockException - if the process model is locked by someone other than the current user
      InvalidUuidException - if the specified uuid is used by another process model
      InvalidUserException - if any user referenced in the ProcessModel does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
      InvalidPriorityException
    • getProcessModel

      ProcessModel getProcessModel(Long processModelId_) throws PrivilegeException, InvalidProcessModelException
      Retrieve a working draft of a ProcessModel. If the information needed can be retrieved from ProcessModel.Descriptor consider calling the getProcessModelDescriptor(Long) method instead which is considerably faster.
      Parameters:
      processModelId_ - ID of the ProcessModel to retrieve
      Returns:
      The ProcessModel specified by processModelId_
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist
      PrivilegeException - if the current User does not have sufficient privileges to view the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • exportProcessModel

      ProcessModel exportProcessModel(Long processModelId_) throws PrivilegeException, InvalidProcessModelException
      Retrieve a working draft of a ProcessModel. Unlike getProcessModel(java.lang.Long), this API does not convert rule uuids to names (within expressions). Therefore this API should be used when retrieving a model for export.
      Parameters:
      processModelId_ - ID of the ProcessModel to retrieve
      Returns:
      The ProcessModel specified by processModelId_
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist
      PrivilegeException - if the current User does not have sufficient privileges to view the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • listProcessModels

      @Deprecated ProcessModel.Descriptor[] listProcessModels()
      Deprecated.
      Use getProcessModelDescriptors(Long[]) instead. This method performs poorly and should not be called.
      Lists descriptors representing the working drafts of all process models in the system.
      Returns:
      an array of descriptor objects which represent the process models in the system
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getActivityClassSchemas

      Identity[] getActivityClassSchemas(Long[] acsIds_) throws InvalidActivityClassSchemaException
      Retrieves a list of abbreviated ActivityClassSchema representations for the given IDs
      Parameters:
      acsIds_ - the activity class schema IDs
      Returns:
      An array of Identity objects which are abbreviated representations of ActivityClassSchema objects.
      Throws:
      InvalidActivityClassSchemaException - if ActivityClassSchema does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getActivityClassSchema

      ActivityClassSchema getActivityClassSchema(Long acsId_) throws InvalidActivityClassSchemaException
      Retrieves an ActivityClassSchema.
      Parameters:
      acsId_ - the ID of the ActivityClassSchema to retrieve.
      Returns:
      the ActivityClassSchema specified by acsId_
      Throws:
      InvalidActivityClassSchemaException - if the ActivityClassSchema specified by acsId_ does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getACSchemaByLocalId

      ActivityClassSchema getACSchemaByLocalId(String acsLocalId_) throws InvalidActivityClassSchemaException
      Retrieves an ActivityClassSchema by local id.
      Parameters:
      acsLocalId_ - the local ID of the ActivityClassSchema to retrieve.
      Returns:
      the ActivityClassSchema specified by acsLocalId_
      Throws:
      InvalidActivityClassSchemaException - if the ActivityClassSchema specified by acsId_ does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • startProcess

      Deprecated.
      Use initiateProcess(Long, ProcessStartConfig), which has better enforcement of required parameters (requires that their values not be null or empty)
      Starts an instance of the given process model, using the given variables to initialize state.

      The following fields must be populated for each ProcessVariable object: key, value, type, and multiple

      Parameters:
      processModelId_ - id of process model to start
      variables_ - parameters for the process model. If using a process variable of an Appian type, do not set the value to that object but instead to the corresponding primitive. For instance, do not assign a User process variable a User object. Instead, assign that process variable a String containing the username. Likewise, assign a process variable of type Group should be assigned a Long, etc. The exception to this rule is the People type. Process variables of type People should be assigned a LocalObject. Only the values are used for passed parameters, not expressions; expressions must be set on the process model at design time.
      Returns:
      The id of the started process instance.
      Throws:
      InvalidProcessModelException - if the referenced process model does not exist or has been deleted.
      PrivilegeException - if the user does not have permission to perform this action.
      InvalidStateException - if there is no published version of the specified pm, the published version is disabled, or if the process model contains sub process models that have been disabled or deleted. Note that all sub process models of a published process model must have been published, but they can still be disabled.
      InvalidUserException - if any user referenced in any ProcessVariable does not exist.
      IllegalArgumentException - if the ProcessModel requires process parameters to start, and the variables_ parameter is an empty array, or does not contain all necessary process parameters.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs.
      NullPointerException - if processModelId_ or variables_ array is null.
      Exception
      StorageLimitException
    • startProcessWithPriority

      Deprecated.
      Use initiateProcess(Long, ProcessStartConfig), which has better enforcement of required parameters (requires that their values not be null or empty)
      Starts an instance of the given process model, using the given variables to initialize state. The process will be started with the priority specified.
      Parameters:
      processModelId_ - id of process model to start
      variables_ - parameters for the process model. If using a process variable of an Appian type, do not set the value to that object but instead to the corresponding primitive. For instance, do not assign a User process variable a User object. Instead, assign that process variable a String containing the username. Likewise, assign a process variable of type Group should be assigned a Long, etc. The exception to this rule is the People type. Process variables of type People should be assigned a LocalObject.
      priorityId_ - the priority with which to start the process
      Returns:
      The id of the started process instance.
      Throws:
      InvalidPriorityException - if the Priority does not exist
      InvalidProcessModelException - if the ProcessModel does not exist
      PrivilegeException - if the user does not have permission to perform this action
      InvalidStateException - if there is no published version of the specified pm, the published version is disabled, or if the process model contains sub process models that have been disabled or deleted. Note that all sub process models of a published process model must have been published, but they can still be disabled.
      InvalidUserException - if any user referenced in any ProcessVariable does not exist
      IllegalArgumentException - if the ProcessModel requires process parameters to start, and the variables_ parameter is null, an empty array, or does not contain all necessary process parameters.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      Exception
    • initiateProcess

      Starts an instance of the given process model.
      Parameters:
      processModelId_ - id of process model to start
      config - additional configuration to control how the process is started
      Returns:
      The id of the started process instance.
      Throws:
      InvalidProcessModelException - if the referenced process model does not exist or has been deleted.
      PrivilegeException - if the user does not have permission to perform this action.
      InvalidStateException - if there is no published version of the specified pm, the published version is disabled, or if the process model contains sub process models that have been disabled or deleted. Note that all sub process models of a published process model must have been published, but they can still be disabled.
      InvalidUserException - if any user referenced in any ProcessVariable does not exist.
      IllegalArgumentException - if the ProcessModel requires process parameters to start, and any of the required parameters are missing or have not been given a value that is not null or empty.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs.
      NullPointerException - if processModelId_ or variables_ array is null.
      Exception
      InvalidPriorityException
      InvalidVersionException
      StorageLimitException
    • getProcessModelsForGroup

      @Deprecated ResultPage getProcessModelsForGroup(Long groupId_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_)
      Deprecated.
      Process models are no longer associated with groups, but rather are organized into folders. Use getProcessModelsForFolder(java.lang.Long, int, int, java.lang.Integer, java.lang.Integer)
      Retrieves process model descriptors objects for all process models owned by a group
      Parameters:
      groupId_ - ID of the Group for which to retrieve ProcessModel.Descriptor objects
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in ProcessModel.Descriptor
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      A ResultPage which contains an array of ProcessModel.Descriptor objects for each ProcessModel owned by the Group specified by groupId_
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDetails

      ProcessModelDetails getProcessModelDetails(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves ProcessModelDetails representing the working drafts of the given ProcessModel If only requiring FormConfig, see getFormConfig in this class.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the ProcessModelDetails
      Returns:
      A ProcessModelDetails which contains details about the ProcessModel specified by processModelId_
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getFormConfig

      FormConfig getFormConfig(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves the FormConfig of the draft of the given process model.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the FormConfig
      Returns:
      A FormConfig
      Throws:
      InvalidProcessModelException
      PrivilegeException
    • getFormConfigForVersion

      Retrieves the FormConfig of the given process model version.
      Parameters:
      processModelId - ID of the ProcessModel for which to retrieve the FormConfig
      version - version of the process model (use null to refer to a draft, or AbstractProcessModel.LATEST_PUBLISHED_VERSION to refer to the latest published version)
      Returns:
      A FormConfig
      Throws:
      InvalidProcessModelException
      InvalidVersionException
      InvalidStateException - if there is no published version of the specified pm, the published version is disabled, or if the process model contains sub process models that have been disabled or deleted. Note that all sub process models of a published process model must have been published, but they can still be disabled.
      PrivilegeException
    • isStartFormCapable

      ResultList isStartFormCapable(Long[] processModelIds, int capabilities)
      Retrieves a ResultList containing Boolean values representing whether the start form for the latest published version of each of the process models is capable of ALL the specified form capabilities. If the process model does not have a start form, this method will return a ResultList.CODE_VALID for that entry.
      Parameters:
      processModelIds - the process model ids
      capabilities - a bitwise OR of any of the following values: FormConfig.CAPABILITY_RENDER_WEB, FormConfig.CAPABILITY_RENDER_MOBILE
      Returns:
      a ResultList containing a Boolean value for each process model that is valid and has a published version. The result codes can be: ResultList.CODE_VALID if the process model exists and has the requested capability, ResultList.CODE_INVALID if the specified process model does not exist, does not have a published version or does not have the requested capability, or ResultList.CODE_NO_PERMISSION if the user does not have permission to view the given process model.
    • getMyProcessModels

      ProcessModel.Descriptor[] getMyProcessModels()
      Retrieves ProcessModel objects for which the current user is an owner.
      Returns:
      An array of ProcessModel.Descriptor objects which represent the ProcessModel objects owned by the current User
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any sytem-level error occurs
    • getProcessModelsICanStart

      ProcessModel.Descriptor[] getProcessModelsICanStart()
      Retrieves process model descriptors which represent the working drafts of the process models that the current user has permission to start
      Returns:
      ProcessModel.Descriptor objects for each ProcessModel which the current user can start.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModels

      @Deprecated ProcessModel[] getProcessModels(Long[] ids_)
      Deprecated.
      Retrieves multiple ProcessModel objects, representing the working drafts of the process models with the given IDs. This method will throw a PrivilegeException if an ID points to a ProcessModel to which the current user does not have "viewer" or higher privileges. If the information needed can be retrieved from ProcessModel.Descriptor consider calling the getProcessModelDescriptors(Long[]) method instead which is considerably faster.
      Parameters:
      ids_ - Unique IDs of the ProcessModel objects to retrieve
      Returns:
      The ProcessModel objects specified by ids_
      Throws:
      NullPointerException - if it is called with a null argument
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      PrivilegeException - if the user does not have "viewer" or higher privileges for any of the referenced ProcessModels.
    • getProcessModelParameters

      Retrieves all of the process variables that are required to start an instance of the given process model (ie. process parameters).
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the process parameters
      Returns:
      ProcessVariable objects which represent those variables which are required to start the given ProcessModel
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist.
      PrivilegeException - if the current User does not have permissions to get the ProcessModel's parameters
      InvalidStateException - if there is no published version of the specified pm, the published version is disabled, or if the process model contains sub process models that have been disabled or deleted. Note that all sub process models of a published process model must have been published, but they can still be disabled.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      Exception
    • getVisibleProcessVariables

      ProcessVariable[] getVisibleProcessVariables(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves all visible process variables associated with the given process model, or the process variables that are reportable through analytics and can be mapped in a subprocess relationship
      Parameters:
      processModelId_ - the unique Id of the process model to retrieve variables for
      Returns:
      the visible process variables of the process model specified
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist.
      PrivilegeException - if the current User does not have permissions to get the ProcessModel's parameters
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getAssigneePoolACSchemas

      ActivityClassSchema[] getAssigneePoolACSchemas()
      Retrieves the activity class schemas for the activity classes that operate on the assignee pool. The assignee pool contains all users and groups which can be assigned a task, as chosen at design time.
      Returns:
      An array of ActivityClassSchema objects which represent the functions that operate on the assignee pool.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getAssignmentPoolACSchemas

      ActivityClassSchema[] getAssignmentPoolACSchemas()
      Retrieves the activity class schemas for the activity classes that operate on the assignment pool. The assignment pool contains all users and groups which are assigned a task at execution time.
      Returns:
      An array of ActivityClassSchema objects which represent the functions that operate on the assignment pool.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • activateUserSession

      void activateUserSession(Long[] membership_, Long[] administration_, Long userTypeId_, String username) throws InvalidUserException
      Notifies the Process application that a new session has been created for the current user, and provides information about the current user's membership and administration rights to groups.

      This method should be called every time the group membership role of the current user is changed (eg: from member to admin, etc), or when a new group is created, or when the current user was newly created. This method will skip any null values for membership_ or administration_. If the userTypeId_ is null, the method will fail but will NOT throw any exceptions

      Parameters:
      membership_ - An array of group IDs which represent the groups to which the current user belongs.
      administration_ - An array of group IDs which represent the groups for which the current user is an administrator.
      userTypeId_ - this is one of UserProfile.USER_TYPE_BASIC or UserProfile.USER_TYPE_SYS_ADMIN. If neither or null is given, UserProfile.USER_TYPE_BASIC will be assumed.
      username - the username of the user whose session is to be activated
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      InvalidUserException
    • getEscalationACSchemas

      ActivityClassSchema[] getEscalationACSchemas()
      Retrieves the activity class schemas for activities that can be used as escalations.
      Returns:
      An array of ActivityClassSchema objects which represent all activity classes of type Escalation
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • deleteProcessModel

      void deleteProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Deletes a process model. A model can be deleted even if there are processes that have been created from it on any of the execution servers. These processes will continue after the process model has been deleted. To delete processes, use ProcessExecutionService.deleteProcess(java.lang.Long, boolean), and ProcessExecutionService.deleteProcesses(java.lang.Long[], boolean)
      Parameters:
      processModelId_ - the ID of the ProcessModel to delete.
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist.
      PrivilegeException - if the current User does not have permissions to delete the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • deleteProcessModels

      void deleteProcessModels(Long[] processModelIds_) throws InvalidProcessModelException, PrivilegeException
      Deletes multiple ProcessModel objects. A model can only be deleted if there are no processes that have been created from it on any of the execution servers. To delete processes, use ProcessExecutionService.deleteProcess(java.lang.Long, boolean), and ProcessExecutionService.deleteProcesses(java.lang.Long[], boolean)
      Parameters:
      processModelIds_ - ids of process models to delete.
      Throws:
      InvalidProcessModelException - if a specified ProcessModel does not exist.
      PrivilegeException - if the current User does not have permissions to delete a specified ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDescriptor

      ProcessModel.Descriptor getProcessModelDescriptor(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves a process model descriptor representing the working draft of a process model. This method will successfully return a valid descriptor even if the user only has "initiator" privileges over the specified ProcessModel.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to get the descriptor
      Returns:
      ProcessModel.Descriptor specified by given processModelId_
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist
      PrivilegeException - if the current User does not have sufficient privileges to get the ProcessModel descriptor
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getRecursiveRelationship

      int getRecursiveRelationship(Long processModelId_, Long subProcessModelId_) throws InvalidProcessModelException
      Return the status of the two process models' recursive relationship
      Parameters:
      processModelId_ - id of process model to check for recursive relationship
      subProcessModelId_ - subProcessModel to check for relationship with parent ProcessModel
      Returns:
      one of DOES_NOT_RECURSE, PARENT_PROCESS_RECURSES or SUBPROCESS_RECURSES
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getSubProcessModelDescriptorsForProcessModel

      @Deprecated ResultList getSubProcessModelDescriptorsForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Gets a ResultList containing process model descriptors representing the working drafts of the subprocess models of the given process model
      Parameters:
      processModelId_ - the unique ID of the process model to get the sub process model descriptors for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects that are subprocesses for the given process. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the process model is invalid
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getSynchronousSubProcessModelDescriptorsForProcessModel

      ResultList getSynchronousSubProcessModelDescriptorsForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Gets a ResultList containing process model descriptors representing the working drafts of the sub-process models of the given process model
      Parameters:
      processModelId_ - the unique ID of the process model to get the sub-process model descriptors for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects that are subprocesses for the given process. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the process model is invalid
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDescriptorsContainingSubProcessModel

      @Deprecated ResultList getProcessModelDescriptorsContainingSubProcessModel(Long subProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves process model descriptors representing the working drafts of the process models that contain the given process model as a sub-process model
      Parameters:
      subProcessModelId_ - The ID of the sub process model which will be contained in the returned process models
      Returns:
      A ResultList which contains an array of ProcessModel.Descriptor objects representing those process models containing the given sub process model. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the ProcessModel given by subProcessModelId_ is invalid
      PrivilegeException - if the current user does not have sufficient permissions to view the given process model
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDescriptorsContainingSynchronousSubProcessModel

      ResultList getProcessModelDescriptorsContainingSynchronousSubProcessModel(Long subProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves process model descriptors representing the working drafts of the process models that contain the given process model as a sub-process model
      Parameters:
      subProcessModelId_ - The ID of the sub-process model which will be contained in the returned process models
      Returns:
      A ResultList which contains an array of ProcessModel.Descriptor objects representing process models that contain the given sub process model. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the ProcessModel given by subProcessModelId_ is invalid
      PrivilegeException - if the current user does not have sufficient permissions to view the given process model
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getTopLevelProcessModelDescriptorsForSubProcessModel

      @Deprecated ResultList getTopLevelProcessModelDescriptorsForSubProcessModel(Long subProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Gets a ResultList containing process model descriptors representing the working drafts of the top level process models of the given sub process model
      Parameters:
      subProcessModelId_ - the process model to get top level ProcessModel.Descriptor objects for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects for all top level process models of the given sub process model. This will return an empty ResultList for models that solely form a recursive loop or if called on a top-level process model. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the process model is invalid
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getTopLevelProcessModelDescriptorsForSynchronousSubProcessModel

      ResultList getTopLevelProcessModelDescriptorsForSynchronousSubProcessModel(Long subProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Gets a ResultList containing process model descriptors that represent the working drafts of the top level process models of the given sub-process model
      Parameters:
      subProcessModelId_ - the process model to get top level ProcessModel.Descriptor objects for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects for all top level process models of the given sub process model. This will return an empty ResultList for models that solely form a recursive loop or if called on a top-level process model. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the process model is invalid
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getLinkProcessModelDescriptorsForProcessModel

      @Deprecated ResultList getLinkProcessModelDescriptorsForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieve a list of process model descriptors representing the working drafts of the linked process models for a given process model.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the linked ProcessModel.Descriptor objects
      Returns:
      a ResultList containing ProcessModel.Descriptor objects which represent the linked ProcessModel objects for the specified ProcessModel. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ is invalid
      PrivilegeException - if the current user does not have sufficient privileges to access the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getAsynchronousSubProcessModelDescriptorsForProcessModel

      ResultList getAsynchronousSubProcessModelDescriptorsForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieve a list of process model descriptors that represent the working drafts of all linked process models for the given process model.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the linked ProcessModel.Descriptor objects
      Returns:
      a ResultList containing ProcessModel.Descriptor objects which represent the linked ProcessModel objects for the specified ProcessModel. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ is invalid
      PrivilegeException - if the current user does not have sufficient privileges to access the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDescriptorsContainingLinkProcessModel

      @Deprecated ResultList getProcessModelDescriptorsContainingLinkProcessModel(Long linkProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves process model descriptors that represent the working drafts of all process models that contain the given linked process model
      Parameters:
      linkProcessModelId_ - The ID of the linked ProcessModel which will be contained in the returned ProcessModel objects
      Returns:
      A ResultList which contains an array of ProcessModel.Descriptor objects which contain the linked ProcessModel specified by linkProcessModelId_. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the linked ProcessModel does not exist
      PrivilegeException - if the current user does not have sufficient permissions to view the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDescriptorsContainingAsynchronousSubProcessModel

      ResultList getProcessModelDescriptorsContainingAsynchronousSubProcessModel(Long linkProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves process model descriptors representing the working drafts of the process models that contain the given linked process model
      Parameters:
      linkProcessModelId_ - The ID of the linked ProcessModel which will be contained in the returned ProcessModel objects
      Returns:
      A ResultList which contains an array of ProcessModel.Descriptor objects which contain the linked ProcessModel specified by linkProcessModelId_. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the linked ProcessModel does not exist
      PrivilegeException - if the current user does not have sufficient permissions to view the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getTopLevelProcessModelDescriptorsForLinkProcessModel

      @Deprecated ResultList getTopLevelProcessModelDescriptorsForLinkProcessModel(Long linkProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Gets a ResultList containing process model descriptors representing the working drafts of thetop level process models of the given linked process model
      Parameters:
      linkProcessModelId_ - the process model to get top level process model descriptors for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects for all top level process models of the given linked process model. This will return an empty ResultList for models that solely form a recursive loop or if called on a top level process model.
      Throws:
      InvalidProcessModelException - if the process model is invalid
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getTopLevelProcessModelDescriptorsForAsynchronousSubProcessModel

      ResultList getTopLevelProcessModelDescriptorsForAsynchronousSubProcessModel(Long linkProcessModelId_) throws InvalidProcessModelException, PrivilegeException
      Gets a ResultList containing process model descriptors that represent the working drafts of all parent process models for the given linked process model
      Parameters:
      linkProcessModelId_ - the process model to get top level process model descriptors for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects for all top level process models of the given linked process model. This will return an empty ResultList for models that solely form a recursive loop or if called on a top level process model.
      Throws:
      InvalidProcessModelException - if the process model is invalid
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getSecurityForProcessApplication

      Security getSecurityForProcessApplication() throws PrivilegeException
      Gets the security settings of the Process Application
      Returns:
      the Security object (with all fields populated) that contains the security for the process application. The role maps in the Security object are ProcessApplicationRoleMap objects.
      Throws:
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setSecurityForProcessApplication

      void setSecurityForProcessApplication(Security s_) throws PrivilegeException, InvalidUserException
      Sets the security settings of the Process Application. Fields canInherit and inheritable will be ignored (doesInherit is not ignored).
      Parameters:
      s_ - a Security object which encapsulates the security settings of the Process Application. The role maps in the Security object must be ProcessRoleMap objects
      Throws:
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      InvalidUserException - if any user referenced in the Security does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getSecurityForProcessModel

      Security getSecurityForProcessModel(Long id_) throws InvalidProcessModelException, PrivilegeException
      Gets the security settings of a process model
      Parameters:
      id_ - the unique Id of the process model
      Returns:
      the Security object (with all fields populated) that contains the security settings of the process model. The role maps in the Security object are be ProcessRoleMap objects
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setSecurityForProcessModel

      void setSecurityForProcessModel(Long id_, Security s_) throws InvalidProcessModelException, PrivilegeException, InvalidUserException
      Sets the security settings of a process model. This method does NOT set canInherit and inheritable (doesInherit is not ignored).
      Parameters:
      id_ - the unique Id of the process model
      s_ - a Security object which encapsulates the security settings of the process model. The role maps in the Security object must be ProcessRoleMap objects
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      InvalidUserException - if any user referenced in the Security does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setActorsInRolesForProcessApplication

      void setActorsInRolesForProcessApplication(String[] users_, String[][] userRoles_, Long[] groups_, String[][] groupRoles_) throws PrivilegeException, InvalidUserException, InvalidRoleException
      Adds and/or modifies the roles of users and groups on the Process Application. This method will only update the roles for the users and groups specified in the parameters. All other roles will not be changed. To overwrite the roles for all users and groups use setSecurityForProcessApplication(Security) See ProcessRoleMap for valid roles.
      Parameters:
      users_ - the list of users whose roles are to be added/modified. This parameter can be null, as long as userRoles_ is also null. If one is null and the other is not, a NullPointerException will be thrown.
      userRoles_ - a 2-dimentional array of size [users_.length][]. The String array userRoles_[i] represents the roles which users_[i] will have. (If this array is null or zero-length, the user have no explicit permissions in the Process Application role map). It is legal to have null within this array.
      groups_ - the list of groups whose roles are to be added/modified. This parameter can be null, as long as groupRoles_ is also null. If one is null and the other is not, a NullPointerException will be thrown.
      groupRoles_ - a 2-dimentional array of size [groups_.length][]. The String array groupRoles_[i] represents the roles which groups_[i] will have. (If this array is null or zero-length, the group have no explicit permissions in the Process Application role map). It is legal to have null within this array.
      Throws:
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      InvalidUserException - if any users does not exist
      InvalidRoleException - if an invalid role is passed to the method
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setActorsInRolesForProcessModel

      void setActorsInRolesForProcessModel(Long id_, String[] users_, String[][] userRoles_, Long[] groups_, String[][] groupRoles_) throws InvalidProcessModelException, PrivilegeException, InvalidUserException, InvalidRoleException
      Adds and/or modifies the roles of users and groups on a specified ProcessModel. This method will only overwrite the roles for the users and groups specified in the parameters. All other roles will not be changed. To overwrite the roles for all users and groups use setSecurityForProcessModel(Long, Security) See ProcessRoleMap for valid roles.
      Parameters:
      id_ - the unique Id of the process model
      users_ - the list of users whose roles are to be added/modified This parameter can be null, as long as userRoles_ is also null. If one is null and the other is not, a NullPointerException will be thrown.
      userRoles_ - a 2-dimentional array of size [users_.length][]. The String array userRoles_[i] represents the roles which users_[i] will have. (If this array is null or zero-length, the user have no explicit permissions in the process model role map)
      groups_ - the list of groups whose roles are to be added/modified This parameter can be null, as long as groupRoles_ is also null. If one is null and the other is not, a NullPointerException will be thrown.
      groupRoles_ - a 2-dimentional array of size [groups_.length][]. The String array groupRoles_[i] represents the roles which groups_[i] will have. (If this array is null or zero-length, the group have no explicit permissions in the process model role map)
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have sufficient privileges to perform this operation
      InvalidUserException - if any users does not exist
      InvalidRoleException - if an invalid role is passed to the method
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPermissionsForProcessApplication

      ProcessApplicationPermissions getPermissionsForProcessApplication() throws InvalidUserException
      Retrieves permissions on the Process application for the current user
      Returns:
      ProcessApplicationPermissions object which contains the permissions for the current user on the Process Application
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      InvalidUserException
    • getPermissionsForProcessModel

      ProcessModelPermissions getPermissionsForProcessModel(Long id_) throws InvalidProcessModelException
      Retrieves permissions on a process model for the current user.
      Parameters:
      id_ - ID of the ProcessModel for which to get the ProcessModelPermissions
      Returns:
      ProcessModelPermissions object which contains the permissions on the process model for the current user.
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPermissionsForProcessModels

      ProcessModelPermissions[] getPermissionsForProcessModels(Long[] ids_) throws InvalidProcessModelException
      Retrieves permissions on multiple process models objects for the current user.
      Parameters:
      ids_ - Unique IDs of the process models for which to get the ProcessModelPermissions
      Returns:
      ProcessModelPermissions which contain the permissions on the process models for the current user
      Throws:
      InvalidProcessModelException - if a specified ProcessModel does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPriority

      Priority getPriority(Long priorityId_) throws InvalidPriorityException
      Retrieves a Priority
      Parameters:
      priorityId_ - ID of the Priority to retrieve
      Returns:
      The Priority coresponding to priorityId_
      Throws:
      InvalidPriorityException - if the Priority does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getDefaultPriority

      Priority getDefaultPriority()
      Retrieves the default Priority for the system.
      Returns:
      The default Priority; null if no default is configured.
    • setDefaultPriority

      void setDefaultPriority(Long priorityId_) throws InvalidPriorityException, IllegalArgumentException
      Sets the default Priority that the Process Application will use.
      Parameters:
      priorityId_ - the ID of the priority to set as the default priority
      Throws:
      InvalidPriorityException - if the specificed priority does not exist
      IllegalArgumentException - if a null argument is passed
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPriorityOfProcessModel

      Priority getPriorityOfProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves the priority for a ProcessModel.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the Priority
      Returns:
      The Priority for the ProcessModel specified by processModelId_
      Throws:
      InvalidProcessModelException - if the specified ProcessModel does not exist
      PrivilegeException - if the current user does not have privileges to view the process model
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setPriorityOfProcessModel

      void setPriorityOfProcessModel(Long processModelId_, Long priorityId_) throws InvalidPriorityException, InvalidProcessModelException, PrivilegeException
      Sets the priority of a process model
      Parameters:
      processModelId_ - the unique id of the process model to set the priority of
      priorityId_ - the unique id of the priority to set
      Throws:
      InvalidPriorityException - if the priority does not exist
      InvalidProcessModelException - if the process model does not exist
      PrivilegeException - if the current user does not have sufficient permissions to perform this action
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • lockProcessModel

      void lockProcessModel(Long processModelId_, boolean override_) throws InvalidProcessModelException, PrivilegeException, LockException
      Locks the specified process model
      Parameters:
      processModelId_ - the unique ID of the process model to lock
      override_ - whether or not to override the lock another user has placed on the process model
      Throws:
      InvalidProcessModelException - if the process model does not exist
      PrivilegeException - if the user does not have access to lock (or override the existing lock, if specified) of the process model
      LockException - if the process model is already locked (by someone other than the user) and the user did not choose to override it.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelVersion

      ProcessModel getProcessModelVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException
      Retrieves a version of a ProcessModel. If the version is null or empty, it returns the latest saved draft.
      Parameters:
      processModelId_ - ID of the ProcessModel whose version will be retrieved
      version_ - The version of the ProcessModel to retrieve
      Returns:
      The ProcessModel given by processModelId_ and version_
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      InvalidVersionException - if the ProcessModel does not have the given version
      PrivilegeException - if the current user does not have sufficient permissions to view the ProcessModel version
    • exportProcessModelVersion

      ProcessModel exportProcessModelVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException
      Retrieves a version of a ProcessModel. If the version is null or empty, it returns the latest saved draft. Unlike getProcessModelVersion(java.lang.Long, java.lang.String), this API does not convert rule uuids to names (within expressions). Therefore this API should be used when retrieving a model for export.
      Parameters:
      processModelId_ - ID of the ProcessModel whose version will be retrieved
      version_ - The version of the ProcessModel to retrieve
      Returns:
      The ProcessModel given by processModelId_ and version_
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      InvalidVersionException - if the ProcessModel does not have the given version
      PrivilegeException - if the current user does not have sufficient permissions to view the ProcessModel version
    • versionProcessModel

      Versions a process model in the database based on the input parameter. See createProcessModel(com.appiancorp.suiteapi.process.ProcessModel) for the properties that must be populated on the process model. It creates a new process model if the process model Id is set to -1.
      Parameters:
      pm_ - a ProcessModel object representing the new process model version
      Returns:
      a ProcessModel object representing the versioned process model
      Throws:
      InvalidProcessModelException - if the ID of the process model does not correspond to a valid process model
      PrivilegeException - if the user does not have privileges to version the process model
      LockException - if the process model is locked by someone other than the current user
      InvalidUserException - if any of the users referenced in the ProcessModel do not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • versionProcessModel

      The returned process model is not transformed.
      Throws:
      InvalidProcessModelException
      PrivilegeException
      LockException
      InvalidUserException
    • getProcessModelsForFolder

      ResultPage getProcessModelsForFolder(Long folderId_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidFolderException, PrivilegeException
      Retrieve process model descriptors representing the working drafts of the process models directly in a process model folder
      Parameters:
      folderId_ - ID of the ProcessModelFolder for which to retrieve all contained ProcessModel objects
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in ProcessModel.Descriptor
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      Returns a ResultPage which contains an array of ProcessModel.Descriptor objects
      Throws:
      InvalidFolderException - if the ProcessModelFolder does not exist
      PrivilegeException - if the current user does not have permission to access the folder
    • getChildFolders

      ResultPage getChildFolders(Long folderId_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidFolderException, PrivilegeException
      Gets all the direct child folders of a process model folder
      Parameters:
      folderId_ - id of the folder for which to get child folders
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Negative numbers will result in the entire collection being returned, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in ProcessModelFolder
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      Returns a ResultPage which contains an array of ProcessModelFolder objects
      Throws:
      InvalidFolderException - if the ProcessModelFolder specified by folderId_ does not exist
      PrivilegeException - if the current user does not have access to the ProcessModelFolder
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getTopLevelFolders

      ResultPage getTopLevelFolders(int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_)
      Returns the top level folders in the process application that the current user can see.
      Parameters:
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Negative numbers will result in the entire collection being returned, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted This is one of the SORT_BY_XXX constants located in ProcessModelFolder
      sortOrder_ - the order in which the results will be sorted This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      a ResultPage of ProcessModelFolder objects representing the top level folders
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getVersionsForProcessModel

      ResultPage getVersionsForProcessModel(Long processModelId_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidProcessModelException, PrivilegeException
      Gets the versions for a process model
      Parameters:
      processModelId_ - the id of the process model to get versions for
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in ProcessModel.Descriptor
      sortOrder_ - The order in which to sort the results. This is either Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      A ResultPage containing ProcessModel.Descriptor objects representing the versions of the specified process model.
      Throws:
      InvalidProcessModelException - if the process model does not exist
      PrivilegeException - if the user does not have permissions to view the process model
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setActorsInRolesForFolder

      void setActorsInRolesForFolder(Long folderId_, String[] users_, String[][] userRoles_, Long[] groups_, String[][] groupRoles_) throws InvalidFolderException, PrivilegeException, InvalidUserException, InvalidRoleException
      Sets actors (users and groups) in roles for a process model folder. This method will only overwrite the roles for the users and groups specified in the parameters. All other roles will not be changed. To overwrite the roles for all users and groups use setSecurityForFolder(Long, Security) See ProcessRoleMap for valid roles.
      Parameters:
      folderId_ - the unique id of the process model folder
      users_ - the list of users (user names) whose roles are to be added/modified This parameter can be null, as long as userRoles_ is also null. If one is null and the other is not, a NullPointerException will be thrown.
      userRoles_ - a 2-dimensional array of size [users_.length]. The String array userRoles_[i] represents the roles which users_[i] will have. (If this array is null or zero-length, the user has no explicit permissions in the process model folder's role map)
      groups_ - the list of groups whose roles are to be added/modified This parameter can be null, as long as groupRoles_ is also null. If one is null and the other is not, a NullPointerException will be thrown.
      groupRoles_ - a 2-dimentional array of size [groups_.length]. The String array groupRoles_[i] represents the roles which groups_[i] will have. (If this array is null or zero-length, the group has no explicit permissions in the process model folder's role map)
      Throws:
      InvalidFolderException - if the folder does not exist
      PrivilegeException - if the user does not have permission to perform the operation
      InvalidUserException - if any of the users do not exist
      InvalidRoleException - if an invalid role is passed to the method
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • unlockProcessModel

      void unlockProcessModel(Long processModelId_, boolean override_) throws InvalidProcessModelException, PrivilegeException, LockException
      Unlocks the given process model
      Parameters:
      processModelId_ - the unique id of the process model to unlock
      override_ - whether or not to break a lock on the given process model, if it is currently locked by someone other than the current user
      Throws:
      InvalidProcessModelException - if the process model does not exist
      LockException - if the process model is already locked and the user has not specified to override it
      PrivilegeException - if the user does not have privileges to unlock the process model
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • unlockProcessModels

      void unlockProcessModels()
      Unlocks all process models locked by the current user.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getFolder

      Retrieves a ProcessModelFolder.
      Parameters:
      folderId_ - ID of the ProcessModelFolder to retrieve
      Returns:
      a ProcessModelFolder specified by folderId_
      Throws:
      InvalidFolderException - if the ProcessModelFolder does not exist
      PrivilegeException - if the current User does not have permission to access to the folder
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getFolders

      ResultList getFolders(Long[] folderIds_)
      Retrieves multiple process model folders
      Parameters:
      folderIds_ - Unique IDs of the process model folders to retrieve.
      Returns:
      A ResultList which contains an array of ProcessModelFolder objects, and result codes. In the case where there is an exception (such as access restriction) the ResultList.getResultCodes() will have an entry for every id passed to it, but the Result.getResults() will only have an entry for every valid result returned. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified folder does not exist
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • startProcessVersion

      Deprecated.
      Use initiateProcess(Long, ProcessStartConfig), which has better enforcement of required parameters (requires that their values not be null or empty)
      Starts an instance of the given process model version, using the given variables to initialize state.
      Parameters:
      processModelId_ - id of process model to start
      variables_ - parameters for the process model. If using a process variable of an Appian type, do not set the value to that object but instead to the corresponding primitive. For instance, do not assign a User process variable a User object. Instead, assign that process variable a String containing the username. Likewise, assign a process variable of type Group should be assigned a Long, etc. The exception to this rule is the People type. Process variables of type People should be assigned a LocalObject.
      version_ - version of the given process model to start
      priorityId_ - priority of the process model to start, null if the default priority is to be used
      Returns:
      The id of the started process instance.
      Throws:
      InvalidProcessModelException - if the process model is invalid
      InvalidPriorityException - if the priority is invalid
      InvalidVersionException - if the version is invalid
      PrivilegeException - if the user does not have privileges to perform this
      InvalidStateException - if the version does not exist
      StorageLimitException - if all execution servers are full
      InvalidUserException - if any of the users users referenced by a ProcessVariable does not exist
      IllegalArgumentException - if the ProcessModel requires process parameters to start, and the variables_ parameter is null, an empty array, or does not contain all necessary process parameters.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      Exception
    • getProcessModelProperties

      ProcessModelProperties getProcessModelProperties(Long modelId_) throws PrivilegeException, InvalidProcessModelException
      Retrieves the ProcessModelProperties representing the working draft of a ProcessModel.
      Parameters:
      modelId_ - ID of the ProcessModel for which to retrieve the ProcessModelProperties
      Returns:
      A ProcessModelProperties object which contains the properties for the ProcessModel given by modelId_
      Throws:
      PrivilegeException - if the current user does not have sufficient privileges to view the ProcessModel
      InvalidProcessModelException - if the ProcessModel does not exist
      a - ServiceException if any system-level error occurs
    • getMaximumNumberOfNotes

      @Deprecated int getMaximumNumberOfNotes()
      Deprecated.
      since 23.2
      Returns the maximum number of notes that can be added to a process model or process node. This property can be configured in pc.properties
      Returns:
      The maximum number of notes
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getMaximumNumberOfAttachments

      int getMaximumNumberOfAttachments()
      Returns the maximum number of attachments that can be added to a process model or process node. This property can be configured in pc.properties
      Returns:
      The maximum number of attachments
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getUnpublishedChildrenForProcessModel

      ResultList getUnpublishedChildrenForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Returns the working draft of the unpublished children (sub process models) of the given process model
      Parameters:
      processModelId_ - the id of the process model to get unpublished children for
      Returns:
      a ResultList containing ProcessModel.Descriptor objects of the process model's unpublished children The result codes are as follows: UNPUBLISHED_CHILDREN_VIEW_PERMISSIONS = No permissions, cannot view process model; UNPUBLISHED_CHILDREN_INVALID = Invalid Process Model (a process model that cannot be run); UNPUBLISHED_CHILDREN_PUBLISH_PERMISSIONS = No permissions to publish the process model; UNPUBLISHED_CHILDREN_SUCCESS = Success
      Throws:
      InvalidProcessModelException - if the process model does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      PrivilegeException
    • getParentsForProcessModel

      ResultList getParentsForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Retrieves the working drafts of the parents of a ProcessModel. If the process model is not a sub process model in any other process model, the returned ResultList will have an empty result set.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to get the parents.
      Returns:
      a ResultList containing an array of ProcessModel.Descriptor objects which represent the parents of the ProcessModel specified by processModelId_. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist.
      PrivilegeException - if the user does not have privileges to view the process model
    • getParentsOfUnpublishedChildrenForProcessModel

      ResultList getParentsOfUnpublishedChildrenForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Returns the working drafts of the parents of the unpublished children (sub process models) of a ProcessModel. Does not return the ProcessModel itself or its parents.
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve the parents of the unpublished children.
      Returns:
      A ResultList containing an array of ProcessModel.Descriptor objects which represent the parents of the unpublished children of the ProcessModel specified by processModelId_. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      PrivilegeException - if the user does not have privileges to view the process model
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs.
    • publishProcessModel

      Deprecated.
      use saveAndPublishProcessModel
      Publishes a process model. Unpublished children of the process model will be published and owners of the affected process models will be notified
      Parameters:
      processModel_ - process model to publish
      Returns:
      the published process model. The process model is transformed.
      Throws:
      InvalidProcessModelException - if the ID of the process model does not correspond to a valid ID
      PrivilegeException - if the user does not have privileges to publish the process model
      LockException - if the process model is locked
      InvalidStateException - if the process model is in an invalid state (not validated)
      InvalidUserException - if any of the users referenced by the ProcessModel does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • saveAndPublishProcessModel

      Attempts to lock, save, validate, and publish the given model. If the model is new, we try to create, lock, validate, and publish. The resulting data structure contains the model that was written to the database (published if everything worked, saved if only the save worked, and null if nothing worked), along with any validation errors or warnings that were detected. During the save portion, the method can throw any of the exceptions that would be thrown by createProcessModel or updateProcessModel. If the model contains any sub-processes that are unpublished, then the ProcessModel.Descriptor objects are returned for those models that were published and owners notified, those that cannot be published and those parents of unpublished children that were notified.
      Parameters:
      processModel_ - the model to save and publish
      overrideLock_ - whether to lock the model if it is already locked
      Returns:
      a ProcessModelWithErrors data structure holding the saved and/or published model and descriptions of any errors that occurred
      Throws:
      InvalidProcessModelException - if the ID of the process model does not correspond to a valid ID
      PrivilegeException - if the user does not have privileges to save or publish the process model
      LockException - if the process model is locked and we cannot override
      InvalidStateException - if the process model is in an invalid state (not validated)
      InvalidUserException - if any of the users referenced in the ProcessModel do not exist
      InvalidUuidException - if any of the UUIDs referenced do not exist
      InvalidFolderException - if folder ID where processModel is to be saved does not exist
      InvalidPriorityException - if priority for the processModel is invalid
    • getVisibleProcessVariablesForVersion

      ProcessVariable[] getVisibleProcessVariablesForVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException
      Retrieves all visible process variables associated with the given process model version, or the process variables that are reportable through analytics and can be mapped in a subprocess relationship
      Parameters:
      processModelId_ - the unique Id of the process model to retrieve variables for
      version_ - version to get the parameters for
      Returns:
      the visible process variables of the process model specified by the id and version given
      Throws:
      InvalidProcessModelException - if the process model does not exist
      InvalidVersionException - if the version does not exsit
      PrivilegeException - if the user does not have sufficient privileges to perform the operation
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelParametersForVersion

      ProcessVariable[] getProcessModelParametersForVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException, Exception
      Retrieves all of the process variables that are required to start an instance of the given process model version (ie. process parameters)
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve ProcessParameters
      version_ - The version of the ProcessModel for which to retrieve ProcessParameters (use null to refer to a draft)
      Returns:
      ProcessVariable objects which represent those variables which are required to start the ProcessModel version given by processModelId_ and version_
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      InvalidVersionException - if the ProcessModel version does not exist
      PrivilegeException - if the current User does not have permissions to view the ProcessModel
      Exception
    • getCountProcessModelParametersForVersion

      int getCountProcessModelParametersForVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException, Exception
      Retrieves count of all of the process variables that are required to start an instance of the given process model version (ie. process parameters)
      Parameters:
      processModelId_ - ID of the ProcessModel for which to retrieve ProcessParameters
      version_ - The version of the ProcessModel for which to retrieve ProcessParameters (use null to refer to a draft)
      Returns:
      ProcessVariable objects which represent those variables which are required to start the ProcessModel version given by processModelId_ and version_
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      InvalidVersionException - if the ProcessModel version does not exist
      PrivilegeException - if the current User does not have permissions to view the ProcessModel
      Exception
    • updateFolder

      Updates a process model folder. The following fields must be populated in the ProcessModelFolder object: id, name, description, and parentFolderId
      Parameters:
      folder_ - a ProcessModelFolder object containing the properties of the folder to update. This methods will update name, description and parentFolderId. Other fields will not be updated.
      Returns:
      a ProcessModelFolder object representing the updated folder
      Throws:
      PrivilegeException - if the user does not have permissions to perform this action
      IllegalArgumentException - if the type of the folder is different from the previous type (not thrown if the new type is null, in which case the new type is ignored)
      InvalidFolderException - if the ID of the folder does not correspond to a valid folder, or if the ID of the parent folder is invalid
      RecursiveRelationshipException - if the update would result in a loop in the tree of parent folders
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • createFolder

      Creates a folder for storing process models. The following fields are required for the ProcessModelFolder object: name, and type
      Parameters:
      folder_ - The ProcessModelFolder to create.
      Returns:
      The created ProcessModelFolder
      Throws:
      PrivilegeException - if the current user does not have permissions to create a ProcessModelFolder
      IllegalArgumentException - if the type of folder is invalid. It must be one of two types: ProcessModelFolder.TYPE_COMMUNITY or ProcessModelFolder.TYPE_PRIVATE. This exception will also be thrown if the parent folder is invalid (Top level folders must have a null parent folder id).
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      DuplicateUuidException - if the UUID of the folder already exists
    • disableProcessModel

      void disableProcessModel(Long processModelId_, String version_) throws InvalidProcessModelException, PrivilegeException, InvalidVersionException
      Disables a version of a ProcessModel.
      Parameters:
      processModelId_ - ID of the ProcessModel on which to disable a version.
      version_ - The ID of the version to disable.
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist.
      PrivilegeException - if the current User does not have sufficient permissions to disable a version
      InvalidVersionException - if the given version does not exist for the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • enableProcessModel

      void enableProcessModel(Long processModelId_, String version_) throws InvalidProcessModelException, PrivilegeException, InvalidVersionException
      Enables a ProcessModel version.
      Parameters:
      processModelId_ - The ID of the ProcessModel which has the version to enable.
      version_ - The name of the version to enable
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by processModelId_ does not exist.
      PrivilegeException - if the current user does not have sufficient permissions to enable the version.
      InvalidVersionException - if the given version does not exist for the ProcessModel
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • deleteFolders

      ResultList deleteFolders(Long[] folders_)
      Deletes a list of folders
      Parameters:
      folders_ - The ProcessModelFolder objects to delete.
      Returns:
      a ResultList containing result codes for each deletion. Possible values are: ResultList.CODE_NO_PERMISSION if the user does not have permission, ResultList.CODE_INVALID if the folder does not exist or is not empty, and ResultList.CODE_VALID if the delete succeeded .
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • deleteFolder

      Parameters:
      folderId_ - id of the ProcessModelFolder to delete.
      Throws:
      InvalidFolderException - if the ProcessModelFolder specified by folderId_ does not exist.
      PrivilegeException - if the current user does not have sufficient privileges to delete the ProcessModelFolder.
      InvalidStateException - if the ProcessModelFolder is not empty (it must not contain sub-folders or process models)
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • updateFolders

      ResultList updateFolders(ProcessModelFolder[] processModelFolders_) throws RecursiveRelationshipException
      Updates a list of process model folders. The following fields must be populated in each ProcessModelFolder object: id, name, description, and parentFolderId
      Parameters:
      processModelFolders_ - an array of ProcessModelFolder objects each containing the properties of the folders to update. This method will update name, description, parentFolderId. Other fields will not be updated.
      Returns:
      a ResultList containing the updated ProcessModeFolder objects and result codes for the operations. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified folder does not exist or its parent folder does not exist
      Throws:
      RecursiveRelationshipException - if the updates would result in a loop in the tree of parent folders
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • updateProcessModelsWithDescriptors

      ResultList updateProcessModelsWithDescriptors(ProcessModel.Descriptor[] descriptors_)
      Updates process models in the database. In order to update a ProcessModel.Descriptor at least the following fields must be populated: id and processName
      Parameters:
      descriptors_ - the ProcessModel.Descriptor objects that represent the process models to update
      Returns:
      A result list containing the updated ProcessModel.Descriptor objects and a list of result codes for the operations. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have permission, or ResultList.CODE_INVALID if the specified process model does not exist
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • getSecurityForFolder

      Security getSecurityForFolder(Long folderId_) throws InvalidFolderException, PrivilegeException
      Gets the security for a process model folder
      Parameters:
      folderId_ - the unique Id of the folder to retrieve security for
      Returns:
      the Security object (with all fields populated) that contains that security settings for the folder. The role maps in the Security object are be ProcessRoleMap objects
      Throws:
      InvalidFolderException - if the folder doesn't exist
      PrivilegeException - if the user doesn't have privileges
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setSecurityForFolder

      void setSecurityForFolder(Long folderId_, Security security_) throws PrivilegeException, InvalidFolderException, InvalidUserException
      Sets the security for a process model folder. Fields canInherit and inheritable will be ignored (doesInherit is not ignored).
      Parameters:
      folderId_ - the unique id of the folder to set security for
      security_ - a Security object representing the security to set. The role maps in the Security object must be ProcessRoleMap objects
      Throws:
      PrivilegeException - if the user doesn't have privileges
      InvalidFolderException - if the folder doesn't exist
      InvalidUserException - if any of the users referenced by the Security does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelDescriptors

      ResultList getProcessModelDescriptors(Long[] pmIds_)
      Retrieves multiple process model descriptors, representing the working drafts of the given process models
      Parameters:
      pmIds_ - Unique IDs of the ProcessModel objects for which to retrieve descriptors
      Returns:
      A ResultList which contains an array of ProcessModel.Descriptor objects and an array of result codes which correspond to each ID. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have viewer permission, or ResultList.CODE_INVALID if the specified process model does not exist
    • getProcessModelsLatestPublishedDescriptors

      ResultList getProcessModelsLatestPublishedDescriptors(Long[] pmIds_)
      Retrieves multiple process model descriptors, representing the latest published version or a draft if there is no publish version. The list of results is the same length and in the same order as the input IDs. Invalid results will be represented by a null in the result list.
      Parameters:
      pmIds_ - Unique IDs of the ProcessModel objects for which to retrieve descriptors
      Returns:
      A ResultList which contains an array of ProcessModel.Descriptor objects and an array of result codes which correspond to each ID. The result codes can be: ResultList.CODE_VALID if the action succeeded, ResultList.CODE_NO_PERMISSION if the user does not have viewer permission, or ResultList.CODE_INVALID if the specified process model does not exist
    • getProcessModelVersionDescriptor

      ProcessModel.Descriptor getProcessModelVersionDescriptor(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException
      Retrieves the process model descriptor for a version of a ProcessModel. If null is given as a parameter for version, the returned value will be the descriptor of the draft.
      Parameters:
      processModelId_ - ID of the ProcessModel whose version will be retrieved
      version_ - The version of the ProcessModel for which to get the ProcessModel.Descriptor
      Returns:
      ProcessModel.Descriptor for the ProcessModel given by processModelId_ and version_
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      InvalidVersionException - if the version of the process model does not exist
      PrivilegeException - if the current user does not have permissions to view the ProcessModel or version
    • moveProcessModel

      void moveProcessModel(Long processModelId_, Long parentFolderId_) throws InvalidProcessModelException, InvalidFolderException, PrivilegeException
      Moves a process model to a new process model folder
      Parameters:
      processModelId_ - the unique id of process model to move
      parentFolderId_ - the unique id of new parent folder
      Throws:
      InvalidProcessModelException - if the process model does not exist
      InvalidFolderException - if the folder does not exist
      PrivilegeException - if the user does not have permissions to move the given process model to the given folder
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • moveFolder

      void moveFolder(Long folderId_, Long parentFolderId_) throws InvalidFolderException, PrivilegeException, RecursiveRelationshipException
      Moves a process model folder
      Parameters:
      folderId_ - the unique id of the process model folder to move
      parentFolderId_ - the unique id of the new parent folder
      Throws:
      InvalidFolderException - if the folder or the new parent folder does not exist
      PrivilegeException - if the user does not have permissions to perform this action
      RecursiveRelationshipException - if the move would result in a loop in the tree of parent folders
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPermissionsForFolder

      Parameters:
      folderId_ - ID of ProcessModelFolder for which to get ProcessModelFolderPermissions
      Returns:
      A ProcessModelFolderPermissions object which contains permissions for the folder.
      Throws:
      InvalidFolderException - if the ProcessModelFolder does not exist
      PrivilegeException - if the current user does not have sufficient permissions to view the ProcessModelFolderPermissions for the folder
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPermissionsForFolders

      ProcessModelFolderPermissions[] getPermissionsForFolders(Long[] folderIds_) throws InvalidFolderException, PrivilegeException
      Retrieves ProcessModelFolderPermissions objects for multiple ProcessModelFolder objects.
      Parameters:
      folderIds_ - Unique IDs of ProcessModelFolder objects for which to get permissions
      Returns:
      An array of ProcessModelFolderPermissions objects which contain the permissions for the folders.
      Throws:
      InvalidFolderException - if any of the ProcessModelFolder objects do not exist
      PrivilegeException - if the current User does not have sufficient permissions to view the ProcessModelFolderPermissions for any of the folders
    • setInheritanceForFolder

      void setInheritanceForFolder(Long folderId_, boolean inherits_) throws PrivilegeException, InvalidFolderException
      Sets the inheritance for a process model folder
      Parameters:
      folderId_ - the unique id of the folder
      inherits_ - if the folder inherits permissions from its parent
      Throws:
      PrivilegeException - if the user does not have permission to perform this action
      InvalidFolderException - if the folder does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • deleteProcessModelVersion

      ProcessModel.Descriptor deleteProcessModelVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException
      Deletes a version of a ProcessModel.
      Parameters:
      processModelId_ - ID of the ProcessModel
      version_ - ID of the version to delete. If null, the process model will be deleted.
      Returns:
      Descriptor from before the version is deleted
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist.
      InvalidVersionException - if the version does not exist for the ProcessModel.
      PrivilegeException - if the current user does not have sufficient permissions to delete the ProcessModel version.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getBusinessEntity

      BusinessEntity getBusinessEntity()
      Retrieves the BusinessEntity which has been created on the system.
      Returns:
      The BusinessEntity in the system. Returns null if no BusinessEntity has been created.
    • createBusinessEntity

      void createBusinessEntity(BusinessEntity business_) throws IllegalArgumentException
      Creates a BusinessEntity for use with Web Services.
      Parameters:
      business_ - The BusinessEntity to create. Minimum required fields are: uuid, organizationName, and contactInformation. All fields in the contactInformation bean are required (non-null and non-empty Strings).
      Throws:
      IllegalArgumentException - if any of the required fields or any of the fields in the contactInformation bean is null or empty.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • updateBusinessEntity

      void updateBusinessEntity(BusinessEntity business_) throws NullPointerException
      Updates a BusinessEntity.
      Parameters:
      business_ - a BusinessEntity object. Minimum required fields are: uuid, organizationName, and contactInformation.
      Throws:
      NullPointerException - if,
      • the required fields in the argument are null or empty.
      • the contactInformation field of the argument is a list and any entry of this list is null or empty.
      • the argument itself is null
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • getProcessModelWebServices

      ResultPage getProcessModelWebServices(int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_)
      Retrieves all ProcessModelWebService objects on the server.
      Parameters:
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants in ProcessModelWebService
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      A ResultPage which contains an array of ProcessModelWebService objects.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • createProcessModelWebService

      Parameters:
      pmws_ - The ProcessModelWebService to create. Minimum required fields are: serviceName, serviceUuid, and processModelId.
      Throws:
      DuplicateWebServiceNameException - if a ProcessModelWebService with the serviceName already exists.
      InvalidProcessModelException - if the ProcessModel specified by processModelId does not exist.
      Exception - if the ProcessModelWebService does not contain a serviceName or serviceUuid
      ServiceExeption - if any system-level error occurs
    • deleteProcessModelWebService

      void deleteProcessModelWebService(String serviceName_)
      Deletes a ProcessModelWebService based on the service name which it contains.
      Parameters:
      serviceName_ - The name of the service to delete. The ProcessModelWebService itself will be deleted.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessStartingInfo

      ProcessStartingInfo getProcessStartingInfo(String serviceName_)
      Retrieves the ProcessStartingInfo for a service.
      Parameters:
      serviceName_ - The service for which to retrieve the ProcessStartingInfo
      Returns:
      A ProcessStartingInfo object which contains the information necessary to start a service.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelByUuid

      ProcessModel getProcessModelByUuid(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) String uuid_) throws InvalidProcessModelException, PrivilegeException
      Retrieves the working draft of the ProcessModel specified by a UUID (Universal Unique Identifier).
      Parameters:
      uuid_ - UUID which specifies the ProcessModel to retrieve.
      Returns:
      The ProcessModel specified by uuid_
      Throws:
      InvalidProcessModelException - if the ProcessModel does not exist
      PrivilegeException - if the user is not allowed to access the model.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelIdByUuid

      Long getProcessModelIdByUuid(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) String uuid_) throws InvalidProcessModelException, PrivilegeException
      Retrieves the ID of a ProcessModel by a UUID (Universal Unique Identifier).
      Parameters:
      uuid_ - UUID of ProcessModel whose ID will be retrieved
      Returns:
      ID of the ProcessModel specified by uuid_, or null if no process model exists with that UUID
      Throws:
      InvalidProcessModelException - if no process exists for the UUID provided
      PrivilegeException - if the user is not allowed to access the model.
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelsAndDescendants

      ProcessModel[] getProcessModelsAndDescendants(Long[] ids_) throws InvalidProcessModelException
      Retrieves multiple ProcessModel objects as well as the sub ProcessModel objects which they contain. All process models returned represent the working drafts of the process models in question.
      Parameters:
      ids_ - Uniques IDs of the ProcessModel which will be retrieved. Their sub process models will be retrieved as well.
      Returns:
      The ProcessModel objects specified by ids_, along with their sub process models
      Throws:
      InvalidProcessModelException - if a specified ProcessModel does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelsForFolderStartableOnly

      ResultPage getProcessModelsForFolderStartableOnly(Long folderId_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidFolderException, PrivilegeException
      Retrieve descriptors representing the working drafts of the startable process models directly in a process model folder. A ProcessModel is startable if it has a valid version or draft.
      Parameters:
      folderId_ - id of the folder to get all process models for
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in ProcessModel.Descriptor
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      Returns a ResultPage of ProcessModel.Descriptor objects which represent the startable ProcessModel objects in the ProcessModelFolder specified by folderId_
      Throws:
      InvalidFolderException - if the ProcessModelFolder does not exist
      PrivilegeException - if the current user does not have permission to access the folder
    • validateProcessModel

      String[] validateProcessModel(AbstractProcessModel apm_)
      Returns the results of validating a process model
      Parameters:
      pm_ - a ProcessModel object representing the process model to be validated
      Returns:
      An array of strings relating to the errors in the process model.

      The error strings contain the error name followed by "@"-separated field names in the ProcessModel bean to specify the location, followed by "@" and the reasons for the error Possible error names include "Invalid Expression" and "Invalid Subprocess". This name (prefix) is omitted from fatal invalidities.

      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
    • validateProcessModelVersion

      String[] validateProcessModelVersion(Long processModelId_, String version_) throws InvalidProcessModelException, InvalidVersionException, PrivilegeException
      Returns the results of validating a process model, same as getProcessModelVersion followed by validateProcessModel.
      Parameters:
      processModelId_ - ID of the ProcessModel whose version will be validated
      version_ - The version of the ProcessModel to retrieve
      Returns:
      An array of strings relating to the errors in the process model.

      The error strings contain the error name followed by "@"-separated field names in the ProcessModel bean to specify the location, followed by "@" and the reasons for the error Possible error names include "Invalid Expression" and "Invalid Subprocess". This name (prefix) is omitted from fatal invalidities.

      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if a system-level error occurs.
      InvalidProcessModelException
      InvalidVersionException
      PrivilegeException
    • isProcessModelLocked

      boolean isProcessModelLocked(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Determines whether a process model is locked
      Parameters:
      processModelId_ - the ID of the process model
      Returns:
      true, if the process model with the given ID is locked; false otherwise.
      Throws:
      InvalidProcessModelException - if the ID does not correspond to a valid process model
      PrivilegeException - if the current user cannot view the process model (if ProcessModelPermissions.isView() would return false for this process model)
    • getProcessModelLatestPublishedVersion

      ProcessModel getProcessModelLatestPublishedVersion(Long processModelId_) throws PrivilegeException, InvalidProcessModelException
      Retrieve the latest published version of a ProcessModel or the working draft if a published version does not exist.
      Parameters:
      processModelId_ - ID of the ProcessModel to retrieve
      Returns:
      The ProcessModel specified by processModelId_
      Throws:
      PrivilegeException - if the current User does not have sufficient privileges to view the ProcessModel
      InvalidProcessModelException - if a ProcessModel specified by processModelId_ does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getProcessModelLatestPublishedVersionDescriptor

      ProcessModel.Descriptor getProcessModelLatestPublishedVersionDescriptor(Long processModelId_) throws PrivilegeException, InvalidProcessModelException
      Retrieve the latest published version of a ProcessModel.Descriptor or the working draft if a published version does not exist.
      Parameters:
      processModelId_ - ID of the Descriptor to retrieve
      Returns:
      The Descriptor specified by processModelId_
      Throws:
      PrivilegeException - if the current User does not have sufficient privileges to view the ProcessModel
      InvalidProcessModelException - if a ProcessModel specified by processModelId_ does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getACInstanceIdsForLocalIds

      ResultList getACInstanceIdsForLocalIds(String[] localIds_)
      Returns a ResultList containing the actual Id's in database corresponding to given localId's of ActivityClass
      Parameters:
      localIds_ - localId's of ActivityClass objects
      Returns:
      a ResultList containing Long Id's of ActivityClass in database
    • getACPInstanceIdsForLocalIds

      ResultList getACPInstanceIdsForLocalIds(Long activityClassLocalId_, String[] localIds_)
      Returns a ResultList containing the actual Id's in database for ActivityClassParameter corresponding to given a ActivityClass localId and ActivityClassParameter localId's. If the localIds array is empty, InvalidActivityClassSchemaException might be thrown.
      Parameters:
      activityClassLocalId_ - Id of ActivityClass> whose ActivityClassParameter Id's are requested
      localIds_ - localId's of ActivityClassParameter objects
      Returns:
      a ResultList containing Long Id's of given ActivityClassParameter objects in database
    • notifyUserCreation

      @Deprecated void notifyUserCreation(String username_) throws NullPointerException
      Deprecated.
      done automatically by UserService.createUser
      Notifies the server that a new user was created on the Personalization server
      Parameters:
      username_ - the name of the user that was added
      Throws:
      NullPointerException - if username_ is null
    • notifyUsersCreation

      void notifyUsersCreation(String[] usernames_) throws NullPointerException
      Notifies the server that new users were created on the Personalization server
      Parameters:
      usernames_ - the names of the users that were added
      Throws:
      NullPointerException - if any of the usernames are null
    • validateGroupMembership

      boolean validateGroupMembership(Long[] memGroupIds_, Long[] admGroupIds_, Long userTypeId_, String username) throws InvalidAnonymousUserException, InvalidUserException
      Validates if the association of a user as 'Member' and as an 'Administrator has changed or not.
      Parameters:
      memGroupIds_ - Groups for which the User is a member
      admGroupIds_ - Groups for which the User is an administrator
      userTypeId_ - this is one of UserProfile.USER_TYPE_BASIC or UserProfile.USER_TYPE_SYS_ADMIN
      username - the username of the user whose group membership is to be validated
      Returns:
      true if there is not change in the membership of the user
      Throws:
      InvalidAnonymousUserException - if the user calling this method is anonymous, but anonymous access has not been enabled
      InvalidUserException - if the user calling this method does not exist
      NullPointerException - if any of the input arrays are null
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • updateUsernames

      @Deprecated void updateUsernames(String[] oldUsernames_, String[] newUsernames_, long maxExpirationTimeInSeconds_) throws IllegalArgumentException, DuplicateNameException
      DEPRECATED: See UserService.renameUsersByUuid(java.lang.String[], java.lang.String[]) Updates a list of old usernames to new usernames.

      If successful, this method must be followed by commitUpdateUsernames(). After commitUpdateUsernames has been called, the old usernames will still be active, but will expire after the interval specified by maxExpirationTimeInSeconds_; if updateUsernames is successful but commitUpdateUsernames is not called, the new usernames will not become active.

      If unsuccessful, this method should be followed by rollbackUpdateUsernames(). This will simply free memory dedicated to mapping old usernames to new usernames.

      Parameters:
      oldUsernames_ - the usernames to be updated
      newUsernames_ - the usernames to which the old usernames will be updated
      maxExpirationTimeInSeconds_ - the interval, in seconds, after commitUpdateUsernames has been called, after which the old usernames will expire. If this parameter is zero or a negative value the old usernames will expire instantly. After expiration, the old usernames will no longer be valid.
      Throws:
      IllegalArgumentException - if the length of oldUsernames_ is not the same as the length of newUsernames_.
      DuplicateNameException - if any oldUsernames_ or newUsernames_ contain any duplicates, or if an old username is being updated to a username that already exists
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • commitUpdateUsernames

      @Deprecated void commitUpdateUsernames()
      DEPRECATED: See UserService.renameUsersByUuid(java.lang.String[], java.lang.String[]) Commits an update of usernames.

      This method should be preceded by a call to updateUsernames(String[], String[], long). After the commit, the old usernames will be temporarily active, and will expire after the interval specified by maxExpirationTimeInSeconds_; if commitUpdateUsernames is not called, the new usernames will not become active.

      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • rollbackUpdateUsernames

      @Deprecated void rollbackUpdateUsernames()
      DEPRECATED: See UserService.renameUsersByUuid(java.lang.String[], java.lang.String[]) Rolls back an update of usernames.

      This method should be called if updateUsernames(String[], String[], long) is unsuccessful. The rollback will simply free memory dedicated to mapping old usernames to new usernames.

      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setApplicationAdministratorGroup

      void setApplicationAdministratorGroup(Long groupId_) throws PrivilegeException
      Determines which group users need to be in to have the application administrator role.
      Parameters:
      groupId - the id of the administrator group
      Throws:
      PrivilegeException - if the current user does not have permission to perform this action
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • reloadProperties

      @Deprecated void reloadProperties()
      Deprecated.
      reloading properties is now automatic, so this call is now unnecessary and does nothing.
      Reloads all database-level properties files (*.xml, *.properties) without interrupting API services
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • validate

      String validate()
      Runs validation tests against the database to check whether it is corrupt, and returns a line-separated list of validation results
      Returns:
      the validation results
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setSiteLocaleSettings

      void setSiteLocaleSettings(SiteLocaleSettings settings_)
      Registers the site locale settings on the process design server. Use GlobalizationService.setSiteLocaleSettings(SiteLocaleSettings) if you need to update the site locale settings for all the product Servers.
      Parameters:
      settings_ - The site locale settings.
    • getEventsForProcessModelPaging

      ResultPage getEventsForProcessModelPaging(Long pmId_, Long[] eventTypes_, Boolean includeStartEvents_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_)
      Returns the Events for a given ProcessModel specified by eventTypes_.
      Parameters:
      pmId_ - ID of the ProcessModel for which to retrieve Event objects
      eventTypes_ - types of events to retrieve. This is one of XXX_EVENT_YYY constants in Event
      includeStartEvents_ - whether start events should be included
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in Event
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      A ResultPage which contains an array of Events
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • findEventsPaging

      ResultPage findEventsPaging(String searchString_, Long pmId_, Long[] eventTypes_, Boolean includeStartEvents_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_)
      Searches for Events associated with the given Process Model that match the specified searchString.
      Parameters:
      searchString_ - search string to search the Events' names.
      pmId_ - ID of the ProcessModel for which to retrieve Event objects. If the ID is null, then events for all process models are searched.
      eventTypes_ - types of events to retrieve. This is one of XXX_EVENT_YYY constants in Event
      includeStartEvents_ - Whether or not events on start node should be returned
      includeConsuming_ - whether or not consuming events should be returned
      includeProducing_ - whether or not producing events should be returned
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. Use Constants.COUNT_ALL to return the entire collection, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted. This is one of the SORT_BY_XXX constants located in Event
      sortOrder_ - the order in which to sort the results. This is one of Constants.SORT_ORDER_ASCENDING or Constants.SORT_ORDER_DESCENDING
      Returns:
      A ResultPage which contains an array of Event objects that match the search criteria
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getEventOrProcessModelNames

      String[] getEventOrProcessModelNames(Long[] pmIds_, String[] eventPersistentIds_)
      Returns the display names of processModels and Events for the provided ProcessModel Ids and Event Ids
      Parameters:
      pmIds_ - Ids of Process Models to get the display name of
      eventPersistentIds_ - Persistent Ids of Events (EventTrigger)to get the display name for
      Returns:
      displayNames of ProcessModels and Events. First part of the array is ProcessModels depending on the pmIds_ count and later part of array is Events depending on the eventIds_ count.
      Throws:
      NullPointerException - if pmIds_ array or eventIds_ array is null.
    • getProcessModelIdsByUuids

      Long[] getProcessModelIdsByUuids(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter[][].class) String[] pmUUIDs_) throws PrivilegeException
      Returns the IDs of ProcessModels that match the given UUID.
      Parameters:
      pmUUIDs_ - Array of UUID Strings.
      Returns:
      an array of process model IDs that match the given UUIDs. null is returned for invalid UUID.
      Throws:
      PrivilegeException
    • getEmailAttachmentFolderIdForPm

      Long getEmailAttachmentFolderIdForPm(Long pm_) throws InvalidProcessModelException
      Returns the Id of the folder where attachments will be stored when an email message is sent to either the ProcessModel or any event within the ProcessModel
      Parameters:
      pm_ - ID of process model
      Returns:
      ID of the folder where attachments will be stored.
      Throws:
      InvalidProcessModelException - if the specified ProcessModel does not exist
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getPmIdForEvent

      Long getPmIdForEvent(String eventPersistentId_) throws InvalidEventException
      Returns the ID of the ProcessModel that the Event by given eventPersistentId belongs to.
      Parameters:
      eventPersistentId_ - Persistent ID of the Event
      Returns:
      ID of the Process Model
      Throws:
      InvalidEventException - If passed in event persistent ID is invalid
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • getEventsByPersistentId

      ResultList getEventsByPersistentId(String[] eventPersistentIds_)
      Returns a ResultList containing Events that correspond to the passed in array of Event persistent IDs.
      Parameters:
      eventPersistentIds_ - Array of Event persistent IDs.
      Returns:
      ResultList containing Event objects corresponding to the array of given persistent IDs. The result codes can be: ResultList.CODE_VALID if the action succeeded, or ResultList.CODE_INVALID if the event persistent ID is invalid.
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • setDashboardPageForProcessModel

      void setDashboardPageForProcessModel(Long processModelId, Long pageId) throws InvalidProcessModelException, PrivilegeException
      Sets a page as the Dashboard page for the given ProcessModel by processModelId.
      Parameters:
      processModelId - Id of the ProcessModel to associate the page with
      pageId - the id of the page to set as the Process Model's Dashboard page
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have permission to associate the Dashboard page for the ProcessModel
    • getDashboardPageForProcessModel

      Long getDashboardPageForProcessModel(Long processModelId_) throws InvalidProcessModelException
      Returns the dashboard Id that is used for the ProcessModel by given processModelId_
      Parameters:
      processModelId_ - Id of the process model
      Returns:
      Id of the dahsboard
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
    • removeDashboardPageForProcessModel

      void removeDashboardPageForProcessModel(Long processModelId) throws InvalidProcessModelException, PrivilegeException
      Disassociates the current Dashboard page for the given ProcessModel by processModelId.
      Parameters:
      processModelId - Id of the ProcessModel for which to remove its current Dashboard page
      Throws:
      InvalidProcessModelException - if the ProcesModel specified does not exist
      PrivilegeException - if the current user does not have permission to disassociate the Dashboard page from the ProcessModel
    • addProcessModelToFavorites

      void addProcessModelToFavorites(Long modelId_) throws InvalidProcessModelException, PrivilegeException
      Associates this ProcessModel by given modelId_ as one of the current user's favorites.
      Parameters:
      modelId_ - Id of the ProcessModel to be added as favorite.
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have permission to perform this action on the specified ProcessModel
      NullPointerException - if modelId_ is null
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • removeProcessModelFromFavorites

      void removeProcessModelFromFavorites(Long modelId_) throws InvalidProcessModelException, PrivilegeException
      Removes this ProcessModel by given modelId_ as one of the current user's favorites.
      Parameters:
      modelId_ - Id of the ProcessModel to be removed as favorite.
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have permission to perform this action on the specified ProcessModel
      NullPointerException - if modelId_ is null
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
    • handleMessages

      int[] handleMessages(InternalMessage[] messages_)
      Sends the messages to the design server to be handled by the Events framework, and returns appropriate result codes. The result codes can be: Message.SUCCESS_CODE if the messages are handled successfully Message.JMS_TYPE_NOT_PROVIDED_CODE if the message does not provide a valid JMS type Message.INVALID_USERNAME_CODE if the provided username is not valid. If a username is not provided, the result code will return as Message.SUCCESS_CODE because username may be anonymous. Message.DESTINATION_NOT_PROVIDED_CODE if the message does not specify a valid destination Message.DUPLICATE_MESSAGE_CODE if the message is a duplicate
      Parameters:
      messages_ - an array of InternalMessage objects to be processed by the Events framework
      Returns:
      the result codes
      Throws:
      com.appiancorp.asl3.servicefw.connect.ServiceException - if any system-level error occurs
      NullPointerException - if any of the messages in the messages_ array are null or if the array itself is null
    • validateUsernames

      Boolean[] validateUsernames(String[] usernames_)
      Returns an array of Boolean values, Boolean.TRUE if the user given by the username exists and Boolean.FALSE otherwise.
      Parameters:
      usernames_ - An array of usernames to validate
      Returns:
      An array of Boolean values
    • getProcessVariablesForModel

      ProcessVariable[] getProcessVariablesForModel(Long pmId_, boolean recursive_)
      Returns the list of all process variables in a given process model. If the recursive flag is set to true, process variables for all sub-process models (that have the transparency flag set to true) will also be returned.
      Parameters:
      pmId_ - Id of the ProcessModel to retrieve the process variables of
      recursive_ - true if you want to retrieve process variables from the child process models (and their child models in turn).
      Returns:
      An array of ProcessVariable objects.
      Throws:
      NullPointerException - if pmId_ is null.
    • getProcessVariablesForModel

      ProcessVariable[] getProcessVariablesForModel(@ConvertWith(com.appiancorp.kougar.mapper.parameters.UuidParameterConverter.class) String uuid, boolean recursive) throws InvalidProcessModelException
      Returns the list of all process variables in a given process model. If the recursive flag is set to true, process variables for all sub-process models (that have the transparency flag set to true) will also be returned.
      Parameters:
      uuid_ - UUID which specifies the ProcessModel to retrieve the process variables of, as if by getProcessModelIdByUuid
      recursive_ - true if you want to retrieve process variables from the child process models (and their child models in turn).
      Returns:
      An array of ProcessVariable objects.
      Throws:
      NullPointerException - if pmId_ is null.
      InvalidProcessModelException
    • getCurrentNotePaths

      @Deprecated String[] getCurrentNotePaths()
      Deprecated.
      since 23.2
    • setCurrentNotePaths

      @Deprecated void setCurrentNotePaths(String[] notePaths_) throws PrivilegeException
      Deprecated.
      since 23.2
      Throws:
      PrivilegeException
    • getExpressionDependencies

      ExpressionDependency getExpressionDependencies(String expressionText, String... parameterNames)
      Returns the expression dependencies for the given expressionText. See ExpressionDependency
      Parameters:
      expressionText - Expression for which the dependencies will be determined
      parameterNames - Parameters of the expression. Only apply when the expression is part of a rule definition; pass null if it's not a rule definition.
      Returns:
      The ExpressionDependency for the given expression
    • getExpressionDependencies

      ExpressionDependency[] getExpressionDependencies(String[] expression, String[] parameterNames)
      Returns an array of the ExpressionDependency objects for the given expressions.
      Parameters:
      expression - Array of expressions for which the dependencies are to be determined.
      parameterNames - Parameters of the expressions. Only apply when the expressions are part of a rule definition; pass null if it's not a rule definition.
      Returns:
      An array of ExpressionDependency objects for the given expressions.
    • evaluateExpressionInVariableContext

      PartialResult evaluateExpressionInVariableContext(String expression, NamedTypedValue[] typedVariables, NamedTypedValue[] continueParams)
    • evaluateExpression

      TypedValue evaluateExpression(String expression) throws com.appiancorp.process.expression.ExpressionEvaluationException
      Evaluate the given expression (including java expression functions). The time zone used for the evaluation is the time zone in the service context used to acquire the service.
      Parameters:
      expression - The expression to evaluate.
      Returns:
      The result of the expression.
      Throws:
      com.appiancorp.process.expression.ExpressionEvaluationException - If an error occurs during the evaluation of the expression.
    • externalizeExpression

      String externalizeExpression(String expression, String... parameterNames)
      Replaces rule names with UUIDs within the given expression. Replaces type literals by id with type literals by name of exact type (including deactivated types).
      Parameters:
      expression - expression with rule names
      parameterNames - parameter names in expressions. Used to resolve conflicts between unqualified variables, like unqualified rule inputs in rule definitions, and other rule names
      Returns:
      expression with rule names replaced by UUIDs
    • internalizeExpression

      String internalizeExpression(String expression)
      Replaces UUIDs with rule names within the given expression. Replaces type literals by name with type literals by id.
      Parameters:
      expression - expression with UUIDs
      Returns:
      expression with UUIds replaced by rule names
    • getRuleIdReferences

      Long[] getRuleIdReferences(Long pmId) throws PrivilegeException, InvalidProcessModelException
      Gets all the rule ids that the expressions within the process model with pmId id contain, including nested rules referenced by all the expressions.
      Parameters:
      pmId - process model id
      Returns:
      collection of rule ids
      Throws:
      InvalidProcessModelException - if the ProcessModel specified by pmId does not exist
      PrivilegeException - if the current User does not have sufficient privileges to view the ProcessModel
    • getRuleUuidReferences

      String[] getRuleUuidReferences(ProcessModel pm)
      Gets all the rule UUID references that the expressions within the process model bean (pm) contain.
      Parameters:
      pm - process model bean
      Returns:
      collection of rule UUID references
    • evaluateExpression

      TypedValue evaluateExpression(String expression, NamedTypedValue[] variableValues) throws com.appiancorp.process.expression.ExpressionEvaluationException
      Evaluate the given expression (including java expression functions). The given variable values are substituted into the expression during evaluation. For example, if the expression is a rule's definition, the variable values should hold values for all of the rule's parameters.
      Parameters:
      expression - The expression to evaluate.
      variableValues - Values for all the variables used in the given expression. The name, instance type, and value of each variable value must be set. For example, if the expression is: ="Hello "&!firstName The variableValues array should hold a single NamedTypedValue object with the name "firstName", instance type AppianTypeLong.STRING and a value such as "John".
      Returns:
      The result of the expression.
      Throws:
      com.appiancorp.process.expression.ExpressionEvaluationException - If an error occurrs during the evaluation of the expression.
    • setProcessDashboardPageForProcessModel

      void setProcessDashboardPageForProcessModel(Long processModelId_, Long pageId_) throws InvalidProcessModelException, PrivilegeException
      Sets a particular page as the dashboard for every instance of a given ProcessModel by processModelId.
      Parameters:
      processModelId_ - The ID of the process model whose processes will be nabbed
      pageId_ - The ID of the page that will serve as the dashboard for those processes.
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have permission to associate the Dashboard page for the ProcessModel
    • getProcessDashboardPageForProcessModel

      Long getProcessDashboardPageForProcessModel(Long processModelId_) throws InvalidProcessModelException
      Returns the dashboard Id that is used for all processes spawned from the ProcessModel by given processModelId_
      Parameters:
      processModelId_ - Id of the process model
      Returns:
      Id of the dahsboard
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
    • removeProcessDashboardPageForProcessModel

      void removeProcessDashboardPageForProcessModel(Long processModelId_) throws InvalidProcessModelException, PrivilegeException
      Removes any custom dashboards created for instances of a particular process model. Instances will use the system default dashboard page instead.
      Parameters:
      processModelId_ - The ID of the process model
      Throws:
      InvalidProcessModelException - if the ProcessModel specified does not exist
      PrivilegeException - if the current user does not have permission to associate the Dashboard page for the ProcessModel
    • getLingeringTasksForProcessModel

      ResultPage getLingeringTasksForProcessModel(Long processModelId_, boolean recursive_, int startIndex_, int batchSize_, Integer sortProperty_, Integer sortOrder_) throws InvalidProcessException, PrivilegeException
      Returns all instances of lingering nodes in the specified process. Lingering nodes are those whose instances are known only to the execution server and are not notified externally as long as they are active. One example of such nodes is quick tasks.
      Parameters:
      processModelId_ - the id of the process model for which the lingering tasks should be retrieved
      recursive - whether to return the lingering tasks of the sub-process models of the given process model also
      startIndex_ - the index into the collection of total results at which to start. Negative numbers are treated as zeros.
      batchSize_ - the number of results to return. use of Constants.COUNT_ALL will result in the entire collection being returned, but this is STRONGLY discouraged.
      sortProperty_ - the property by which the results will be sorted This is one of the SORT_BY_XXX constants in TaskDesignProperties
      sortOrder_ - Constants.SORT_ORDER_ASCENDING for sorting results in ascending order, Constants.SORT_ORDER_DESCENDING for sorting results in descending order
      Returns:
      a ResultPage of TaskDesignProperties objects
      Throws:
      InvalidProcessException - if the given process id is invalid
      PrivilegeException - if the user doesn't have privileges to see the model
    • validateTypedValues

      boolean validateTypedValues(TypedValue[] typedValues)
      Validates given TypedValues. This method is free to throw an exception or to return false if any TypedValue passed is invalid for this engine. This engine supports: AppianType.PROCESS_MODEL
      Parameters:
      typedValues -
      Returns:
      true if valid, false if invalid
    • setTimeZone

      void setTimeZone(BackendTimeZoneSimple tz)
      Set a backend timezone.
      Parameters:
      tz -
    • setTimeZoneSameAs

      void setTimeZoneSameAs(BackendTimeZoneSimple tz, String sameAsId)
      Set a backend timezone to have the same rules as another backend timezone the sameAsId.
      Parameters:
      tz -
      sameAsId -