Class TransientEffectExecutionResult

java.lang.Object
org.palladiosimulator.simulizar.action.interpreter.TransientEffectExecutionResult

public final class TransientEffectExecutionResult extends Object
Class to represent the result of the execution of transient effects, i.e., AdaptationBehaviors. Instances of this class are created by the TransientEffectInterpreter in the course of its TransientEffectInterpreter.caseAdaptationBehavior(AdaptationBehavior) method. Note that in case of an asynchronous execution of the behavior, the meaningfulness is limited since the execution is only triggered. Hence, in such a case the corresponding result only contains information on this.
  • Method Details

    • getExecutionResult

      public EventResult getExecutionResult()
      Gets the execution result.
      Returns:
      The result of the execution of the behavior, in terms of a EventResult constant.
      If this instance is associated with an asynchronous behavior execution, SUCCESSFUL is returned in any case.
    • getContext

      public Optional<ExecutionContext> getContext()
      Gets the execution context that was used to execute the behavior. This is mainly of interest in case of an asynchronous execution.
      Returns:
      The ExecutionContext that was used to execute the behavior.
    • getExecutionResultAsBoolean

      public boolean getExecutionResultAsBoolean()
      Gets the execution result in terms of a boolean flag. This is only meaningful in case of a synchronous behavior execution.
      Returns:
      true in case of success, else false.