Class Switch.SwitchDirector

    • Field Detail

      • m_CaseToken

        protected transient Token m_CaseToken
        the token to use in the switch cases.
    • Constructor Detail

      • SwitchDirector

        public SwitchDirector()
    • Method Detail

      • setControlActor

        public void setControlActor​(AbstractDirectedControlActor value)
        Sets the group to execute.
        value - the group
      • setCaseToken

        public void setCaseToken​(Token value)
        Sets the token to use in the switch cases.
        value - the token to use
      • getCaseToken

        public Token getCaseToken()
        Returns the token to be forwarded to switch cases.
        the token, can be null if not yet set
      • whichCase

        protected int whichCase()
        Determines which case to execute.
        the index of the case to execute
      • execute

        public String execute()
        Executes the group of actors.
        Specified by:
        execute in class AbstractDirector
        null if everything went smooth