Interface IMultipleConditionBuilder

    • Method Detail

      • build

        WorkflowNode build()
                    throws FastJsonException
        Creates a new multiple condition node with the current configuration. Changes to the builder after this method has been called will not affect the created node.
        Returns:
        The created multiple condition node.
        Throws:
        FastJsonException - When the properties model could not be serialized.
      • buildProps

        FcMultipleConditionProps buildProps()
        Creates a new multiple condition properties POJO with the current configuration. Changes to the builder after this method has been called will not affect the created node.
        Returns:
        The created multiple condition properties.
      • description

        IMultipleConditionBuilder description​(String description)
        Sets the description of the multiple condition node.
        Parameters:
        description - The description.
        Returns:
        This builder for chaining method calls.
      • labelNo

        IMultipleConditionBuilder labelNo​(String labelNo)
        Sets the label to be used for the "no" branch of the condition.
        Parameters:
        labelNo - The label for the "no" branch.
        Returns:
        This builder for chaining method calls.
      • labelYes

        IMultipleConditionBuilder labelYes​(String labelYes)
        Sets the label to be used for the "yes" branch of the condition.
        Parameters:
        labelYes - The label for the "yes" branch.
        Returns:
        This builder for chaining method calls.
      • name

        IMultipleConditionBuilder name​(String name)
        Sets the name of the multiple condition node.
        Parameters:
        name - The name.
        Returns:
        This builder for chaining method calls.
      • whenFalse

        IMultipleConditionBuilder whenFalse​(WorkflowNode... alternate)
        Sets the child nodes to execute when the condition evaluates to false.

        Can be any node or list of nodes. When not a single node of type EWorkflowNodeType.SEQUENCE, the node or nodes are wrapped in a sequence node.

        Parameters:
        alternate - The child nodes to execute.
        Returns:
        This builder for chaining method calls.
      • whenFalse

        default IMultipleConditionBuilder whenFalse​(Iterable<WorkflowNode> alternate)
        Sets the child nodes to execute when the condition evaluates to false.

        Can be any node or list of nodes. When not a single node of type EWorkflowNodeType.SEQUENCE, the node or nodes are wrapped in a sequence node.

        Parameters:
        alternate - The child nodes to execute.
        Returns:
        This builder for chaining method calls.
      • whenTrue

        IMultipleConditionBuilder whenTrue​(WorkflowNode... consequent)
        Sets the child nodes to execute when the condition evaluates to true.

        Can be any node or list of nodes. When not a single node of type EWorkflowNodeType.SEQUENCE, the node or nodes are wrapped in a sequence node.

        Parameters:
        consequent - The child nodes to execute.
        Returns:
        This builder for chaining method calls.
      • whenTrue

        default IMultipleConditionBuilder whenTrue​(Iterable<WorkflowNode> consequent)
        Sets the child nodes to execute when the condition evaluates to true.

        Can be any node or list of nodes. When not a single node of type EWorkflowNodeType.SEQUENCE, the node or nodes are wrapped in a sequence node.

        Parameters:
        consequent - The child nodes to execute.
        Returns:
        This builder for chaining method calls.