Class DataflowWithRatesActorInterpreter

    • Constructor Detail

      • DataflowWithRatesActorInterpreter

        public DataflowWithRatesActorInterpreter​(caltrop.interpreter.ast.Actor actor,
                                                 caltrop.interpreter.Context context,
                                                 caltrop.interpreter.environment.Environment actorEnv,
                                                 java.util.Map inputPortMap,
                                                 java.util.Map outputPortMap)
        Defines a new actor interpreter for the specified actor.
        Parameters:
        actor - The actor.
        context - The interpretation context.
        actorEnv - The global environment.
        inputPortMap - Map from input port names to channels.
        outputPortMap - Map from output port names to channels.
        See Also:
        InputChannel, OutputChannel
    • Method Detail

      • actionEvaluatePrecondition

        public boolean actionEvaluatePrecondition()
        Evaluate the preconditions for the action and return its result. If this method returns false, some condition required for the successful completion of the action is not satisfied.
        Overrides:
        actionEvaluatePrecondition in class DataflowActorInterpreter
        Returns:
        True, if the action precondition was satisfied.
        Throws:
        caltrop.interpreter.InterpreterException - If the evaluation of the guards could not be successfully completed.
      • actionStep

        public void actionStep()
        Execute the action body, potentially changing the value of actor state variables and action-scope variables.
        Overrides:
        actionStep in class DataflowActorInterpreter
        Throws:
        caltrop.interpreter.InterpreterException - If the action body could not be executed successfully.