Class DefaultFreshVarMapper<T>

java.lang.Object
fr.lirmm.graphik.integraal.core.DefaultFreshVarMapper<T>
Type Parameters:
T - the object type whose occurrences are mapped to fresh variables
All Implemented Interfaces:
FreshVarMapper<T>

public class DefaultFreshVarMapper<T> extends Object implements FreshVarMapper<T>
Variable mapper for replacing a variable with another one. Used only by IDCompilation.
Author:
Clément Sipieter (INRIA) <clement@6pi.fr>
  • Constructor Details

    • DefaultFreshVarMapper

      public DefaultFreshVarMapper()
      Creates a mapper using a default fresh-variable generator.
    • DefaultFreshVarMapper

      public DefaultFreshVarMapper(VariableGenerator gen)
      Creates a mapper using the specified fresh-variable generator.
      Parameters:
      gen - the generator used to allocate fresh variables
    • DefaultFreshVarMapper

      public DefaultFreshVarMapper(VariableGenerator gen, List<T> objectsToSubstitute)
      Creates a mapper and eagerly allocates fresh variables for the supplied objects.
      Parameters:
      gen - the generator used to allocate fresh variables
      objectsToSubstitute - the objects to pre-map
  • Method Details

    • getImageOf

      public Variable getImageOf(T object)
      Returns the fresh variable associated with the specified object.
      Specified by:
      getImageOf in interface FreshVarMapper<T>
      Parameters:
      object - the object to map
      Returns:
      the fresh variable image of the object