forked from JavaTX/JavaCompilerCore
regeln erstellt bis auf reduce2
This commit is contained in:
parent
b082b603de
commit
ed512e9e8b
761
.idea/workspace.xml
generated
761
.idea/workspace.xml
generated
@ -3,8 +3,12 @@
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="5cf612a7-261d-49e6-bf7a-db4b05e41151" name="Default" comment="">
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TI.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TI.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TypeExpr.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TypeExpr.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/MappingAltNeu.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/MappingAltNeu.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarAbstract.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarAbstract.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarType.java" afterPath="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarType.java" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java" afterPath="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java" />
|
||||
</list>
|
||||
<ignored path="$PROJECT_DIR$/bin/" />
|
||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||
@ -20,11 +24,21 @@
|
||||
<component name="ExecutionTargetManager" SELECTED_TARGET="default_target" />
|
||||
<component name="FileEditorManager">
|
||||
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
|
||||
<file leaf-file-name="TypeExpr.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TypeExpr.java">
|
||||
<file leaf-file-name="SolveTest.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/SolveTest.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="151">
|
||||
<caret line="159" column="53" lean-forward="false" selection-start-line="159" selection-start-column="53" selection-end-line="159" selection-end-column="53" />
|
||||
<state relative-caret-position="-165">
|
||||
<caret line="7" column="22" lean-forward="true" selection-start-line="7" selection-start-column="22" selection-end-line="7" selection-end-column="22" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="SolveTest_Dev.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/SolveTest_Dev.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="336">
|
||||
<caret line="294" column="44" lean-forward="false" selection-start-line="294" selection-start-column="44" selection-end-line="294" selection-end-column="44" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
@ -32,103 +46,101 @@
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="ChangeTypeVars.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/assumptions/ChangeTypeVars.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="41">
|
||||
<caret line="29" column="16" lean-forward="false" selection-start-line="29" selection-start-column="16" selection-end-line="29" selection-end-column="16" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="MappingAltNeu.java" pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/MappingAltNeu.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-30">
|
||||
<caret line="27" column="5" lean-forward="true" selection-start-line="27" selection-start-column="5" selection-end-line="27" selection-end-column="5" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="NewOperatorTest3.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest3.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="150">
|
||||
<caret line="22" column="13" lean-forward="false" selection-start-line="22" selection-start-column="13" selection-end-line="22" selection-end-column="13" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="NewOperatorTest2.jav" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.jav">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="NewOperatorTest2.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="223">
|
||||
<caret line="46" column="0" lean-forward="true" selection-start-line="46" selection-start-column="0" selection-end-line="46" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="NewOperatorTest3.jav" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest3.jav">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="165">
|
||||
<caret line="11" column="1" lean-forward="true" selection-start-line="11" selection-start-column="1" selection-end-line="11" selection-end-column="1" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="Rules.java" pinned="false" current-in-tab="false">
|
||||
<file leaf-file-name="Rules.java" pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="274">
|
||||
<caret line="76" column="0" lean-forward="false" selection-start-line="76" selection-start-column="0" selection-end-line="76" selection-end-column="0" />
|
||||
<state relative-caret-position="319">
|
||||
<caret line="371" column="0" lean-forward="true" selection-start-line="371" selection-start-column="0" selection-end-line="371" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="e#13279#13280#0" expanded="true" />
|
||||
<element signature="e#13322#13323#0" expanded="true" />
|
||||
<element signature="e#13539#13540#0" expanded="true" />
|
||||
<element signature="e#13575#13576#0" expanded="true" />
|
||||
<element signature="e#13655#13656#0" expanded="true" />
|
||||
<element signature="e#13705#13706#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="ConstraintSubstitution.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubstitution.java">
|
||||
<file leaf-file-name="TypeVarType.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="62" lean-forward="false" selection-start-line="7" selection-start-column="62" selection-end-line="7" selection-end-column="62" />
|
||||
<state relative-caret-position="319">
|
||||
<caret line="46" column="5" lean-forward="false" selection-start-line="46" selection-start-column="5" selection-end-line="46" selection-end-column="5" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="ConstraintSubType.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="334">
|
||||
<caret line="32" column="0" lean-forward="false" selection-start-line="32" selection-start-column="0" selection-end-line="32" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#452#453#0" expanded="true" />
|
||||
<element signature="e#477#478#0" expanded="true" />
|
||||
<element signature="e#522#523#0" expanded="true" />
|
||||
<element signature="e#550#551#0" expanded="true" />
|
||||
<element signature="e#588#589#0" expanded="true" />
|
||||
<element signature="e#613#614#0" expanded="true" />
|
||||
<element signature="e#658#659#0" expanded="true" />
|
||||
<element signature="e#686#687#0" expanded="true" />
|
||||
<element signature="e#732#733#0" expanded="true" />
|
||||
<element signature="e#816#817#0" expanded="true" />
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="e#871#872#0" expanded="true" />
|
||||
<element signature="e#901#902#0" expanded="true" />
|
||||
<element signature="e#1071#1072#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="ConstraintInterface.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintInterface.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-551">
|
||||
<caret line="0" column="0" lean-forward="true" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#490#491#0" expanded="true" />
|
||||
<element signature="e#520#521#0" expanded="true" />
|
||||
<element signature="e#575#576#0" expanded="true" />
|
||||
<element signature="e#608#609#0" expanded="true" />
|
||||
<element signature="e#653#654#0" expanded="true" />
|
||||
<element signature="e#685#686#0" expanded="true" />
|
||||
<element signature="e#744#745#0" expanded="true" />
|
||||
<element signature="e#781#782#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="TypeVarInterface.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="323">
|
||||
<caret line="53" column="9" lean-forward="true" selection-start-line="53" selection-start-column="9" selection-end-line="53" selection-end-column="9" />
|
||||
<folding>
|
||||
<element signature="e#1630#1631#0" expanded="true" />
|
||||
<element signature="e#1715#1716#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="TypeVarAbstract.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarAbstract.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="225">
|
||||
<caret line="15" column="0" lean-forward="true" selection-start-line="15" selection-start-column="0" selection-end-line="15" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="TypeVarFactory.java" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="150">
|
||||
<caret line="24" column="87" lean-forward="true" selection-start-line="24" selection-start-column="87" selection-end-line="24" selection-end-column="87" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
</leaf>
|
||||
</component>
|
||||
<component name="FileTemplateManagerImpl">
|
||||
@ -141,8 +153,6 @@
|
||||
</component>
|
||||
<component name="FindInProjectRecents">
|
||||
<findStrings>
|
||||
<find>ConstraintS</find>
|
||||
<find>Constraint</find>
|
||||
<find>methodCa</find>
|
||||
<find>getClass</find>
|
||||
<find>ConstraintM</find>
|
||||
@ -171,6 +181,8 @@
|
||||
<find>r_20</find>
|
||||
<find>20</find>
|
||||
<find>new</find>
|
||||
<find>getNeu</find>
|
||||
<find>adapt</find>
|
||||
</findStrings>
|
||||
</component>
|
||||
<component name="Git.Settings">
|
||||
@ -184,12 +196,6 @@
|
||||
<component name="IdeDocumentHistory">
|
||||
<option name="CHANGED_PATHS">
|
||||
<list>
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/ausgabe/ClassWithTPH2String.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/ausgabe/Class2Code.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintField.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintMethod.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/Class2StringTest.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/ConstructTest.jav" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/factoryForSyntaxtree/FactoryForElementes.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/GenericNames.java" />
|
||||
@ -207,7 +213,6 @@
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/assumptions/AssumptionClass.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.jav" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/OldConstraints.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest3.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest3.jav" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/FieldTest.java" />
|
||||
@ -225,16 +230,23 @@
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/Construct.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubType.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/ConstructInterfaceTemplates.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/assumptions/ChangeTypeVars.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarStore.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TI.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TypeExpr.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintShouldEqual.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubstitution.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/MappingAltNeu.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/SolveTest.jav" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/SolveTest.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TI.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintInterface.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarType.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarAbstract.java" />
|
||||
<option value="$PROJECT_DIR$/test/strucTypes5/SolveTest_Dev.java" />
|
||||
<option value="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
@ -375,6 +387,110 @@
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="src" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="dhbwstuttgart" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="strucTypes5" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="typeVars" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="src" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="dhbwstuttgart" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="strucTypes5" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="solve" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="src" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="dhbwstuttgart" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="strucTypes5" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="interfaceTemplates" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="src" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="dhbwstuttgart" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="strucTypes5" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="constraints" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="JavaCompilerCore" />
|
||||
@ -413,8 +529,8 @@
|
||||
<recent name="de.dhbwstuttgart.strucTypes4" />
|
||||
</key>
|
||||
<key name="CopyClassDialog.RECENTS_KEY">
|
||||
<recent name="de.dhbwstuttgart.strucTypes5.assumptions" />
|
||||
<recent name="strucTypes5" />
|
||||
<recent name="de.dhbwstuttgart.strucTypes5.assumptions" />
|
||||
<recent name="de.dhbwstuttgart.strucTypes5.algo" />
|
||||
<recent name="strucTypes3" />
|
||||
</key>
|
||||
@ -425,7 +541,7 @@
|
||||
<recent name="$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5" />
|
||||
</key>
|
||||
</component>
|
||||
<component name="RunManager" selected="JUnit.NewOperatorTest2.run">
|
||||
<component name="RunManager" selected="JUnit.SolveTest_Dev.run">
|
||||
<configuration default="false" name="NewOperatorTest2.run" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||
<pattern>
|
||||
@ -478,32 +594,6 @@
|
||||
<patterns />
|
||||
<method />
|
||||
</configuration>
|
||||
<configuration default="false" name="FieldTest.run" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||
<pattern>
|
||||
<option name="PATTERN" value="strucTypes5.*" />
|
||||
<option name="ENABLED" value="true" />
|
||||
</pattern>
|
||||
</extension>
|
||||
<module name="JavaCompilerCore" />
|
||||
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||
<option name="ALTERNATIVE_JRE_PATH" />
|
||||
<option name="PACKAGE_NAME" value="strucTypes5" />
|
||||
<option name="MAIN_CLASS_NAME" value="strucTypes5.FieldTest" />
|
||||
<option name="METHOD_NAME" value="run" />
|
||||
<option name="TEST_OBJECT" value="method" />
|
||||
<option name="VM_PARAMETERS" value="-ea" />
|
||||
<option name="PARAMETERS" />
|
||||
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
|
||||
<option name="ENV_VARIABLES" />
|
||||
<option name="PASS_PARENT_ENVS" value="true" />
|
||||
<option name="TEST_SEARCH_SCOPE">
|
||||
<value defaultName="singleModule" />
|
||||
</option>
|
||||
<envs />
|
||||
<patterns />
|
||||
<method />
|
||||
</configuration>
|
||||
<configuration default="false" name="TypeExprTest.run" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||
<pattern>
|
||||
@ -556,6 +646,32 @@
|
||||
<patterns />
|
||||
<method />
|
||||
</configuration>
|
||||
<configuration default="false" name="SolveTest_Dev.run" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||
<pattern>
|
||||
<option name="PATTERN" value="strucTypes5.*" />
|
||||
<option name="ENABLED" value="true" />
|
||||
</pattern>
|
||||
</extension>
|
||||
<module name="JavaCompilerCore" />
|
||||
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||
<option name="ALTERNATIVE_JRE_PATH" />
|
||||
<option name="PACKAGE_NAME" value="strucTypes5" />
|
||||
<option name="MAIN_CLASS_NAME" value="strucTypes5.SolveTest_Dev" />
|
||||
<option name="METHOD_NAME" value="run" />
|
||||
<option name="TEST_OBJECT" value="method" />
|
||||
<option name="VM_PARAMETERS" value="-ea" />
|
||||
<option name="PARAMETERS" />
|
||||
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
|
||||
<option name="ENV_VARIABLES" />
|
||||
<option name="PASS_PARENT_ENVS" value="true" />
|
||||
<option name="TEST_SEARCH_SCOPE">
|
||||
<value defaultName="singleModule" />
|
||||
</option>
|
||||
<envs />
|
||||
<patterns />
|
||||
<method />
|
||||
</configuration>
|
||||
<configuration default="true" type="#org.jetbrains.idea.devkit.run.PluginConfigurationType" factoryName="Plugin">
|
||||
<module name="" />
|
||||
<option name="VM_PARAMETERS" value="-Xmx512m -Xms256m -XX:MaxPermSize=250m -ea" />
|
||||
@ -939,17 +1055,17 @@
|
||||
<list size="5">
|
||||
<item index="0" class="java.lang.String" itemvalue="JUnit.NewOperatorTest2.run" />
|
||||
<item index="1" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3.run" />
|
||||
<item index="2" class="java.lang.String" itemvalue="JUnit.FieldTest.run" />
|
||||
<item index="3" class="java.lang.String" itemvalue="JUnit.TypeExprTest.run" />
|
||||
<item index="4" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3" />
|
||||
<item index="2" class="java.lang.String" itemvalue="JUnit.TypeExprTest.run" />
|
||||
<item index="3" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3" />
|
||||
<item index="4" class="java.lang.String" itemvalue="JUnit.SolveTest_Dev.run" />
|
||||
</list>
|
||||
<recent_temporary>
|
||||
<list size="5">
|
||||
<item index="0" class="java.lang.String" itemvalue="JUnit.NewOperatorTest2.run" />
|
||||
<item index="1" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3" />
|
||||
<item index="2" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3.run" />
|
||||
<item index="3" class="java.lang.String" itemvalue="JUnit.TypeExprTest.run" />
|
||||
<item index="4" class="java.lang.String" itemvalue="JUnit.FieldTest.run" />
|
||||
<item index="0" class="java.lang.String" itemvalue="JUnit.SolveTest_Dev.run" />
|
||||
<item index="1" class="java.lang.String" itemvalue="JUnit.NewOperatorTest2.run" />
|
||||
<item index="2" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3" />
|
||||
<item index="3" class="java.lang.String" itemvalue="JUnit.NewOperatorTest3.run" />
|
||||
<item index="4" class="java.lang.String" itemvalue="JUnit.TypeExprTest.run" />
|
||||
</list>
|
||||
</recent_temporary>
|
||||
</component>
|
||||
@ -967,44 +1083,44 @@
|
||||
<option name="presentableId" value="Default" />
|
||||
<updated>1492600650522</updated>
|
||||
<workItem from="1492600653626" duration="3746000" />
|
||||
<workItem from="1492623646935" duration="140524000" />
|
||||
<workItem from="1492623646935" duration="164646000" />
|
||||
</task>
|
||||
<servers />
|
||||
</component>
|
||||
<component name="TestHistory">
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 00h 13m 46s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 00h 47m 31s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 00h 32m 01s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 29m 15s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 00h 32m 25s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 33m 30s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 00h 46m 34s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 35m 48s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 00h 49m 22s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 37m 14s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 20h 37m 57s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 54m 42s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest2_run - 2017.05.01 at 21h 00m 25s.xml">
|
||||
<configuration name="NewOperatorTest2.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 58m 40s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest3 - 2017.05.01 at 20h 37m 16s.xml">
|
||||
<configuration name="NewOperatorTest3" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 01h 58m 57s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest3 - 2017.05.01 at 20h 37m 49s.xml">
|
||||
<configuration name="NewOperatorTest3" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 02h 03m 04s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
<history-entry file="NewOperatorTest3_run - 2017.05.01 at 00h 56m 46s.xml">
|
||||
<configuration name="NewOperatorTest3.run" configurationId="JUnit" />
|
||||
<history-entry file="SolveTest_Dev_run - 2017.05.03 at 02h 04m 50s.xml">
|
||||
<configuration name="SolveTest_Dev.run" configurationId="JUnit" />
|
||||
</history-entry>
|
||||
</component>
|
||||
<component name="TimeTrackingManager">
|
||||
<option name="totallyTimeSpent" value="144270000" />
|
||||
<option name="totallyTimeSpent" value="168392000" />
|
||||
</component>
|
||||
<component name="ToolWindowManager">
|
||||
<frame x="-2" y="27" width="1442" height="863" extended-state="0" />
|
||||
@ -1032,7 +1148,7 @@
|
||||
<window_info id="Run" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.35602096" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="11" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
||||
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
||||
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32984293" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Theme Preview" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="true" content_ui="tabs" />
|
||||
@ -1103,7 +1219,7 @@
|
||||
<option name="timeStamp" value="14" />
|
||||
</line-breakpoint>
|
||||
</breakpoints>
|
||||
<option name="time" value="29" />
|
||||
<option name="time" value="34" />
|
||||
</breakpoint-manager>
|
||||
<watches-manager />
|
||||
</component>
|
||||
@ -1112,54 +1228,6 @@
|
||||
<option name="FILTER_TARGETS" value="false" />
|
||||
</component>
|
||||
<component name="editorHistoryManager">
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/constraints/ConstraintSet.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="75">
|
||||
<caret line="10" column="13" lean-forward="false" selection-start-line="10" selection-start-column="13" selection-end-line="10" selection-end-column="13" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/constraints/ConstraintsFactory.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-34">
|
||||
<caret line="14" column="13" lean-forward="false" selection-start-line="14" selection-start-column="13" selection-end-line="14" selection-end-column="13" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/unify/model/WildcardType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-80">
|
||||
<caret line="35" column="40" lean-forward="true" selection-start-line="35" selection-start-column="37" selection-end-line="35" selection-end-column="40" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/unify/model/UnifyPair.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-575">
|
||||
<caret line="28" column="4" lean-forward="false" selection-start-line="28" selection-start-column="4" selection-end-line="28" selection-end-column="4" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/unify/model/UnifyType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-875">
|
||||
<caret line="13" column="22" lean-forward="false" selection-start-line="13" selection-start-column="22" selection-end-line="13" selection-end-column="22" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/unify/model/ExtendsType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="235">
|
||||
<caret line="63" column="23" lean-forward="false" selection-start-line="63" selection-start-column="23" selection-end-line="63" selection-end-column="23" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/typeinference/unify/Unifikationsalgorithmus.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="60">
|
||||
@ -1352,24 +1420,6 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/InterfaceForConstraint.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="150">
|
||||
<caret line="10" column="24" lean-forward="true" selection-start-line="10" selection-start-column="24" selection-end-line="10" selection-end-column="24" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarAbstract.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="75">
|
||||
<caret line="5" column="22" lean-forward="false" selection-start-line="5" selection-start-column="22" selection-end-line="5" selection-end-column="22" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVar.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="255">
|
||||
@ -1412,50 +1462,6 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="288">
|
||||
<caret line="39" column="41" lean-forward="false" selection-start-line="39" selection-start-column="41" selection-end-line="39" selection-end-column="41" />
|
||||
<folding>
|
||||
<element signature="e#1123#1124#0" expanded="true" />
|
||||
<element signature="e#1208#1209#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarRefType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="145">
|
||||
<caret line="11" column="11" lean-forward="false" selection-start-line="11" selection-start-column="11" selection-end-line="11" selection-end-column="11" />
|
||||
<folding>
|
||||
<element signature="e#271#272#0" expanded="true" />
|
||||
<element signature="e#309#310#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="320">
|
||||
<caret line="31" column="24" lean-forward="false" selection-start-line="31" selection-start-column="24" selection-end-line="31" selection-end-column="24" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="false" />
|
||||
<element signature="e#564#565#0" expanded="false" />
|
||||
<element signature="e#612#613#0" expanded="false" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TI.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="227">
|
||||
<caret line="25" column="13" lean-forward="false" selection-start-line="25" selection-start-column="13" selection-end-line="25" selection-end-column="13" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarStore.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="222">
|
||||
@ -1484,35 +1490,6 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubstitution.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="62" lean-forward="false" selection-start-line="7" selection-start-column="62" selection-end-line="7" selection-end-column="62" />
|
||||
<folding>
|
||||
<element signature="e#452#453#0" expanded="true" />
|
||||
<element signature="e#477#478#0" expanded="true" />
|
||||
<element signature="e#522#523#0" expanded="true" />
|
||||
<element signature="e#550#551#0" expanded="true" />
|
||||
<element signature="e#588#589#0" expanded="true" />
|
||||
<element signature="e#613#614#0" expanded="true" />
|
||||
<element signature="e#658#659#0" expanded="true" />
|
||||
<element signature="e#686#687#0" expanded="true" />
|
||||
<element signature="e#732#733#0" expanded="true" />
|
||||
<element signature="e#816#817#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="274">
|
||||
<caret line="76" column="0" lean-forward="false" selection-start-line="76" selection-start-column="0" selection-end-line="76" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest3.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="150">
|
||||
@ -1537,14 +1514,6 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="223">
|
||||
<caret line="46" column="0" lean-forward="true" selection-start-line="46" selection-start-column="0" selection-end-line="46" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TypeExpr.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="151">
|
||||
@ -1555,36 +1524,188 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="154">
|
||||
<caret line="18" column="11" lean-forward="false" selection-start-line="18" selection-start-column="11" selection-end-line="18" selection-end-column="11" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/assumptions/ChangeTypeVars.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="41">
|
||||
<caret line="29" column="16" lean-forward="false" selection-start-line="29" selection-start-column="16" selection-end-line="29" selection-end-column="16" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="imports" expanded="false" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/MappingAltNeu.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-30">
|
||||
<caret line="27" column="5" lean-forward="true" selection-start-line="27" selection-start-column="5" selection-end-line="27" selection-end-column="5" />
|
||||
<state relative-caret-position="270">
|
||||
<caret line="47" column="0" lean-forward="true" selection-start-line="47" selection-start-column="0" selection-end-line="47" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="false" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/NewOperatorTest2.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="268">
|
||||
<caret line="61" column="0" lean-forward="false" selection-start-line="61" selection-start-column="0" selection-end-line="61" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/SolveTest.jav">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="15">
|
||||
<caret line="1" column="0" lean-forward="false" selection-start-line="1" selection-start-column="0" selection-end-line="1" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/algo/TI.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="904">
|
||||
<caret line="115" column="33" lean-forward="false" selection-start-line="115" selection-start-column="33" selection-end-line="115" selection-end-column="33" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/syntaxtree/type/RefType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-600">
|
||||
<caret line="9" column="13" lean-forward="false" selection-start-line="9" selection-start-column="13" selection-end-line="9" selection-end-column="13" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubstitution.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="13" lean-forward="false" selection-start-line="7" selection-start-column="13" selection-end-line="7" selection-end-column="13" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/InterfaceForConstraint.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="109">
|
||||
<caret line="10" column="13" lean-forward="false" selection-start-line="10" selection-start-column="13" selection-end-line="10" selection-end-column="13" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarRefType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-4">
|
||||
<caret line="9" column="17" lean-forward="false" selection-start-line="9" selection-start-column="17" selection-end-line="9" selection-end-column="17" />
|
||||
<folding>
|
||||
<element signature="e#344#345#0" expanded="true" />
|
||||
<element signature="e#374#375#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarAbstract.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="225">
|
||||
<caret line="15" column="0" lean-forward="true" selection-start-line="15" selection-start-column="0" selection-end-line="15" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarInterface.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="323">
|
||||
<caret line="53" column="9" lean-forward="true" selection-start-line="53" selection-start-column="9" selection-end-line="53" selection-end-column="9" />
|
||||
<folding>
|
||||
<element signature="e#1630#1631#0" expanded="true" />
|
||||
<element signature="e#1715#1716#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintInterface.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-551">
|
||||
<caret line="0" column="0" lean-forward="true" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#490#491#0" expanded="true" />
|
||||
<element signature="e#520#521#0" expanded="true" />
|
||||
<element signature="e#575#576#0" expanded="true" />
|
||||
<element signature="e#608#609#0" expanded="true" />
|
||||
<element signature="e#653#654#0" expanded="true" />
|
||||
<element signature="e#685#686#0" expanded="true" />
|
||||
<element signature="e#744#745#0" expanded="true" />
|
||||
<element signature="e#781#782#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/constraints/ConstraintSubType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="334">
|
||||
<caret line="32" column="0" lean-forward="false" selection-start-line="32" selection-start-column="0" selection-end-line="32" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="e#871#872#0" expanded="true" />
|
||||
<element signature="e#901#902#0" expanded="true" />
|
||||
<element signature="e#1071#1072#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarType.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="319">
|
||||
<caret line="46" column="5" lean-forward="false" selection-start-line="46" selection-start-column="5" selection-end-line="46" selection-end-column="5" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/SolveTest_Dev.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="336">
|
||||
<caret line="294" column="44" lean-forward="false" selection-start-line="294" selection-start-column="44" selection-end-line="294" selection-end-column="44" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/test/strucTypes5/SolveTest.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-165">
|
||||
<caret line="7" column="22" lean-forward="true" selection-start-line="7" selection-start-column="22" selection-end-line="7" selection-end-column="22" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/typeVars/TypeVarFactory.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="150">
|
||||
<caret line="24" column="87" lean-forward="true" selection-start-line="24" selection-start-column="87" selection-end-line="24" selection-end-column="87" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/src/de/dhbwstuttgart/strucTypes5/solve/Rules.java">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="319">
|
||||
<caret line="371" column="0" lean-forward="true" selection-start-line="371" selection-start-column="0" selection-end-line="371" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="imports" expanded="true" />
|
||||
<element signature="e#13279#13280#0" expanded="true" />
|
||||
<element signature="e#13322#13323#0" expanded="true" />
|
||||
<element signature="e#13539#13540#0" expanded="true" />
|
||||
<element signature="e#13575#13576#0" expanded="true" />
|
||||
<element signature="e#13655#13656#0" expanded="true" />
|
||||
<element signature="e#13705#13706#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</component>
|
||||
<component name="masterDetails">
|
||||
<states>
|
||||
|
@ -8,6 +8,7 @@ import de.dhbwstuttgart.strucTypes5.ausgabe.Class2String;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.ConstraintAbstract;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.ConstraintSubType;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.OldConstraints;
|
||||
import de.dhbwstuttgart.strucTypes5.solve.Rules;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.ResultTuple;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVar;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVarAbstract;
|
||||
@ -111,7 +112,9 @@ public class TI {
|
||||
|
||||
|
||||
|
||||
// Result of Solve ->
|
||||
// Result of Construct Basis für die Unifikation
|
||||
System.out.println("Result of Solve: ");
|
||||
System.out.println(newResultConstraints);
|
||||
|
||||
|
||||
|
||||
|
@ -0,0 +1,60 @@
|
||||
package de.dhbwstuttgart.strucTypes5.constraints;
|
||||
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVarAbstract;
|
||||
|
||||
/**
|
||||
* Created by sebastian on 02.05.17.
|
||||
*/
|
||||
public class ConstraintInterface extends ConstraintAbstract {
|
||||
|
||||
private TypeVarAbstract SubType;
|
||||
private TypeVarAbstract SuperType;
|
||||
|
||||
public ConstraintInterface(TypeVarAbstract subType, TypeVarAbstract superType) {
|
||||
SubType = subType;
|
||||
SuperType = superType;
|
||||
}
|
||||
|
||||
|
||||
public TypeVarAbstract getSubType() {
|
||||
return SubType;
|
||||
}
|
||||
|
||||
public void setSubType(TypeVarAbstract subType) {
|
||||
SubType = subType;
|
||||
}
|
||||
|
||||
public TypeVarAbstract getSuperType() {
|
||||
return SuperType;
|
||||
}
|
||||
|
||||
public void setSuperType(TypeVarAbstract superType) {
|
||||
SuperType = superType;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (!(o instanceof ConstraintInterface)) return false;
|
||||
|
||||
ConstraintInterface that = (ConstraintInterface) o;
|
||||
|
||||
if (getSubType() != null ? !getSubType().equals(that.getSubType()) : that.getSubType() != null) return false;
|
||||
return getSuperType() != null ? getSuperType().equals(that.getSuperType()) : that.getSuperType() == null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
int result = getSubType() != null ? getSubType().hashCode() : 0;
|
||||
result = 31 * result + (getSuperType() != null ? getSuperType().hashCode() : 0);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.format("ConstraintInterface( %s <* %s ) " , getSubType(), getSuperType());
|
||||
}
|
||||
}
|
@ -1,13 +1,16 @@
|
||||
package de.dhbwstuttgart.strucTypes5.solve;
|
||||
|
||||
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.ConstraintAbstract;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.ConstraintShouldEqual;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.ConstraintSubType;
|
||||
import de.dhbwstuttgart.strucTypes5.algo.Type;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.*;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVar;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVarAbstract;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVarInterface;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.TypeVarRefType;
|
||||
import de.dhbwstuttgart.syntaxtree.Generic;
|
||||
import de.dhbwstuttgart.typeinference.constraints.Constraint;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -16,9 +19,25 @@ import java.util.List;
|
||||
public class Rules {
|
||||
|
||||
|
||||
private List<ConstraintInterface> constraintInterfaces = new ArrayList<>();
|
||||
|
||||
|
||||
/*
|
||||
Achtung höchstwahrscheinlich ist \theta auch ein type (eben ein Struktureller ), Dieser muss auch verglichen werden!!!
|
||||
|
||||
- Rules given by Plümicke
|
||||
- reduce (1/2) reduceEqual implemented
|
||||
- adapt1 - implemented
|
||||
- adapt2 -
|
||||
- erase1 - implemented
|
||||
- erase2 - implemented
|
||||
- swap - implemented
|
||||
- subst - implemented
|
||||
- refl - implemented
|
||||
*/
|
||||
|
||||
|
||||
public List<ConstraintSubstitution> substitutions = new ArrayList<>();
|
||||
|
||||
public void erase1(List<ConstraintAbstract> constraints) {
|
||||
for (ConstraintAbstract cs : constraints) {
|
||||
@ -73,8 +92,251 @@ public class Rules {
|
||||
C[T -> Typ vereinigt mit T =* Theta
|
||||
Wenn T eine Typvariable ist und T in C aber nicht in Theta vorkommt
|
||||
*/
|
||||
public void subst(List<ConstraintAbstract> constratins) {
|
||||
public void subst(List<ConstraintAbstract> constraints) {
|
||||
for (ConstraintAbstract cs : constraints) {
|
||||
if (cs instanceof ConstraintShouldEqual) {
|
||||
TypeVarAbstract t1 = ((ConstraintShouldEqual) cs).getT1();
|
||||
TypeVarAbstract t2 = ((ConstraintShouldEqual) cs).getT2();
|
||||
|
||||
if (t1 instanceof TypeVar) {
|
||||
if (t2 instanceof TypeVarRefType || t2 instanceof TypeVarInterface) {
|
||||
ConstraintSubstitution constraintSubstitution = new ConstraintSubstitution(t1 , t2);
|
||||
substitutions.add(constraintSubstitution);
|
||||
// Todo Occors Check
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// ToDo Not implemented
|
||||
public void reduce(List<ConstraintAbstract> constraints) {
|
||||
for (ConstraintAbstract cs : constraints) {
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// Todo wer sagt dass man nicht irgendwo in der mitte anfängt
|
||||
public void reflect(List<ConstraintAbstract> constriants) {
|
||||
for (ConstraintAbstract cs : constriants) {
|
||||
if (cs instanceof ConstraintSubType) {
|
||||
TypeVarAbstract t1 = ((ConstraintSubType) cs).getSubtype();
|
||||
|
||||
if (t1 instanceof TypeVarRefType || t1 instanceof TypeVarInterface ) {
|
||||
// Hier muss geschaut werden ob es einen nächsten gibt
|
||||
List<TypeVar> chain = reflectNext(t1,((ConstraintSubType) cs).getSubtype() , constriants);
|
||||
if (chain != null) {
|
||||
System.out.println("erfolg");
|
||||
System.out.println(chain);
|
||||
}
|
||||
else {
|
||||
System.out.println("kein erfolg");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private List<TypeVar> reflectNext(TypeVarAbstract startValue, TypeVarAbstract lastValue , List<ConstraintAbstract> remainingConstraints) {
|
||||
|
||||
// suche next
|
||||
|
||||
|
||||
for (ConstraintAbstract cs : remainingConstraints) {
|
||||
if (cs instanceof ConstraintSubType) {
|
||||
TypeVarAbstract tProbNext = ((ConstraintSubType) cs).getSubtype();
|
||||
TypeVarAbstract tNextSuper = ((ConstraintSubType) cs).getSuperType();
|
||||
|
||||
if (tProbNext.equals(lastValue)) {
|
||||
|
||||
|
||||
// 1. Supertyp ist der gesuchte Typ
|
||||
if (tNextSuper.equals(startValue)) {
|
||||
List<TypeVar> chain = new ArrayList<>();
|
||||
|
||||
// Füge Type Var in die Kette ein
|
||||
// ToDo Substituion
|
||||
if (tProbNext instanceof TypeVar) {
|
||||
//chain.add((TypeVar) tProbNext);
|
||||
}
|
||||
else {
|
||||
System.err.println(Rules.class.getName() + "LogikFehler");
|
||||
}
|
||||
return chain;
|
||||
}
|
||||
|
||||
//2. Supertyp != der gesuchte Typ aber TypVar
|
||||
else if (tNextSuper instanceof TypeVar) {
|
||||
List<ConstraintAbstract> remainingConstriants2 = new ArrayList<>();
|
||||
remainingConstriants2.addAll(remainingConstraints);
|
||||
remainingConstriants2.remove(cs);
|
||||
List<TypeVar> chain = reflectNext(startValue,tNextSuper, remainingConstriants2);
|
||||
|
||||
if (chain != null) {
|
||||
chain.add((TypeVar) tNextSuper);
|
||||
return chain;
|
||||
}
|
||||
else {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// 3. sonst
|
||||
else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void reduceEqual(List<ConstraintAbstract> constraints) {
|
||||
for (ConstraintAbstract cs : constraints) {
|
||||
if (cs instanceof ConstraintShouldEqual) {
|
||||
ConstraintShouldEqual css = (ConstraintShouldEqual) cs;
|
||||
if (css.getT1() instanceof TypeVarInterface && css.getT2() instanceof TypeVarInterface ) {
|
||||
|
||||
|
||||
TypeVarInterface st1 = (TypeVarInterface) css.getT1();
|
||||
TypeVarInterface st2 = (TypeVarInterface) css.getT2();
|
||||
|
||||
InterfaceForConstraint if1 = st1.getInterfaceForConstraint();
|
||||
InterfaceForConstraint if2 = st2.getInterfaceForConstraint();
|
||||
|
||||
|
||||
// 1. Prüfe Gleichheit des Namens
|
||||
// Todo .... Name ist noch Objekt TypeVar
|
||||
if (if1.getStrucType().toString().equals(if2.getStrucType().toString())) {
|
||||
|
||||
// Prüfe ob die Listen gleich lange sind
|
||||
if (if1.getGenerics().size() == if2.getGenerics().size()) {
|
||||
|
||||
// Erstelle neue Constraints
|
||||
for (int i = 0 ; i < if1.getGenerics().size() ; i++) {
|
||||
TypeVarAbstract tnX = if1.getGenerics().get(i);
|
||||
TypeVarAbstract tnY = if2.getGenerics().get(i);
|
||||
|
||||
// Ergebnis an ConstraintList
|
||||
constraints.add(new ConstraintShouldEqual(tnX,tnY));
|
||||
}
|
||||
// Lösche element
|
||||
constraints.remove(cs);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void adapt1 (List<ConstraintAbstract> constraints) {
|
||||
for (ConstraintAbstract cs : constraints) {
|
||||
if (cs instanceof ConstraintSubType) {
|
||||
ConstraintSubType csub = (ConstraintSubType) cs;
|
||||
ConstraintInterface cinterface = sucheInterface( csub.getSubtype() , csub.getSuperType() );
|
||||
if (cinterface != null) {
|
||||
ConstraintShouldEqual constraintShouldEqual = new ConstraintShouldEqual(cinterface.getSuperType() , csub.getSuperType());
|
||||
constraints.remove(cs);
|
||||
constraints.add(constraintShouldEqual);
|
||||
// Todo Substitution für Types
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private ConstraintInterface sucheInterface( TypeVarAbstract tvSub , TypeVarAbstract tvSuper ) {
|
||||
|
||||
for (ConstraintInterface cs : constraintInterfaces) {
|
||||
if ( cs.getSubType().equalsForUnify(tvSub) && cs.getSuperType().equalsForUnify(tvSuper) ) {
|
||||
return cs;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public void adapt2(List<ConstraintAbstract> constraints) {
|
||||
|
||||
List<ConstraintAbstract> newConstraints = new ArrayList<>();
|
||||
|
||||
for (ConstraintAbstract cs : constraints) {
|
||||
|
||||
// Start
|
||||
if (cs instanceof ConstraintSubType) {
|
||||
ConstraintSubType css = (ConstraintSubType) cs;
|
||||
if (css.getSuperType() instanceof TypeVar) {
|
||||
if (css.getSubtype() instanceof TypeVarInterface || css.getSubtype() instanceof TypeVarRefType) {
|
||||
adapt2Next(((ConstraintSubType) cs).getSubtype(), ((ConstraintSubType) cs).getSuperType() , constraints, newConstraints);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
constraints.addAll(newConstraints);
|
||||
}
|
||||
|
||||
|
||||
public void adapt2Next(TypeVarAbstract start , TypeVarAbstract last , List<ConstraintAbstract> remainingConstraints, List<ConstraintAbstract> newConstraints) {
|
||||
|
||||
for (ConstraintAbstract cs : remainingConstraints) {
|
||||
|
||||
|
||||
|
||||
if (cs instanceof ConstraintSubType) {
|
||||
ConstraintSubType css = (ConstraintSubType) cs;
|
||||
if (css.getSubtype().equals(last)) {
|
||||
|
||||
// Next ist irgendein Interface
|
||||
if (css.getSuperType() instanceof TypeVarInterface) {
|
||||
|
||||
// Next ist gesuchtes Inteface
|
||||
ConstraintInterface constraintInterface = sucheInterface(start, css.getSuperType());
|
||||
if (constraintInterface != null) {
|
||||
System.out.println("adapt2Next : gefunden");
|
||||
System.out.println(constraintInterface);
|
||||
|
||||
|
||||
// Should Equal ermitteln
|
||||
if (constraintInterface.getSuperType() instanceof TypeVarInterface) {
|
||||
TypeVarInterface iFGiven = (TypeVarInterface) constraintInterface.getSuperType();
|
||||
TypeVarInterface iFthis = (TypeVarInterface) css.getSuperType();
|
||||
|
||||
List<TypeVarAbstract> iFGivenGenerics = iFGiven.getInterfaceForConstraint().getGenerics();
|
||||
List<TypeVarAbstract> iFthisGenerics = iFthis.getInterfaceForConstraint().getGenerics();
|
||||
|
||||
if (iFGivenGenerics.size() == iFthisGenerics.size()) {
|
||||
for (int i = 0 ; i < iFGivenGenerics.size() ; i++ ) {
|
||||
newConstraints.add(new ConstraintShouldEqual(iFGivenGenerics.get(i) , iFthisGenerics.get(i)));
|
||||
}
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
else if (css.getSuperType() instanceof TypeVar) {
|
||||
List<ConstraintAbstract> remConst2 = new ArrayList<>();
|
||||
remConst2.addAll(remainingConstraints);
|
||||
remConst2.remove(cs);
|
||||
adapt2Next(start,css.getSuperType() , remConst2 , newConstraints);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -86,4 +348,24 @@ public class Rules {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
// Getter und Setter
|
||||
|
||||
|
||||
public List<ConstraintInterface> getConstraintInterfaces() {
|
||||
return constraintInterfaces;
|
||||
}
|
||||
|
||||
public void setConstraintInterfaces(List<ConstraintInterface> constraintInterfaces) {
|
||||
this.constraintInterfaces = constraintInterfaces;
|
||||
}
|
||||
|
||||
public List<ConstraintSubstitution> getSubstitutions() {
|
||||
return substitutions;
|
||||
}
|
||||
|
||||
public void setSubstitutions(List<ConstraintSubstitution> substitutions) {
|
||||
this.substitutions = substitutions;
|
||||
}
|
||||
}
|
||||
|
@ -5,7 +5,13 @@ package de.dhbwstuttgart.strucTypes5.typeVars;
|
||||
*/
|
||||
public abstract class TypeVarAbstract {
|
||||
|
||||
|
||||
|
||||
public boolean equalsForUnify(TypeVarAbstract tv) {
|
||||
if (tv.equals(this)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -18,11 +18,11 @@ public class TypeVarFactory {
|
||||
return new TypeVar(zaehler.toString());
|
||||
}
|
||||
|
||||
public static TypeVarAbstract makeTypeVar(InterfaceForConstraint ifc) {
|
||||
public static TypeVarInterface makeTypeVar(InterfaceForConstraint ifc) {
|
||||
return new TypeVarInterface(ifc);
|
||||
}
|
||||
|
||||
public static TypeVarAbstract makeTypeVar(RefTypeOrTPHOrWildcardOrGeneric refType) {
|
||||
public static TypeVarRefType makeTypeVar(RefTypeOrTPHOrWildcardOrGeneric refType) {
|
||||
if (refType instanceof RefType) {
|
||||
RefType refType2 = (RefType) refType;
|
||||
return new TypeVarRefType(refType2);
|
||||
|
@ -24,6 +24,9 @@ public class TypeVarInterface extends TypeVarAbstract {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
@ -35,6 +38,29 @@ public class TypeVarInterface extends TypeVarAbstract {
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Equal_for_Unify
|
||||
public boolean equalsForUnify(TypeVarAbstract tv) {
|
||||
|
||||
if (tv instanceof TypeVarInterface) {
|
||||
String name = ((TypeVarInterface) tv).getInterfaceForConstraint().getStrucType().toString();
|
||||
String name2 = getInterfaceForConstraint().getStrucType().toString();
|
||||
if (name.equals(name2)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.format("TVar_%s" , interfaceForConstraint.toString());
|
||||
|
@ -34,6 +34,7 @@ public class TypeVarType extends TypeVarAbstract {
|
||||
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public boolean equals(Object obj) {
|
||||
if (obj.getClass().equals(TypeVarType.class)) {
|
||||
|
@ -60,6 +60,10 @@ public class NewOperatorTest2 {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
} catch (Exception exc) {
|
||||
|
20
test/strucTypes5/SolveTest.jav
Normal file
20
test/strucTypes5/SolveTest.jav
Normal file
@ -0,0 +1,20 @@
|
||||
|
||||
|
||||
|
||||
class Main {
|
||||
main () { return new A().mt( new MyInteger() , new MyInteger() , new MyInteger() ); }
|
||||
}
|
||||
|
||||
|
||||
class A{
|
||||
mt(x,y,z) { return x.sub(y).add(z); }
|
||||
}
|
||||
|
||||
|
||||
class MyInteger {
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
73
test/strucTypes5/SolveTest.java
Normal file
73
test/strucTypes5/SolveTest.java
Normal file
@ -0,0 +1,73 @@
|
||||
package strucTypes5;
|
||||
|
||||
import de.dhbwstuttgart.parser.JavaTXParser;
|
||||
import de.dhbwstuttgart.strucTypes5.algo.TI;
|
||||
import de.dhbwstuttgart.strucTypes5.assumptions.AssumptionMap;
|
||||
import de.dhbwstuttgart.syntaxtree.ClassOrInterface;
|
||||
import de.dhbwstuttgart.syntaxtree.SourceFile;
|
||||
import org.junit.Test;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
import static org.junit.Assert.fail;
|
||||
|
||||
/**
|
||||
* Dieser Test pr�ft nur, ob .java-Dateien fehlerfrei geparst werden. Der
|
||||
* dabei erstellte Syntaxbaum wird nicht kontrolliert.
|
||||
*
|
||||
* @author janulrich
|
||||
*
|
||||
*/
|
||||
public class SolveTest {
|
||||
private static final String rootDirectory = System.getProperty("user.dir") + "/test/strucTypes5/";
|
||||
|
||||
@Test
|
||||
public void run() {
|
||||
|
||||
|
||||
List<String> filenames = new ArrayList<String>();
|
||||
filenames.add("SolveTest.jav");
|
||||
|
||||
JavaTXParser parser = new JavaTXParser();
|
||||
try {
|
||||
for (String filename : filenames) {
|
||||
|
||||
System.out.println("Teste: " + filename);
|
||||
|
||||
SourceFile sf = parser.parse(new File(rootDirectory + filename));
|
||||
|
||||
SourceFile sfdebug = sf;
|
||||
|
||||
ClassOrInterface mainClass = sf.getClasses().get(0);
|
||||
ClassOrInterface aClass = sf.getClasses().get(1);
|
||||
|
||||
|
||||
AssumptionMap assumptionMap = new AssumptionMap();
|
||||
|
||||
TI ti = new TI(assumptionMap, aClass);
|
||||
|
||||
TI ti1 = new TI(ti.assresult, mainClass);
|
||||
|
||||
// Take The Generatet Constraints from ti:
|
||||
// Try To Solve
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
} catch (Exception exc) {
|
||||
exc.printStackTrace();
|
||||
fail();
|
||||
}
|
||||
assertTrue("Tests durchlaufen", filenames.size() > 0);
|
||||
}
|
||||
}
|
331
test/strucTypes5/SolveTest_Dev.java
Normal file
331
test/strucTypes5/SolveTest_Dev.java
Normal file
@ -0,0 +1,331 @@
|
||||
package strucTypes5;
|
||||
|
||||
import de.dhbwstuttgart.parser.NullToken;
|
||||
import de.dhbwstuttgart.strucTypes5.constraints.*;
|
||||
import de.dhbwstuttgart.strucTypes5.solve.Rules;
|
||||
import de.dhbwstuttgart.strucTypes5.typeVars.*;
|
||||
import de.dhbwstuttgart.syntaxtree.type.RefType;
|
||||
import de.dhbwstuttgart.syntaxtree.type.RefTypeOrTPHOrWildcardOrGeneric;
|
||||
import de.dhbwstuttgart.typecheck.JavaClassName;
|
||||
import de.dhbwstuttgart.typeinference.constraints.Constraint;
|
||||
import org.junit.Test;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
import static org.junit.Assert.fail;
|
||||
|
||||
/**
|
||||
For Develop the solve Funktion
|
||||
*/
|
||||
public class SolveTest_Dev {
|
||||
private static final String rootDirectory = System.getProperty("user.dir") + "/test/strucTypes5/";
|
||||
|
||||
|
||||
RefType myInteger;
|
||||
|
||||
@Test
|
||||
public void run() {
|
||||
|
||||
// Initialisiere den gleichen RefType
|
||||
List<RefTypeOrTPHOrWildcardOrGeneric> list = new ArrayList<>();
|
||||
myInteger = new RefType(new JavaClassName("MyInteger"),list, new NullToken());
|
||||
|
||||
|
||||
TypeVarRefType typeVarRefType1 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
TypeVarRefType typeVarRefType2 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
|
||||
System.out.println(typeVarRefType1.equals(typeVarRefType2));
|
||||
|
||||
|
||||
|
||||
|
||||
System.out.println("Starte Test der Regeln");
|
||||
|
||||
/*
|
||||
Wie soll das Funktionieren
|
||||
- klein sigma ist der Unifikator
|
||||
- Rules ist solange anzuwenden bis alles unifiziert oder oder keine Regel mehr angewendet werden kann.
|
||||
-
|
||||
*/
|
||||
|
||||
// Erstellen Beispiel:
|
||||
|
||||
|
||||
testSwap();
|
||||
|
||||
testErase1();
|
||||
|
||||
testErase2();
|
||||
|
||||
testSubstition();
|
||||
|
||||
reflectTest();
|
||||
|
||||
reduceEqualTest();
|
||||
|
||||
adapt1Test();
|
||||
|
||||
adapt2Test();
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
public void testSwap() {
|
||||
|
||||
System.out.println("Teste Swap");
|
||||
TypeVarRefType typeVarRefType = TypeVarFactory.makeTypeVar(myInteger);
|
||||
TypeVar typeVar = TypeVarFactory.makeTypeVar();
|
||||
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
ConstraintShouldEqual cs = new ConstraintShouldEqual(typeVarRefType,typeVar);
|
||||
|
||||
constraints.add(cs);
|
||||
|
||||
System.out.println(constraints);
|
||||
Rules rules = new Rules();
|
||||
rules.swap(constraints);
|
||||
System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
// Subtype Relation
|
||||
public void testErase1() {
|
||||
System.out.println("Test Erase 1 ");
|
||||
TypeVarRefType typeVarRefType1 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
TypeVarRefType typeVarRefType2 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
ConstraintSubType constraintSubType = new ConstraintSubType(typeVarRefType1,typeVarRefType2);
|
||||
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
constraints.add(constraintSubType);
|
||||
System.out.println(constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.erase1(constraints);
|
||||
|
||||
System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
// Erase SchouldEqual
|
||||
public void testErase2() {
|
||||
System.out.println("Test Erase 2 ");
|
||||
TypeVarRefType typeVarRefType1 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
TypeVarRefType typeVarRefType2 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
ConstraintShouldEqual constraintShouldEqual = new ConstraintShouldEqual(typeVarRefType1,typeVarRefType2);
|
||||
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
constraints.add(constraintShouldEqual);
|
||||
System.out.println(constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.erase2(constraints);
|
||||
|
||||
System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
public void testSubstition() {
|
||||
System.out.println("Test Substitions ");
|
||||
TypeVar typeVar = TypeVarFactory.makeTypeVar();
|
||||
TypeVarRefType typeVarRefType = TypeVarFactory.makeTypeVar(myInteger);
|
||||
ConstraintShouldEqual constraintShouldEqual = new ConstraintShouldEqual(typeVar,typeVarRefType);
|
||||
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
constraints.add(constraintShouldEqual);
|
||||
System.out.println(constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.subst(constraints);
|
||||
System.out.println(rules.substitutions);
|
||||
|
||||
System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
public void reflectTest() {
|
||||
System.out.println("Reflect Test");
|
||||
TypeVarRefType t1 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
TypeVar t2 = TypeVarFactory.makeTypeVar();
|
||||
TypeVar t3 = TypeVarFactory.makeTypeVar();
|
||||
TypeVarRefType t4 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
|
||||
ConstraintSubType csub1 = new ConstraintSubType(t1,t2);
|
||||
ConstraintSubType csub2 = new ConstraintSubType(t2,t3);
|
||||
ConstraintSubType csub3 = new ConstraintSubType(t3,t4);
|
||||
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
//constraints.add(csub2);
|
||||
constraints.add(csub1);
|
||||
constraints.add(csub3);
|
||||
|
||||
System.out.println(constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.reflect(constraints);
|
||||
|
||||
System.out.println(constraints);
|
||||
System.out.println(rules.substitutions);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public void reduceEqualTest() {
|
||||
System.out.println("ReduceEqualTest");
|
||||
|
||||
// Gemeinsamer SrucType
|
||||
TypeVar t1 = TypeVarFactory.makeTypeVar();
|
||||
|
||||
// Erstelle Interface 1
|
||||
List<TypeVarAbstract> genericsA = new ArrayList<>();
|
||||
TypeVar t2 = TypeVarFactory.makeTypeVar();
|
||||
TypeVar t3 = TypeVarFactory.makeTypeVar();
|
||||
genericsA.add(t3);
|
||||
genericsA.add(t2);
|
||||
InterfaceForConstraint if1 = new InterfaceForConstraint(t1,genericsA);
|
||||
|
||||
|
||||
// Erstelle Interface 2
|
||||
List<TypeVarAbstract> genericsB = new ArrayList<>();
|
||||
TypeVarRefType refType1 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
TypeVarRefType refType2 = TypeVarFactory.makeTypeVar(myInteger);
|
||||
genericsB.add(refType1);
|
||||
genericsB.add(refType2);
|
||||
InterfaceForConstraint if2 = new InterfaceForConstraint(t1,genericsB);
|
||||
|
||||
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
|
||||
constraints.add(new ConstraintShouldEqual(TypeVarFactory.makeTypeVar(if2) , TypeVarFactory.makeTypeVar(if1)));
|
||||
System.out.println(constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.reduceEqual(constraints);
|
||||
System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void adapt1Test() {
|
||||
System.out.println("Adapt1 Test");
|
||||
|
||||
// gemeinsamer Typ
|
||||
TypeVarAbstract t1 = TypeVarFactory.makeTypeVar();
|
||||
|
||||
// implements Interface myInteger implements Interface
|
||||
List<TypeVarAbstract> generics = new ArrayList<>();
|
||||
generics.add(TypeVarFactory.makeTypeVar(myInteger));
|
||||
generics.add(TypeVarFactory.makeTypeVar(myInteger));
|
||||
InterfaceForConstraint if1 = new InterfaceForConstraint(t1, generics);
|
||||
ConstraintInterface constraintInterface = new ConstraintInterface(TypeVarFactory.makeTypeVar(myInteger) , TypeVarFactory.makeTypeVar(if1) );
|
||||
List<ConstraintInterface> interfaces = new ArrayList<>();
|
||||
interfaces.add(constraintInterface);
|
||||
|
||||
// Erstelle zu testenden Constraint
|
||||
List<TypeVarAbstract> genericsA = new ArrayList<>();
|
||||
TypeVar t2 = TypeVarFactory.makeTypeVar();
|
||||
TypeVar t3 = TypeVarFactory.makeTypeVar();
|
||||
genericsA.add(t3);
|
||||
genericsA.add(t2);
|
||||
InterfaceForConstraint if2 = new InterfaceForConstraint(t1,genericsA);
|
||||
|
||||
|
||||
ConstraintSubType constraintSubType = new ConstraintSubType(TypeVarFactory.makeTypeVar(myInteger) , TypeVarFactory.makeTypeVar(if2));
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
constraints.add(constraintSubType);
|
||||
|
||||
|
||||
System.out.println("Implemented Interfaces: " + interfaces);
|
||||
|
||||
System.out.println("ConstraintSet: " + constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.setConstraintInterfaces(interfaces);
|
||||
|
||||
rules.adapt1(constraints);
|
||||
System.out.println("Neue Constraints: " + constraints);
|
||||
|
||||
rules.reduceEqual(constraints);
|
||||
System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public void adapt2Test() {
|
||||
System.out.println("Adapt2 Test");
|
||||
|
||||
// gemeinsamer Typ
|
||||
TypeVarAbstract t1 = TypeVarFactory.makeTypeVar();
|
||||
|
||||
// extend
|
||||
TypeVarAbstract text1 = TypeVarFactory.makeTypeVar();
|
||||
TypeVarAbstract text2 = TypeVarFactory.makeTypeVar();
|
||||
ConstraintSubType csub = new ConstraintSubType(text1,text2);
|
||||
|
||||
|
||||
// implements Interface myInteger implements Interface
|
||||
List<TypeVarAbstract> generics = new ArrayList<>();
|
||||
generics.add(TypeVarFactory.makeTypeVar(myInteger));
|
||||
generics.add(TypeVarFactory.makeTypeVar(myInteger));
|
||||
InterfaceForConstraint if1 = new InterfaceForConstraint(t1, generics);
|
||||
ConstraintInterface constraintInterface = new ConstraintInterface(TypeVarFactory.makeTypeVar(myInteger) , TypeVarFactory.makeTypeVar(if1) );
|
||||
List<ConstraintInterface> interfaces = new ArrayList<>();
|
||||
interfaces.add(constraintInterface);
|
||||
|
||||
// Erstelle zu testenden Constraint
|
||||
List<TypeVarAbstract> genericsA = new ArrayList<>();
|
||||
TypeVar t2 = TypeVarFactory.makeTypeVar();
|
||||
TypeVar t3 = TypeVarFactory.makeTypeVar();
|
||||
genericsA.add(t3);
|
||||
genericsA.add(t2);
|
||||
InterfaceForConstraint if2 = new InterfaceForConstraint(t1,genericsA);
|
||||
|
||||
|
||||
ConstraintSubType constraintSubType = new ConstraintSubType(TypeVarFactory.makeTypeVar(myInteger) , text1);
|
||||
ConstraintSubType constraintSubType1 = new ConstraintSubType(text2 , TypeVarFactory.makeTypeVar(if2));
|
||||
List<ConstraintAbstract> constraints = new ArrayList<>();
|
||||
constraints.add(constraintSubType);
|
||||
constraints.add(constraintSubType1);
|
||||
constraints.add(csub);
|
||||
|
||||
|
||||
System.out.println("Implemented Interfaces: " + interfaces);
|
||||
|
||||
System.out.println("ConstraintSet: " + constraints);
|
||||
|
||||
Rules rules = new Rules();
|
||||
rules.setConstraintInterfaces(interfaces);
|
||||
|
||||
rules.adapt2(constraints);
|
||||
System.out.println("Neue Constraints: " + constraints);
|
||||
|
||||
//rules.reduceEqual(constraints);
|
||||
//System.out.println(constraints);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
Loading…
Reference in New Issue
Block a user