Class ScopeAssignments


  • public class ScopeAssignments
    extends java.lang.Object
    Class contains variables that were assigned in a specific scope..
    Author:
    Sizonenko
    • Constructor Detail

      • ScopeAssignments

        public ScopeAssignments()
        Sole constructor.
    • Method Detail

      • wasAssignedInThisScope

        public boolean wasAssignedInThisScope​(IDecisionVariable variable)
        Method for determining if variable was assigned in the specific scope. Call setCurrentScope(IModelElement) before.
        Parameters:
        variable - Variable under question.
        Returns:
        True if variable already was assigned in this scope.
      • clear

        public void clear()
        Clears all assignments.
      • clearScopeAssignments

        public void clearScopeAssignments​(Project scope)
        Clears all scope assignments for scope.
        Parameters:
        scope - the scope to clear
      • setCurrentScope

        public void setCurrentScope​(Constraint constraint)
        Defines the current scope due to the parents of the given constraint.
        Parameters:
        constraint - defining the current scope
      • setCurrentScope

        public void setCurrentScope​(IModelElement currentScope)
        Defines the current scope.
        Parameters:
        currentScope - the current scope