Class SeffVisitor

  • Direct Known Subclasses:
    AggregatedContextSEFFVisitor

    public class SeffVisitor
    extends org.palladiosimulator.pcm.seff.util.SeffSwitch
    Visitor that builds the computed usage and computed allocation contexts.
    • Field Detail

      • contextWrapper

        protected ContextWrapper contextWrapper
        Context wrapper for access to context information.
    • Constructor Detail

      • SeffVisitor

        public SeffVisitor​(ContextWrapper wrapper)
        The constructor.
        Parameters:
        wrapper - reference to the context wrapper
    • Method Detail

      • caseAbstractInternalControlFlowAction

        public Object caseAbstractInternalControlFlowAction​(org.palladiosimulator.pcm.seff.AbstractInternalControlFlowAction action)
        Handles recovery block actions. This is a workaround implementing the case for the base class of the RecoveryBlockAction type, as the type itself is not directly in the SEFF package and thus not handled by the SeffSwitch.
        Overrides:
        caseAbstractInternalControlFlowAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the recovery block action
        Returns:
        the recovery block action
      • caseAcquireAction

        public Object caseAcquireAction​(org.palladiosimulator.pcm.seff.AcquireAction action)
        Handles acquire actions. Nothing to do for the dependency solver. Just goes to the next action.
        Overrides:
        caseAcquireAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the acquire action
        Returns:
        the acquire action
      • caseBranchAction

        public Object caseBranchAction​(org.palladiosimulator.pcm.seff.BranchAction action)
        Handles branch actions. Proceeds with the inner branch transitions, then goes to the next action.
        Overrides:
        caseBranchAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the branch action
        Returns:
        the branch action
      • caseCollectionIteratorAction

        public Object caseCollectionIteratorAction​(org.palladiosimulator.pcm.seff.CollectionIteratorAction action)
        Handles collection iterator actions. Invokes the collectionIteratorHandler, then goes to the next action.
        Overrides:
        caseCollectionIteratorAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the collection iterator action
        Returns:
        the collection iterator action
      • caseExternalCallAction

        public Object caseExternalCallAction​(org.palladiosimulator.pcm.seff.ExternalCallAction action)
        Handles external call actions. Invokes the externalCallHandler, then goes to the next action.
        Overrides:
        caseExternalCallAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the external call action
        Returns:
        the external call action
      • caseForkAction

        public Object caseForkAction​(org.palladiosimulator.pcm.seff.ForkAction action)
        Handles fork actions. Invokes the forkActionHandler, then goes to the next action.
        Overrides:
        caseForkAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the fork action
        Returns:
        the fork action
      • caseGuardedBranchTransition

        public Object caseGuardedBranchTransition​(org.palladiosimulator.pcm.seff.GuardedBranchTransition transition)
        Handles guarded branch transitions. Invokes the guardedBranchHandler.
        Overrides:
        caseGuardedBranchTransition in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        transition - the branch transition
        Returns:
        the branch transition
      • caseInternalAction

        public Object caseInternalAction​(org.palladiosimulator.pcm.seff.InternalAction action)
        Handles internal actions. Invokes the internalActionHandler, then goes to the next action.
        Overrides:
        caseInternalAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the internal action
        Returns:
        the internal action
      • caseLoopAction

        public Object caseLoopAction​(org.palladiosimulator.pcm.seff.LoopAction action)
        Handles loop actions. Invokes the loopActionHandler, then goes to the next action.
        Overrides:
        caseLoopAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the loop action
        Returns:
        the loop action
      • caseProbabilisticBranchTransition

        public Object caseProbabilisticBranchTransition​(org.palladiosimulator.pcm.seff.ProbabilisticBranchTransition transition)
        Handles probabilistic branch transitions. Invokes the probabilisticBranchHandler, then goes to the next action.
        Overrides:
        caseProbabilisticBranchTransition in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        transition - the branch transition
        Returns:
        the branch transition
      • caseReleaseAction

        public Object caseReleaseAction​(org.palladiosimulator.pcm.seff.ReleaseAction action)
        Handles release actions. Nothing to do for the dependency solver. Just goes to the next action.
        Overrides:
        caseReleaseAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the release action
        Returns:
        the release action
      • caseResourceDemandingBehaviour

        public Object caseResourceDemandingBehaviour​(org.palladiosimulator.pcm.seff.ResourceDemandingBehaviour behaviour)
        Handles resource demanding behaviours. Goes to the first action within the behaviour.
        Overrides:
        caseResourceDemandingBehaviour in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        behaviour - the resource demanding behaviour
        Returns:
        the resource demanding behaviour
      • caseResourceDemandingSEFF

        public Object caseResourceDemandingSEFF​(org.palladiosimulator.pcm.seff.ResourceDemandingSEFF behaviour)
        Handles resource demanding seffs. Goes to the first action within the seff.
        Overrides:
        caseResourceDemandingSEFF in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        behaviour - the resource demanding seff
        Returns:
        the resource demanding seff
      • caseSetVariableAction

        public Object caseSetVariableAction​(org.palladiosimulator.pcm.seff.SetVariableAction action)
        Handles set variable actions. Invokes the setVariableHandler, then goes to the next action.
        Overrides:
        caseSetVariableAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the set variable action
        Returns:
        the set variable action
      • caseStartAction

        public Object caseStartAction​(org.palladiosimulator.pcm.seff.StartAction action)
        Handles start actions. Nothing to do for the dependency solver. Just goes to the next action.
        Overrides:
        caseStartAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the start action
        Returns:
        the start action
      • caseStopAction

        public Object caseStopAction​(org.palladiosimulator.pcm.seff.StopAction action)
        Handles stop actions. Saves the contexts that have been created for the surrounding resource demanding seff.
        Overrides:
        caseStopAction in class org.palladiosimulator.pcm.seff.util.SeffSwitch
        Parameters:
        action - the stop action
        Returns:
        the stop action
      • getContextWrapper

        public ContextWrapper getContextWrapper()
        Retrieves the context wrapper.
        Returns:
        the context wrapper
      • setContextWrapper

        public void setContextWrapper​(ContextWrapper wrapper)
        Sets the context wrapper.
        Parameters:
        wrapper - the context wrapper