modified: src/main/java/de/dhbwstuttgart/bytecode/TPHExtractor.java
modified: src/main/java/de/dhbwstuttgart/bytecode/utilities/MethodAndTPH.java
This commit is contained in:
parent
b99c022b50
commit
2ca4aad07d
@ -55,7 +55,10 @@ public class TPHExtractor extends AbstractASTWalker {
|
|||||||
boolean inLocalOrParamOrReturn = false;
|
boolean inLocalOrParamOrReturn = false;
|
||||||
|
|
||||||
public final ArrayList<MethodAndTPH> ListOfMethodsAndTph = new ArrayList<>();
|
public final ArrayList<MethodAndTPH> ListOfMethodsAndTph = new ArrayList<>();
|
||||||
public Set<Pair> oldConstraints = new HashSet<>(); // Alle Constraints in einer Menge (und- & Oder-Constraints)
|
|
||||||
|
// Alle Constraints in einer Menge (und- & Oder-Constraints)
|
||||||
|
public Set<Pair> oldConstraints = new HashSet<>();
|
||||||
|
|
||||||
final ArrayList<ResultPair<TypePlaceholder, TypePlaceholder>> allPairs = new ArrayList<>();
|
final ArrayList<ResultPair<TypePlaceholder, TypePlaceholder>> allPairs = new ArrayList<>();
|
||||||
public final ArrayList<TPHConstraint> allCons = new ArrayList<>();
|
public final ArrayList<TPHConstraint> allCons = new ArrayList<>();
|
||||||
private ResultSet resultSet;
|
private ResultSet resultSet;
|
||||||
@ -214,7 +217,9 @@ public class TPHExtractor extends AbstractASTWalker {
|
|||||||
ret.addOderConstraint(setCons);} );
|
ret.addOderConstraint(setCons);} );
|
||||||
return ret;
|
return ret;
|
||||||
};
|
};
|
||||||
methodAndTph = new MethodAndTPH(id, filterConstrRemainingTVar.apply(method.getConstraints()));
|
ConstraintSet<Pair> filteredConstraints = filterConstrRemainingTVar.apply(method.getConstraints());
|
||||||
|
methodAndTph = new MethodAndTPH(id, filteredConstraints);
|
||||||
|
oldConstraints.addAll(filteredConstraints.getAll());
|
||||||
|
|
||||||
inLocalOrParamOrReturn = true;
|
inLocalOrParamOrReturn = true;
|
||||||
method.getReturnType().accept(this);
|
method.getReturnType().accept(this);
|
||||||
|
@ -5,6 +5,7 @@ import java.util.ArrayList;
|
|||||||
import de.dhbwstuttgart.syntaxtree.type.RefTypeOrTPHOrWildcardOrGeneric;
|
import de.dhbwstuttgart.syntaxtree.type.RefTypeOrTPHOrWildcardOrGeneric;
|
||||||
import de.dhbwstuttgart.syntaxtree.type.TypePlaceholder;
|
import de.dhbwstuttgart.syntaxtree.type.TypePlaceholder;
|
||||||
import de.dhbwstuttgart.typeinference.constraints.ConstraintSet;
|
import de.dhbwstuttgart.typeinference.constraints.ConstraintSet;
|
||||||
|
import de.dhbwstuttgart.typeinference.constraints.Pair;
|
||||||
import de.dhbwstuttgart.typeinference.result.GenericInsertPair;
|
import de.dhbwstuttgart.typeinference.result.GenericInsertPair;
|
||||||
import de.dhbwstuttgart.typeinference.result.ResultPair;
|
import de.dhbwstuttgart.typeinference.result.ResultPair;
|
||||||
|
|
||||||
@ -22,7 +23,7 @@ public class MethodAndTPH {
|
|||||||
*/
|
*/
|
||||||
public final ConstraintSet constraints;
|
public final ConstraintSet constraints;
|
||||||
|
|
||||||
public MethodAndTPH(String name, ConstraintSet constraints) {
|
public MethodAndTPH(String name, ConstraintSet<Pair> constraints) {
|
||||||
this.id = name;
|
this.id = name;
|
||||||
this.constraints = constraints;
|
this.constraints = constraints;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user