Class UnmodifiableActivationLifeCycle

  • Direct Known Subclasses:
    DefaultActivationLifeCycle

    public class UnmodifiableActivationLifeCycle
    extends ActivationLifeCycle
    This class represents life-cycles that cannot be modified. Attempts to add new transitions will result in UnsupportedOperationException.
    • Constructor Detail

      • UnmodifiableActivationLifeCycle

        protected UnmodifiableActivationLifeCycle​(ActivationState inactiveState)
        Parameters:
        inactiveState -
    • Method Detail

      • addStateTransition

        public boolean addStateTransition​(ActivationState from,
                                          EventType event,
                                          ActivationState to)
        Description copied from class: ActivationLifeCycle
        Extends the life cycle with a new transition that is created from the given state, labeled with the given event and leading to the given state. If the (from,event) transition already exists in the life-cycle, it is overwritten with the given to state.
        Overrides:
        addStateTransition in class ActivationLifeCycle
        Parameters:
        from - the source state of the transition
        event - the event causing the transition
        to - the target state of the transition
        Returns:
        true, if the life-cycle changed
      • internalAddStateTransition

        protected boolean internalAddStateTransition​(ActivationState activationState,
                                                     EventType eventType,
                                                     ActivationState activationState2)
        Internal method to add transitions to an unmodifiable life-cycle.
        Parameters:
        activationState -
        eventType -
        activationState2 -
        Returns: