new file: src/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java
This commit is contained in:
parent
421169a72d
commit
608d73452a
25
src/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java
Normal file
25
src/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
package de.dhbwstuttgart.typeinference.unify;
|
||||||
|
|
||||||
|
import java.io.FileWriter;
|
||||||
|
import java.util.HashSet;
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
|
import de.dhbwstuttgart.typeinference.unify.interfaces.IFiniteClosure;
|
||||||
|
import de.dhbwstuttgart.typeinference.unify.model.UnifyPair;
|
||||||
|
|
||||||
|
public class TypeUnify2Task extends TypeUnifyTask {
|
||||||
|
|
||||||
|
Set<Set<UnifyPair>> setToFlatten;
|
||||||
|
|
||||||
|
public TypeUnify2Task(Set<Set<UnifyPair>> setToFlatten, Set<UnifyPair> eq, IFiniteClosure fc, boolean parallel, FileWriter logFile, Boolean log) {
|
||||||
|
super(eq, fc, parallel, logFile, log);
|
||||||
|
this.setToFlatten = setToFlatten;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected Set<Set<UnifyPair>> compute() {
|
||||||
|
Set<Set<UnifyPair>> res = unify2(setToFlatten, eq, fc, parallel);
|
||||||
|
if (isUndefinedPairSetSet(res)) { return new HashSet<>(); }
|
||||||
|
else return res;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user