Class SwitchBuilder

  • All Implemented Interfaces:
    NodeBuilder


    public abstract class SwitchBuilder
    extends java.lang.Object
    implements NodeBuilder

    Create a switch node in the current Flow.

    Since:
    2.2
    • Constructor Detail

      • SwitchBuilder

        public SwitchBuilder​()
    • Method Detail

      • switchCase

        public abstract SwitchCaseBuilder switchCase​()

        Create a switch case in the current switch.

        Returns:
        the builder instance
        Since:
        2.2
      • defaultOutcome

        public abstract SwitchCaseBuilder defaultOutcome​(java.lang.String outcome)

        Set the default outcome of the current switch.

        Parameters:
        outcome - A ValueExpression String that will be the default outcome of the switch.
        Returns:
        the builder instance
        Throws:
        java.lang.NullPointerException - if any of the parameters are null
        Since:
        2.2
      • defaultOutcome

        public abstract SwitchCaseBuilder defaultOutcome​(ValueExpression outcome)

        Set the default outcome of the current switch.

        Parameters:
        outcome - A ValueExpression that will be the default outcome of the switch.
        Returns:
        the builder instance
        Throws:
        java.lang.NullPointerException - if any of the parameters are null
        Since:
        2.2
      • markAsStartNode

        public abstract SwitchBuilder markAsStartNode​()
        Description copied from interface: NodeBuilder

        Mark this node as the start node in the flow. Any other node that had been marked as the start node will no longer be the start node.

        Specified by:
        markAsStartNode in interface NodeBuilder
        Returns:
        the builder instance