Class Context

java.lang.Object
liquidjava.processor.context.Context

public class Context extends Object
  • Field Details

    • counter

      public int counter
  • Method Details

    • getInstance

      public static Context getInstance()
    • reinitializeContext

      public void reinitializeContext()
    • reinitializeAllContext

      public void reinitializeAllContext()
    • enterContext

      public void enterContext()
    • exitContext

      public void exitContext()
    • getCounter

      public int getCounter()
    • getContext

      public Map<String, spoon.reflect.reference.CtTypeReference<?>> getContext()
    • addGlobalVariableToContext

      public void addGlobalVariableToContext(String simpleName, String location, spoon.reflect.reference.CtTypeReference<?> type, Predicate c)
    • addVarToContext

      public void addVarToContext(RefinedVariable var)
    • addVarToContext

      public RefinedVariable addVarToContext(String simpleName, spoon.reflect.reference.CtTypeReference<?> type, Predicate c, spoon.reflect.declaration.CtElement placementInCode)
    • addInstanceToContext

      public RefinedVariable addInstanceToContext(String simpleName, spoon.reflect.reference.CtTypeReference<?> type, Predicate c, spoon.reflect.declaration.CtElement placementInCode)
    • addRefinementToVariableInContext

      public void addRefinementToVariableInContext(String name, spoon.reflect.reference.CtTypeReference<?> type, Predicate et, spoon.reflect.declaration.CtElement placementInCode)
    • newRefinementToVariableInContext

      public void newRefinementToVariableInContext(String variableName, Predicate expectedType)
      The variable with name variableName will have a new refinement
      Parameters:
      variableName -
      expectedType -
    • getVariableRefinements

      public Predicate getVariableRefinements(String varName)
    • getVariableByName

      public RefinedVariable getVariableByName(String name)
    • hasVariable

      public boolean hasVariable(String name)
    • getAllVariables

      public List<RefinedVariable> getAllVariables()
      Lists all variables inside the stack
      Returns:
      list of all variables
    • getAllVariablesWithSupertypes

      public List<RefinedVariable> getAllVariablesWithSupertypes()
    • addRefinementInstanceToVariable

      public void addRefinementInstanceToVariable(String name, String instanceName)
    • getLastVariableInstance

      public Optional<VariableInstance> getLastVariableInstance(String name)
    • addSpecificVariable

      public void addSpecificVariable(RefinedVariable vi)
    • variablesSetBeforeIf

      public void variablesSetBeforeIf()
    • variablesSetThenIf

      public void variablesSetThenIf()
    • variablesSetElseIf

      public void variablesSetElseIf()
    • variablesNewIfCombination

      public void variablesNewIfCombination()
    • variablesFinishIfCombination

      public void variablesFinishIfCombination()
    • variablesCombineFromIf

      public void variablesCombineFromIf(Predicate cond)
    • addFunctionToContext

      public void addFunctionToContext(RefinedFunction f)
    • getFunction

      public RefinedFunction getFunction(String name, String target, int size)
    • getAllMethodsWithNameSize

      public List<RefinedFunction> getAllMethodsWithNameSize(String name, int size)
    • addGhostFunction

      public void addGhostFunction(GhostFunction gh)
    • getGhosts

      public List<GhostFunction> getGhosts()
    • addGhostClass

      public void addGhostClass(String klass)
    • addToGhostClass

      public void addToGhostClass(String klass, GhostState gs)
    • getGhostState

      public List<GhostState> getGhostState(String s)
    • getGhostState

      public List<GhostState> getGhostState()
    • addAlias

      public void addAlias(AliasWrapper aw)
    • getAlias

      public List<AliasWrapper> getAlias()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getVariableFromInstance

      public Variable getVariableFromInstance(VariableInstance vi)