Class DynamicFreezeTest.ProjectFreezeModifier

java.lang.Object
net.ssehub.easy.producer.scenario_tests.DynamicFreezeTest.ProjectFreezeModifier
All Implemented Interfaces:
net.ssehub.easy.varModel.model.rewrite.modifier.IProjectModifier
Enclosing class:
DynamicFreezeTest

private static class DynamicFreezeTest.ProjectFreezeModifier extends Object implements net.ssehub.easy.varModel.model.rewrite.modifier.IProjectModifier
This modifier is used to freeze all relevant declarations inside the CFG projects of Qualimaster.
Author:
El-Sharkawy
  • Field Details

    • CFG_POSTFIX

      private static final String CFG_POSTFIX
      See Also:
    • PROJECT_ADAPTIVITYCFG

      private static final String PROJECT_ADAPTIVITYCFG
      See Also:
    • ANNOTATION_BINDING_TIME

      private static final String ANNOTATION_BINDING_TIME
      See Also:
    • CONST_BINDING_TIME_RUNTIME_MON

      private static final String CONST_BINDING_TIME_RUNTIME_MON
      See Also:
    • RUNTIME_LEVEL

      private static final int RUNTIME_LEVEL
      See Also:
    • BLACKLIST

      private static final Set<String> BLACKLIST
    • declarations

      private List<net.ssehub.easy.varModel.model.DecisionVariableDeclaration> declarations
    • config

      private net.ssehub.easy.varModel.confModel.Configuration config
    • usedProjects

      private Map<String,net.ssehub.easy.varModel.model.Project> usedProjects
  • Constructor Details

    • ProjectFreezeModifier

      private ProjectFreezeModifier()
  • Method Details

    • modifyProject

      public void modifyProject(net.ssehub.easy.varModel.model.Project project, net.ssehub.easy.varModel.model.rewrite.RewriteContext context)
      Specified by:
      modifyProject in interface net.ssehub.easy.varModel.model.rewrite.modifier.IProjectModifier
    • isRuntimeVariable

      private boolean isRuntimeVariable(net.ssehub.easy.varModel.confModel.Configuration config, net.ssehub.easy.varModel.model.DecisionVariableDeclaration declaration)
      Checks whether the given declaration is a runtime variable.
      Parameters:
      config - The configuration where the declaration belongs to.
      declaration - The declaration to test.
      Returns:
      true if the variable is a runtime variable and should not be frozen, false else.
    • getBindingTimeAnnotation

      private net.ssehub.easy.varModel.model.Attribute getBindingTimeAnnotation(net.ssehub.easy.varModel.model.Project project)
      Returns the binding time annotation of the project to create the selector statement of the freeze block.
      Parameters:
      project - The project for which the freeze block shall be created.
      Returns:
      The binding time annotation or null it could not be found.