filenet.vw.api

Class VWWorkflowDefinition

  • java.lang.Object
    • filenet.vw.api.VWWorkflowDefinition
  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable


    public final class VWWorkflowDefinition
    extends java.lang.Object
    implements java.io.Serializable, java.lang.Cloneable
    Use this class to create, delete, and access a workflow and its sub-objects. A workflow definition is the basis of an authored workflow and includes a user-created graphical map showing the sequences, resources, and routing logic of the specific steps needed to complete the workflow process.

    A workflow can be persisted by saving a workflow definition object to a file.

    Since:
    VWWS3.10
    See Also:
    VWMapDefinition, VWFieldDefinition, VWException, Serialized Form
    • Field Detail

      • LVALUE

        public static final int LVALUE
        Value of 0: A subscript for the pre or post assignment arrays.
        See Also:
        Constant Field Values
      • RVALUE

        public static final int RVALUE
        Value of 1: A subscript for the pre or post assignment arrays.
        See Also:
        Constant Field Values
    • Constructor Detail

      • VWWorkflowDefinition

        public VWWorkflowDefinition()
                             throws VWException
        Creates a VWWorkflowDefinition instance.
        Throws:
        VWException
    • Method Detail

      • validate

        public VWValidationError[] validate(VWSession theSession,
                                   boolean fixupSteps)
                                     throws VWException
        Validates this instance.

        When looking for the base workflow signature during validation, the workflow collection is searched first because this is what a transfer will use. If the base workflow does not exist in the collection, it is retrieved from the server. If the base workflow does exist in the collection, but it does not have the transfer flag set (see VWWorkflowDefinition.setTransferFlag(boolean), a validation warning will occur.

        Parameters:
        theSession - The current VWSession object if logged on. This is needed for various parts of the validation process. This can be null; however, areas of validation requiring a logon will not be validated.
        fixupSteps - A boolean value of true to indicate that the step ID values for joins (steps that are AND'd) are to be filled in. Specify false if you do not want the step IDs to be filled in for the join, or to indicate that the caller has already specified the join step IDs.
        Returns:
        An array of VWValidationError objects that describe the validation errors encountered if this workflow is invalid, or null if this workflow is valid.
        Throws:
        VWException - Thrown if an error occurs during validation.
        See Also:
        VWWorkflowDefinition.setTransferFlag(boolean)
      • validate

        public VWValidationError[] validate(VWSession theSession,
                                   VWSystemConfiguration theSystemConfig,
                                   java.lang.String sdfFileContents)
                                     throws VWException
        Validates this instance.

        When looking for the base workflow signature during validation, the workflow collection is searched first because this is what a transfer will use. If the base workflow does not exist in the collection, it is retrieved from the server. If the base workflow does exist in the collection, but it does not have the transfer flag set (see VWWorkflowDefinition.setTransferFlag(boolean), a validation warning will occur.

        Parameters:
        theSession - The current VWSession object. This is needed for various parts of the validation process. This can be null; however, areas of validation requiring a logon will not be validated.
        theSystemConfig - A VWSystemConfiguration object to be used for validation (instead of retrieving this information from the Process Engine server). This value can be null.
        sdfFileContents - A String containing the contents of a solution definition file (SDF). This file is created by IBM Case Manager Builder.
        Returns:
        An array of VWValidationError objects that describe the validation errors encountered if this workflow is invalid, or null if this workflow is valid.
        Throws:
        VWException - Thrown if an error occurs during validation.
        Since:
        PE 5.0.0.0
      • createFieldUsingString

        public VWFieldDefinition createFieldUsingString(java.lang.String theName,
                                               java.lang.String theValueString,
                                               int theType,
                                               boolean theIsArray)
                                                 throws VWException
        Creates a data field in this workflow definition, with values initialized by a field.
        Parameters:
        theName - Name of the field to create.

        theValueString - Initial value for the data field.

        theType - An integer value specifying the data type to which the value expression should evaluate.

        theIsArray - Specify true to indicate that the value expression is to evaluate to an array; otherwise, specify FALSE.
        Returns:
        VWFieldDefinition object that represents the newly created data field.
        Throws:
        VWException
        See Also:
        VWFieldType, VWFieldDefinition
      • deleteField

        public void deleteField(java.lang.String theName)
                         throws VWException
        Deletes a field definition from the workflow definition.
        Parameters:
        theName - Name of the field definition to delete. The name can be passed to this method from a set of field definitions associated with this workflow definition.
        Throws:
        VWException - Thrown if the system encounters an error while attempting to delete the field, or if the system cannot find the specified field.
        See Also:
        VWFieldDefinition
      • createMap

        public VWMapDefinition createMap(java.lang.String theName)
                                  throws VWException
        Creates a new map in this workflow definition.
        Parameters:
        theName - Name of the new map.
        Returns:
        Newly created map definition.
        Throws:
        VWException
        See Also:
        VWMapDefinition
      • insertMap

        public VWMapDefinition insertMap(VWMapDefinition theMap)
                                  throws VWException
        Inserts a map in this workflow definition. This method can be useful for copying maps from one VWWorkflowDefinition to another.
        Parameters:
        theMap - A map to be inserted into this workflow definition.
        Returns:
        Newly inserted map definition.
        Throws:
        VWException - Thrown if a map with the same name as the map being inserted already exists in this workflow definition.
        See Also:
        VWMapDefinition
      • insertField

        public VWFieldDefinition insertField(VWFieldDefinition theField)
                                      throws VWException
        Inserts a field in this workflow definition. This method can be useful for copying fields from one VWWorkflowDefinition to another.
        Parameters:
        theField - a field to be inserted into this workflow definition.
        Returns:
        Newly inserted field definition.
        Throws:
        VWException - Thrown if a field with the same name as the field being inserted already exists in this workflow definition.
        See Also:
        VWFieldDefinition
      • insertMilestone

        public VWMilestoneDefinition insertMilestone(VWMilestoneDefinition theMilestone)
                                              throws VWException
        Inserts a milestone in this workflow definition. This method can be useful for copying milestones from one VWWorkflowDefinition to another.
        Parameters:
        theMilestone - A milestone to be inserted into this workflow definition.
        Returns:
        Newly inserted milestone definition.
        Throws:
        VWException - Thrown if a milestone with the same name as the milestone being inserted already exists in this workflow definition.
        See Also:
        VWMilestoneDefinition
      • insertRuleSet

        public VWRuleSetDefinition insertRuleSet(VWRuleSetDefinition theRuleSet)
                                          throws VWException
        Inserts a ruleset in this workflow definition. This method can be useful for copying rulesets from one VWWorkflowDefinition to another.
        Parameters:
        theRuleSet - A ruleset to be inserted into this workflow definition.
        Returns:
        Newly inserted ruleset definition.
        Throws:
        VWException - Thrown for various causes, including when a ruleset with the same value as the ruleset being inserted already exists in this workflow definition.
        See Also:
        VWRuleSetDefinition
      • insertPartnerLink

        public VWPartnerLinkDefinition insertPartnerLink(VWPartnerLinkDefinition thePartnerLink)
                                                  throws VWException
        Inserts a partner link in this workflow definition. This method can be useful for copying partner links from one VWWorkflowDefinition to another.
        Parameters:
        thePartnerLink - A partner link to be inserted into this workflow definition.
        Returns:
        Newly inserted partner link definition.
        Throws:
        VWException - Thrown for various causes, including when a partner link with the same name as the partner link being inserted already exists in this workflow definition.
        See Also:
        VWPartnerLinkDefinition
      • insertSchema

        public VWSchema insertSchema(VWSchema theSchema)
                              throws VWException
        Inserts a schema in this workflow definition. This method can be useful for copying schemas from one VWWorkflowDefinition to another.
        Parameters:
        theSchema - A schema to be inserted into this workflow definition.
        Returns:
        Newly inserted schema definition.
        Throws:
        VWException
        See Also:
        VWSchema
      • deleteMap

        public void deleteMap(int theMapId)
                       throws VWException
        Note: Currently unsupported, this method throws an exception if called at run time. This method was originally intended to delete a workflow map definition, specified by map ID.
        Parameters:
        theMapId - An integer that contains the ID of the map to delete.
        Throws:
        VWException - Note Always thrown.
        See Also:
        VWMapDefinition
      • deleteMap

        public void deleteMap(java.lang.String theMapName)
                       throws VWException
        Deletes the specified map from this workflow definition.
        Parameters:
        theMapName - Name of the map to be deleted.
        Throws:
        VWException - Thrown if the map cannot be found.
        See Also:
        VWMapDefinition
      • getName

        public java.lang.String getName()
        Gets the name property for this workflow definition. If a translation source exists, the authored name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A String containing the translated name, if a translation source exists; otherwise the authored name is returned.
        See Also:
        setName
      • setName

        public void setName(java.lang.String theName)
                     throws VWException
        Changes the name property for this workflow definition.
        Parameters:
        theName - Name of this workflow definition. The name cannot begin with a tilde ('~') character, because this denotes a name that is reserved for internal use. The name cannot be null.
        Throws:
        VWException - Thrown for various causes, including when theName parameter begins with a tilde ('~') character, or the name is null.
      • getBaseWorkClassName

        public java.lang.String getBaseWorkClassName()
        Gets the this workflow definition's base work class name. This is the name of the work class from which this workflow definition will inherit at transfer or initialization, specified using VWWorkflowDefinition.setBaseWorkClassName(String). If a translation source exists, the authored work class name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A String containing the translated name of the base work class, if a translation source exists; otherwise the authored name is returned. Unless the base work class has been changed using VWWorkflowDefinition.setBaseWorkClassName(String), "WorkObjectEx" is returned.
      • setBaseWorkClassName

        public void setBaseWorkClassName(java.lang.String theBaseWorkClassName)
                                  throws VWException
        Changes the value of this workflow definition's base work class name. This is the name of the work class from which this workflow definition will inherit upon transfer or initialization.
        Parameters:
        theBaseWorkClassName - A String containing the new name of the work class from which this workflow definition will inherit upon transfer or initialization.
        Throws:
        VWException - Thrown if the name does not indicate a valid base work class.
      • getRosterName

        public java.lang.String getRosterName()
        Gets this workflow definition's roster name. If a translation source exists, the authored roster name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A String containing the translated name of the roster for this instance, if a translation source exists; otherwise the authored name is returned. Null is returned when the roster inherits its name property from the base work class.
        See Also:
        setRosterName, getBaseWorkClassName
      • setRosterName

        public void setRosterName(java.lang.String theRosterName)
                           throws VWException
        Changes the roster name for this workflow definition. The Process Engine applies this roster name to the roster during transfer or initialization of the roster.
        Parameters:
        theRosterName - Roster name for this workflow definition, or null. Null causes the associated roster to inherit its name property from the roster name property of the base work class, when the roster is transferred or initialized.
        Throws:
        VWException - Thrown if the roster name is invalid.
        See Also:
        VWWorkflowDefinition.getBaseWorkClassName()
      • getEventLogName

        public java.lang.String getEventLogName()
        Gets the name of this workflow definition's event log. If a translation source exists, the authored event log name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A String containing the translated name of the event log for this instance, if a translation source exists; otherwise the authored name is returned. Null is returned when the event log inherits its name property from the base work class.
        See Also:
        setEventLogName
      • setEventLogName

        public void setEventLogName(java.lang.String theEventLogName)
                             throws VWException
        Changes the event log name for this workflow definition. This workflow definition uses this event log name during transfer or initialization processes.
        Parameters:
        theEventLogName - Name of the event log that this workflow definition uses during transfer or initialization processes, or null. Null is returned when the event log name property will be inherited from the base work class.
        Throws:
        VWException - Thrown if the event log name is invalid.
      • getAuthorTool

        public java.lang.String getAuthorTool()
        Gets the value of this workflow definition's authorTool property. The authorTool property may be used to identify the application that generated this workflow definition.
        Returns:
        authorTool property for this workflow definition. A null value is valid.
      • setAuthorTool

        public void setAuthorTool(java.lang.String theAuthorTool)
                           throws VWException
        Changes the value of this workflow definition's authorTool property. The authorTool property may be used to identify the application that generated this workflow definition.
        Parameters:
        theAuthorTool - New authorTool property value for this workflow definition.
        Throws:
        VWException
      • addAdditionalAuthorTool

        public void addAdditionalAuthorTool(java.lang.String authorTool)
        Add additional author tool info to indicate that another author tool is used to author the workflow definitoin
        Parameters:
        authorTool -
      • getTag

        public java.lang.String getTag()
        Gets the tag expression of this workflow definition.
        Returns:
        The tag expression.
      • setTag

        public void setTag(java.lang.String theTag)
                    throws VWException
        Changes the tag property of this workflow definition.
        Parameters:
        theTag - New tag expression for the workflow definition. The expression can be of any valid type. The expression must meet specific guidelines for expressions; for detailed information about expression guidelines refer to the Expressions book, in the Reference section, of the Designer online help.
        Throws:
        VWException
      • getDescription

        public java.lang.String getDescription()
        Gets the description property of this workflow definition. If a translation source exists, the authored description is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A String containing the translated name of the description for this instance, if a translation source exists; otherwise the authored description is returned.
      • setDescription

        public void setDescription(java.lang.String theDescription)
        Changes the description property of this workflow definition.
        Parameters:
        theDescription - New description for this workflow definition.
      • getMainAttachmentName

        public java.lang.String getMainAttachmentName()
        Gets the name of the main attachment of this workflow definition. If a translation source exists, the authored attachment name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A String containing the translated name of the main attachment for this instance, if a translation source exists; otherwise the authored name is returned. If no main attachment is found for this instance, null is returned.

        Pass the returned name to VWWorkflowDefinition.getField(String) to get the VWFieldDefinition object.

        See Also:
        VWFieldDefinition, VWAttachment
      • setMainAttachmentName

        public void setMainAttachmentName(java.lang.String theName)
                                   throws VWException
        Modifies the main attachment name property of this workflow definition.
        Parameters:
        theName - New main attachment name associated with this workflow definition. The name must be that of a field in this workflow definition, and the type of the field must be VWFieldType.FIELD_TYPE_ATTACHMENT. This value is available at run time in the launch step as a String parameter called F_MAINATTACHMENT. Since the run time parameter is a String, the theName parameter must be a quoted String.
        Throws:
        VWException - Thrown if the theName parameter is not a quoted String.
        See Also:
        VWFieldDefinition, VWFieldType
      • getField

        public VWFieldDefinition getField(java.lang.String theName)
                                   throws VWException
        Gets the definition of a data field from this workflow definition.
        Parameters:
        theName - A String containing the name of the field. If a translation source exists, the authored field name is translated.
        Returns:
        A VWFieldDefinition object representing the data field specified.
        Throws:
        VWException - Thrown if the specified data field cannot be found.
        See Also:
        VWFieldDefinition
      • getFields

        public VWFieldDefinition[] getFields()
                                      throws VWException
        Gets the set of fields associated with this workflow definition. If a translation source exists, the authored field names are translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        An array of VWFieldDefinition objects representing the data fields for this instance. If a translation source exists, the translated field names are returned; otherwise, the authored field names are returned.
        Throws:
        VWException - Thrown if the set of fields associated with this instance cannot be retrieved.
        See Also:
        VWFieldDefinition
      • getMainMap

        public VWMapDefinition getMainMap()
                                   throws VWException
        Gets the main map for this workflow definition. The map name is "Workflow", and its ID is negative 2 (-2). If a translation source exists, the authored map name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        A VWDefinition object that represents the main map in this workflow definition. If a translation source exists, the translated map name is returned; otherwise, the authored name is returned.
        Throws:
        VWException - Thrown if the main map cannot be retrieved.
        See Also:
        VWMapDefinition
      • getLaunchStep

        public VWStepDefinition getLaunchStep()
                                       throws VWException
        Gets the launch step in this workflow definition. If a translation source exists, the authored step name is translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        The launch step ID is zero (0), the step name is "LaunchStep", and it is contained in the map named "Workflow". The launch step is the first step to be executed when the workflow is launched. It cannot be deleted and cannot be the destination of any route.

        Returns:
        A VWDefinition object representing the launch step in this workflow definition. If a translation source exists, the translated step name is returned; otherwise, the authored step name is returned.
        Throws:
        VWException - Thrown if the launch step cannot be retrieved.
        See Also:
        VWMapDefinition, getMainMap, VWMapDefinition.getStartStep
      • getSubject

        public java.lang.String getSubject()
        Gets the subject of this workflow definition (the value of the F_Subject system field). If a translation source exists, the authored subject is translated.
        Returns:
        A String containing the translated subject, if a translation source exists; otherwise, the authored subject is returned.
      • setSubject

        public void setSubject(java.lang.String theSubject)
        Modifies the subject property of this workflow definition.
        Parameters:
        theSubject - New value of the subject property of this workflow definition.
        Note: The subject is a String that must contain a valid String expression, so it requires internal quotes, as shown in the following example:

        VWWorkflowDefinitionInstance.setSubject("\"my subject\"");

      • getMap

        public VWMapDefinition getMap(int theMapId)
                               throws VWException
        Deprecated. Replaced by VWWorkflowDefinition.getMap(String). Note: getMap(String) takes a map name as a parameter, rather than a map ID.
        Note: Currently unsupported, this method throws an exception if called at run time. This method was originally intended to retrieve a workflow map definition, specified by map ID.
        Parameters:
        theMapId - An integer representing the ID of the map the returned definition describes.
        Returns:
        VWMapDefinition object that represents the workflow map definition.
        Throws:
        VWException - WARNING: An exception is always thrown!
      • getMap

        public VWMapDefinition getMap(java.lang.String theName)
                               throws VWException
        Retrieves a workflow map based on the specified map name. All of the workflow maps associated with this workflow definition are searched for the specified name.
        Parameters:
        theName - A String containing the name of the workflow map to retrieve. If a translation source exists, the authored map name is translated.
        Returns:
        A VWMapDefinition object that represents the map specified.
        Throws:
        VWException - Thrown if the specified map cannot be found.
        See Also:
        VWMapDefinition
      • getMapIndex

        public int getMapIndex(java.lang.String theName)
                        throws VWException
        Returns the index of the specified workflow map associated with this workflow definition.
        Parameters:
        theName - A String containing the name of the workflow map.
        Returns:
        The index of the specified workflow map in the array of maps for this workflow definition.
        Throws:
        VWException - Thrown if the named map cannot be found.
        See Also:
        VWMapDefinition
      • getMaps

        public VWMapDefinition[] getMaps()
                                  throws VWException
        Gets the set of workflow maps associated with this workflow definition. If a translation source exists, the authored map names are translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        An array of VWMapDefinition objects representing all of the workflow maps associated with this workflow definition. If a translation source exists, the translated map names are returned; otherwise, the authored names are returned.
        Throws:
        VWException - Thrown if an error occurs retrieving the maps for this workflow definition.
        See Also:
        VWMapDefinition
      • getDeadline

        public long getDeadline()
        Retrieves the deadline property for this workflow definition. The deadline value represents the number of minutes between launching of the workflow and the expiration of the deadline timer at run time.
        Returns:
        A number indicating the deadline value expressed in minutes. Special returned value meanings are as follows:
        • 0 (zero): workflow has no deadline.
        • -1: deadline value is a time expression that cannot be converted to a long value.
      • setDeadline

        public void setDeadline(long theDeadline)
                         throws VWException
        Changes the deadline property for this workflow definition.
        Parameters:
        theDeadline - A positive, long integer that is either 0 (zero) or the number of minutes between launching of the workflow and the expiration of the workflow's deadline timer at run time. 0 (zero) signifies the workflow has no deadline.
        Throws:
        VWException - Thrown for various causes, including when the value specified in the theDeadline parameter is invalid.
      • getReminder

        public long getReminder()
        Retrieves the reminder property for this workflow definition.
        Returns:
        A positive, long integer indicating the number of seconds prior to expiration of the deadline timer that the reminder timer will expire at run time, or 0 (zero). 0 (zero) signifies the step has no reminder.
      • setReminder

        public void setReminder(long theReminder)
                         throws VWException
        Changes the reminder property for this workflow definition.
        Parameters:
        theReminder - A positive, long integer specifying the number of seconds prior to expiration of the deadline timer that the reminder timer will expire at run time, or 0 (zero). 0 (zero) signifies the step has no reminder.
        Throws:
        VWException - Thrown for various causes, including when the reminder value specified in the theReminder parameter is invalid.
      • read

        public static VWWorkflowDefinition read(java.io.InputStream theStream)
                                         throws VWException
        Evaluates a workflow definition from an input stream. The system creates the new VWWorkflowDefinition using values it reads from the input stream.
        Parameters:
        theStream - An input stream from which to read the VWWorkflowDefinition object definition.
        Returns:
        VWWorkflowDefinition object representing an instance of the data read from the stream specified in the theStream parameter.
        Throws:
        VWException - Thrown if it cannot evaluate a workflow definition from an input stream.
        See Also:
        VWWorkflowDefinition.write(java.io.OutputStream)
      • write

        public void write(java.io.OutputStream theStream)
                   throws VWException
        Writes this instance to an output stream.
        Parameters:
        theStream - An OutputStream object to which to write this instance.
        Throws:
        VWException - Thrown if this instance is unable to be written to the output stream specified.
        See Also:
        VWWorkflowDefinition.read(InputStream)
      • writeToFile

        public void writeToFile(java.lang.String theFileName)
                         throws VWException
        Writes this instance to a file.
        Parameters:
        theFileName - A String containing the name of the file to which to write this instance.
        Throws:
        VWException - Thrown if this instance cannot be written to the specified file.
        See Also:
        readFromFile, VWWorkflowDefinition.write(OutputStream)
      • toString

        public java.lang.String toString()
        Gets a String representation of this instance.
        Overrides:
        toString in class java.lang.Object
        Returns:
        A String representation of this workflow definition.
      • AsXMLString

        public java.lang.String AsXMLString()
                                     throws VWException
        Retrieves an XML-formatted representation of this workflow definition.
        Returns:
        A String containing a well-formed XML representation of this workflow definition.
        Throws:
        VWException - Thrown if this method cannot retrieve an XML formatted representation of this workflow definition.
        See Also:
        VWWorkflowDefinition.write(java.io.OutputStream)
      • getMilestone

        public VWMilestoneDefinition getMilestone(java.lang.String theName)
                                           throws VWException
        Gets the definition of a milestone from this workflow definition.
        Parameters:
        theName - A String containing the name of the milestone. If a translation source exists, the authored milestone name is translated.
        Returns:
        A VWMilestoneDefinition object that represents the milestone specified.
        Throws:
        VWException - Thrown if the milestone specified cannot be found.
        See Also:
        VWMilestoneDefinition
      • getMilestones

        public VWMilestoneDefinition[] getMilestones()
                                              throws VWException
        Returns the milestones for this workflow definition. If a translation source exists, the authored milestone names are translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        An array of VWMilestoneDefinition objects representing the milestones for this workflow definition. If a translation source exists, the translated milestone names are returned; otherwise, the authored names are returned. Null is returned when there are no milestones associated with this workflow.
        Throws:
        VWException
      • setMilestones

        public void setMilestones(VWMilestoneDefinition[] theMilestones)
                           throws VWException
        Replaces or reorders the array of milestones for this workflow definition, without adding or deleting milestones. The length of the theMilestones (input) array parameter must be equal to the current number of milestones in the workflow definition.
        Parameters:
        theMilestones - An array of VWMilestoneDefinition objects for this workflow definition, whose length equals the current number of milestones in the workflow definition. Null entries are invalid.
        Throws:
        VWException - Thrown for various causes, including when the array input parameter is invalid.
      • createMilestone

        public VWMilestoneDefinition createMilestone(java.lang.String theName)
                                              throws VWException
        Creates a new milestone in this workflow definition.
        Parameters:
        theName - Name of the new milestone.
        Returns:
        Newly created milestone definition as a VWMilestoneDefinition.
        Throws:
        VWException
        See Also:
        VWMilestoneDefinition
      • deleteMilestone

        public void deleteMilestone(java.lang.String theName)
                             throws VWException
        Deletes the specified milestone from this workflow definition.
        Parameters:
        theName - Name of the milestone to be deleted.
        Throws:
        VWException - Thrown if an error occurs while deleting the milestone.
        See Also:
        VWMilestoneDefinition
      • createPartnerLink

        public VWPartnerLinkDefinition createPartnerLink(java.lang.String theName)
                                                  throws VWException
        Creates a new partner link in this workflow definition.
        Parameters:
        theName - name for this partner link. Name must be non-null and non-zero length, and must not match an existing partner link name. The length of the partner link name must not exceed 15 characters. Partner link names can only contain letters numbers and underscores.
        Returns:
        Newly created partner link definition as a VWPartnerLinkDefinition object.
        Throws:
        VWException
        See Also:
        VWPartnerLinkDefinition
      • deletePartnerLink

        public void deletePartnerLink(java.lang.String theName)
                               throws VWException
        Deletes the specified partner link from this workflow definition.
        Parameters:
        theName - Name of the partner link to be deleted.
        Throws:
        VWException - Thrown for various causes, including when the named partner link cannot be found.
        See Also:
        VWPartnerLinkDefinition
      • getPartnerLink

        public VWPartnerLinkDefinition getPartnerLink(java.lang.String theName)
                                               throws VWException
        Gets the definition of a partner link from this workflow definition.
        Parameters:
        theName - A String containing the name of the partner link for instance. If a translation source exists, the authored partner link name is translated.
        Returns:
        A VWPartnerLinkDefinition object that represents the partner link specified.
        Throws:
        VWException - Thrown for various causes, including when the specified partner link cannot be found.
        See Also:
        VWPartnerLinkDefinition
      • createSchema

        public VWSchema createSchema(java.lang.String theName)
                              throws VWException
        Creates a new schema in this workflow definition.
        Parameters:
        theName - Name of the new schema.
        Returns:
        Newly created schema, as a VWSchema object.
        Throws:
        VWException
        See Also:
        VWSchema
      • deleteSchema

        public void deleteSchema(java.lang.String theName)
                          throws VWException
        Deletes the specified schema from this workflow definition.
        Parameters:
        theName - Name of the schema to be deleted.
        Throws:
        VWException - Thrown for various causes, including when the named schema cannot be found.
        See Also:
        VWSchema
      • getSchema

        public VWSchema getSchema(java.lang.String theName)
                           throws VWException
        Gets the specified schema for this workflow definition.
        Parameters:
        theName - A String containing the name of the schema. If a translation source exists, the authored schema name is translated.
        Returns:
        The VWSchema object for the specified schema.
        Throws:
        VWException - Thrown for various causes, including when the specified schema cannot be found.
        See Also:
        VWSchema
      • getPartnerLinks

        public VWPartnerLinkDefinition[] getPartnerLinks()
                                                  throws VWException
        Retrieves all of the partner links for this workflow definition. If a translation source exists, the authored partner link names are translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        An array of VWPartnerLinkDefinition objects representing the partner links associated with this workflow definition. If a translation source exists, the translated partner link names are returned; otherwise, the authored names are returned. Null is returned when no partner links are associated with this workflow definition.
        Throws:
        VWException
      • getSchemas

        public VWSchema[] getSchemas()
                              throws VWException
        Retrieves the schemas for this workflow definition. If a translation source exists, the authored schema names are translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        An array of VWSchema objects representing the schemas for this workflow definition. If a translation source exists, the translated schema names are returned; otherwise, the authored names are returned. Null is returned when there are no schemas associated with this workflow.
        Throws:
        VWException
      • setPartnerLinks

        public void setPartnerLinks(VWPartnerLinkDefinition[] ThePartnerLinks)
                             throws VWException
        Replaces or reorders the array of partner links for this workflow definition, without adding or deleting partner links. The length of the ThePartnerLinks (input) array parameter must be equal to the current number of partner links in the workflow definition.
        Parameters:
        ThePartnerLinks - An array of non-null VWPartnerLinkDefinition objects for this workflow definition, whose length equals the current number of partner links in the workflow definition.
        Throws:
        VWException - Thrown for various causes, including when the array input parameter is invalid.
      • setSchemas

        public void setSchemas(VWSchema[] TheSchemas)
                        throws VWException
        Replaces or reorders the array of schemas for this workflow definition, without adding or deleting schemas. The length of the TheSchemas (input) array parameter must be equal to the current number of schemas in the workflow definition.
        Parameters:
        TheSchemas - An array of non-null VWSchema objects for this workflow definition, whose length equals the current number of schemas in the workflow definition.
        Throws:
        VWException - Thrown for various causes, including when the array input parameter is invalid.
      • getDisableEmailNotification

        public boolean getDisableEmailNotification()
        Gets the workflow's disable email notification property.
        Returns:
        true if email notification is disabled for this workflow; false otherwise.
      • setDisableEmailNotification

        public void setDisableEmailNotification(boolean bFlag)
        Sets the workflow's disable email notification property.
        Parameters:
        bFlag - true specifies email notification is disabled for this workflow; false specifies otherwise.
      • getRuleSets

        public VWRuleSetDefinition[] getRuleSets()
                                          throws VWException
        Retrieves the rule sets for this workflow definition. If a translation source exists, the authored rule set names are translated.

        Note: The translation is done only at run time, so will not appear in design-time applications (such as the Process Designer or Configuration Console).

        Returns:
        An array of VWRuleSetDefinition objects representing the rule sets for this workflow definition. If a translation source exists, the translated rule set names are returned; otherwise, the authored names are returned. Null is returned when there are no rule sets associated with this workflow.
        Throws:
        VWException
      • createRuleSet

        public VWRuleSetDefinition createRuleSet(java.lang.String theValue)
                                          throws VWException
        Creates a new rule set (VWRuleSetDefinition object) in this workflow.
        Parameters:
        theValue - A String defining the new rule set value.
        Returns:
        The VWRuleSetDefinition object created.
        Throws:
        VWException
      • deleteRuleSet

        public void deleteRuleSet(VWRuleSetDefinition theRuleSet)
                           throws VWException
        Deprecated. Use public void deleteRuleSet(String theRuleSetName) instead. Changes in the API to support inheriting rulessets make it is no longer possible to support deleting rulesets by reference. Rulesets should be deleted by name. This method calls deleteRuleSet(theRuleSet.getName()).
        Parameters:
        theRuleSet - the rule set to delete
        Throws:
        VWException
      • deleteRuleSet

        public void deleteRuleSet(java.lang.String theRuleSetName)
                           throws VWException
        Deletes the specified rule set definition from this instance, removing all references to the rule set from the workflow definition steps.
        Parameters:
        theRuleSetName - A String containing the name of the VWRuleSetDefinition object to be deleted.
        Throws:
        VWException - Thrown if the parameter is null or the specified name cannot be found.
      • getIncomingWSAttachmentFolder

        public java.lang.String getIncomingWSAttachmentFolder()
        Gets the String representation for an attachment that specifies a folder for storing incoming Web Services attachments that are available through a receive instruction.
        Returns:
        The String representation for a folder attachment that can be used to construct a VWAttachment object, or null if no incoming attachments folder was previously specified for this workflow definition.
        See Also:
        VWAttachment, VWAttachmentType
      • setVersionAgnostic

        public void setVersionAgnostic(boolean theAgnosticFlag)
        Determines whether or not the workflow revision for the received instruction (the value of the F_WorkClassRevision field) is one of the selection criteria used to match the correct work item.
        Parameters:
        theAgnosticFlag - A boolean value of true (the default) to perform message correlation without using the workflow revision. Specify false if the received message will not change format and can be received by any revision of the workflow. Workflow revision will then be used as one of the selection criteria to find the correct work item.
      • getVersionAgnostic

        public boolean getVersionAgnostic()
        Returns the value of the versionAgnostic flag set for this workflow definition.
        Returns:
        A boolean value of true if message correlation is performed without using the workflow revision for the received instruction; false if the workflow revision is used as one of the selection criteria to find the correct work item.
        See Also:
        setVersionAgnostic
      • setValidateUsingSchema

        public void setValidateUsingSchema(boolean theValidateUsingSchemaFlag)
        Determines whether process orchestration messages are to be validated (at run time) using the appropriate schema.
        Parameters:
        theValidateUsingSchemaFlag - A boolean value of true to validate process orchestration messages at run time using the appropriate schema; otherwise, false.
      • getValidateUsingSchema

        public boolean getValidateUsingSchema()
        Indicates process orchestration messages are validated (at run time) using the appropriate schema.
        Returns:
        A boolean value of true if process orchestration messages are validated at run time using the appropriate schema; otherwise, false.
        See Also:
        setValidateUsingSchema
      • setTransferFlag

        public void setTransferFlag(boolean theTransferFlag)
        Sets the transfer flag for this workflow definition. This property provides control over the transfer of individual VWWorkflowDefinitions within the VWWorkflowCollectionDefintion.
        Parameters:
        theTransferFlag - A boolean value of true indicates that transferring a VWWorkflowCollectionDefinition containing this VWWorkflowDefinition will transfer this workflow. A value of false indicates this workflow will not be transferred if a VWWorkflowCollectionDefinition containing this VWWorkflowDefinition is transferred.
        See Also:
        VWWorkflowCollectionDefinition
      • clone

        public java.lang.Object clone()
        Creates a clone of this VWWorkflowDefinition object.
        Overrides:
        clone in class java.lang.Object
        Returns:
        A VWWorkflowDefinition object that is a clone of this instance.
        Since:
        P8 4.5.0
      • convertAllRouteConditionsToValidExpressions

        public void convertAllRouteConditionsToValidExpressions()
                                                         throws VWException
        Converts the route conditions for each route in this workflow definition to the standard syntax format: Expressions containing "ALL", "NONE", "ANY" or "COUNT" are converted to expressions using the F_Responses and F_ResponseCount fields. This conversion is normally done automatically during transfer. However, this method can be useful for applications (such as a process simulator) that need to deal with actual route condition expressions used by the Process Engine.

        Warning: Calling this method permanently changes all route condition expressions in this workflow definition to a less user-friendly form. For example, an expression that checked whether all participants in a step chose the response "YES", would change from "ALL(YES)" to "F_Responses[1] = F_ResponseCount" (in this case, assuming 1 is the index of the "YES" response in the F_Responses array). The only way to revert the change is to reread the PEP file containing the original route conditions, which may cause the loss of other changes.

        Throws:
        VWException
      • getFlattenedCopy

        public VWWorkflowDefinition getFlattenedCopy(VWSession theSession)
                                              throws VWException
        Returns a copy of this workflow that includes attributes inherited from the parent workflow. The algorithm used for flattening the workflow definition follows the model used on the Process Engine server at transfer time. The parent workflow definition must be available on the Process Engine server, because it is fetched to make the flattened copy.

        Inherited attributes are maps, fields, rule sets, milestones, schemas and partnerlinks. Attributes from this (child) workflow definition override attributes of the same name and type inherited from the parent workflow definition.

        The name of the flattened copy will be the result of the espression ' this.getName() + "_FLATTENED" '. The base work class name of the flattened copy will be "WorkObjectEx".

        Parameters:
        theSession - The VWSession object that will be used to retrieve the parent workflow definition from the Process Engine server.
        Returns:
        A VWWorkflowDefinition object that is a copy of this instance, including attributes inherited from the parent workflow.
        Throws:
        VWException - if an error occurs, for example if the parent workflow is not found on the server.
      • getIsDynamicWorkflow

        public boolean getIsDynamicWorkflow()
        Returns:
        true if this is a dynamic workflow. Only valid if the workflow has been fetched from the server.

© Copyright IBM Corporation 2002, 2013. All rights reserved.