Bug 512217 Add Redundancy Loop Detection Trivial Option
Change-Id: Ic70c4d0429c380cd1d5c0845d80b90011b37141d
Signed-off-by: Arnault Lapitre <arnault.lapitre@cea.fr>
diff --git a/execution/org.eclipse.efm.execution.configuration.common.ui/src/org/eclipse/efm/execution/configuration/common/ui/page/overview/OverviewExplorationConfigurationProfile.java b/execution/org.eclipse.efm.execution.configuration.common.ui/src/org/eclipse/efm/execution/configuration/common/ui/page/overview/OverviewExplorationConfigurationProfile.java
index 5431e37..6087680 100644
--- a/execution/org.eclipse.efm.execution.configuration.common.ui/src/org/eclipse/efm/execution/configuration/common/ui/page/overview/OverviewExplorationConfigurationProfile.java
+++ b/execution/org.eclipse.efm.execution.configuration.common.ui/src/org/eclipse/efm/execution/configuration/common/ui/page/overview/OverviewExplorationConfigurationProfile.java
@@ -38,7 +38,9 @@
private GraphExplorationStrategyKind fAnalyzeStrategy =
GraphExplorationStrategyKind.BREADTH_FIRST_SEARCH;
- private Group groupInclusionCriterion;
+ private Group fGroupInclusionCriterion;
+ private BooleanFieldEditor fApplyInclusionBooleanField;
+ private Composite fLoopDetectionTrivialComposite;
/**
@@ -118,19 +120,47 @@
createControlInclusionCriterion(parent, widgetToolkit);
}
- private void createControlInclusionCriterion(Composite parent, IWidgetToolkit widgetToolkit) {
- groupInclusionCriterion = widgetToolkit.createGroup(parent,
- "Inclusion Criterion", 5, 2, GridData.FILL_HORIZONTAL);
+ private void createControlInclusionCriterion(
+ Composite parent, IWidgetToolkit widgetToolkit)
+ {
+ fGroupInclusionCriterion = widgetToolkit.createGroup(parent,
+ "Inclusion Criterion", 2, 2, GridData.FILL_HORIZONTAL);
Composite comp = widgetToolkit.createComposite(
- groupInclusionCriterion, 1, 1, GridData.FILL_HORIZONTAL);
+ fGroupInclusionCriterion, 2, 1, GridData.FILL_HORIZONTAL);
- BooleanFieldEditor applyInclusionBooleanField =
+ fApplyInclusionBooleanField =
new BooleanFieldEditor(this.fConfigurationPage,
- ATTR_ENABLED_INCLUSION_CRITERION, "&Apply Inclusion", comp, false);
- addField(applyInclusionBooleanField);
+ ATTR_ENABLED_REDUNDANCY_INCLUSION_CRITERION,
+ "&Apply Inclusion", comp, false);
+ addField(fApplyInclusionBooleanField);
+
+
+ fLoopDetectionTrivialComposite = widgetToolkit.createComposite(
+ fGroupInclusionCriterion, 2, 1, GridData.FILL_HORIZONTAL);
+
+ BooleanFieldEditor loopDetectionTrivialBooleanField =
+ new BooleanFieldEditor(this.fConfigurationPage,
+ ATTR_ENABLED_REDUNDANCY_LOOP_DETECTION_TRIVIAL,
+ "&Loop Detection Trivial",
+ fLoopDetectionTrivialComposite, false);
+ addField(loopDetectionTrivialBooleanField);
+
+ fApplyInclusionBooleanField.addSelectionListener( new SelectionAdapter() {
+ @Override
+ public void widgetSelected(SelectionEvent e) {
+ handleEnablingRedundancyDetection();
+ }
+ });
}
+
+ private void handleEnablingRedundancyDetection() {
+ fConfigurationPage.setVisibleAndEnabled(fLoopDetectionTrivialComposite,
+ ! fApplyInclusionBooleanField.getBooleanValue());
+ }
+
+
protected void createAnalyzeStrategy(Composite parent, IWidgetToolkit widgetToolkit) {
groupAnalyzeStrategy = widgetToolkit.createGroup(
@@ -155,7 +185,9 @@
{
configuration.setAttribute(ATTR_SPECIFICATION_ANALYZE_STRATEGY, "BFS");
- configuration.setAttribute(ATTR_ENABLED_INCLUSION_CRITERION, false);
+ configuration.setAttribute(ATTR_ENABLED_REDUNDANCY_INCLUSION_CRITERION, false);
+
+ configuration.setAttribute(ATTR_ENABLED_REDUNDANCY_LOOP_DETECTION_TRIVIAL, true);
}
@Override
@@ -179,6 +211,8 @@
}
initializeAnalyzeStrategy();
+
+ handleEnablingRedundancyDetection();
}
diff --git a/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.ecore b/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.ecore
index b75b727..24f1ecc 100644
--- a/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.ecore
+++ b/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.ecore
@@ -347,6 +347,9 @@
defaultValueLiteral="CURRENT"/>
<eStructuralFeatures xsi:type="ecore:EAttribute" name="dataScope" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"
defaultValueLiteral="ALL"/>
+ <eStructuralFeatures xsi:type="ecore:EAttribute" name="loopDetetctionTrivial"
+ eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"
+ defaultValueLiteral="true"/>
</eClassifiers>
</eSubpackages>
<eSubpackages name="coverage" nsURI="http://www.eclipse.org/efm/Workflow/Coverage"
diff --git a/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.genmodel b/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.genmodel
index 2b68fee..efb4aba 100644
--- a/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.genmodel
+++ b/execution/org.eclipse.efm.execution.core/resources/ecore/workflow.genmodel
@@ -295,6 +295,7 @@
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute workflow.ecore#//common/RedundancyDetection/solver"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute workflow.ecore#//common/RedundancyDetection/pathScope"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute workflow.ecore#//common/RedundancyDetection/dataScope"/>
+ <genFeatures createChild="false" ecoreFeature="ecore:EAttribute workflow.ecore#//common/RedundancyDetection/loopDetetctionTrivial"/>
</genClasses>
</nestedGenPackages>
<nestedGenPackages prefix="Coverage" basePackage="org.eclipse.efm.execution.core.workflow"
diff --git a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/CommonPackage.java b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/CommonPackage.java
index 922a9ce..e32ad22 100644
--- a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/CommonPackage.java
+++ b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/CommonPackage.java
@@ -1389,13 +1389,22 @@
int REDUNDANCY_DETECTION__DATA_SCOPE = 3;
/**
+ * The feature id for the '<em><b>Loop Detetction Trivial</b></em>' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ * @ordered
+ */
+ int REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL = 4;
+
+ /**
* The number of structural features of the '<em>Redundancy Detection</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
- int REDUNDANCY_DETECTION_FEATURE_COUNT = 4;
+ int REDUNDANCY_DETECTION_FEATURE_COUNT = 5;
/**
* The number of operations of the '<em>Redundancy Detection</em>' class.
@@ -2740,6 +2749,17 @@
EAttribute getRedundancyDetection_DataScope();
/**
+ * Returns the meta object for the attribute '{@link org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#isLoopDetetctionTrivial <em>Loop Detetction Trivial</em>}'.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @return the meta object for the attribute '<em>Loop Detetction Trivial</em>'.
+ * @see org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#isLoopDetetctionTrivial()
+ * @see #getRedundancyDetection()
+ * @generated
+ */
+ EAttribute getRedundancyDetection_LoopDetetctionTrivial();
+
+ /**
* Returns the meta object for enum '{@link org.eclipse.efm.execution.core.workflow.common.GraphExplorationStrategyKind <em>Graph Exploration Strategy Kind</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -3789,6 +3809,14 @@
EAttribute REDUNDANCY_DETECTION__DATA_SCOPE = eINSTANCE.getRedundancyDetection_DataScope();
/**
+ * The meta object literal for the '<em><b>Loop Detetction Trivial</b></em>' attribute feature.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ EAttribute REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL = eINSTANCE.getRedundancyDetection_LoopDetetctionTrivial();
+
+ /**
* The meta object literal for the '{@link org.eclipse.efm.execution.core.workflow.common.GraphExplorationStrategyKind <em>Graph Exploration Strategy Kind</em>}' enum.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
diff --git a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/RedundancyDetection.java b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/RedundancyDetection.java
index d7ee56b..655b364 100644
--- a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/RedundancyDetection.java
+++ b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/RedundancyDetection.java
@@ -27,6 +27,7 @@
* <li>{@link org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#getSolver <em>Solver</em>}</li>
* <li>{@link org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#getPathScope <em>Path Scope</em>}</li>
* <li>{@link org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#getDataScope <em>Data Scope</em>}</li>
+ * <li>{@link org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#isLoopDetetctionTrivial <em>Loop Detetction Trivial</em>}</li>
* </ul>
*
* @see org.eclipse.efm.execution.core.workflow.common.CommonPackage#getRedundancyDetection()
@@ -142,4 +143,31 @@
*/
void setDataScope(String value);
+ /**
+ * Returns the value of the '<em><b>Loop Detetction Trivial</b></em>' attribute.
+ * The default value is <code>"true"</code>.
+ * <!-- begin-user-doc -->
+ * <p>
+ * If the meaning of the '<em>Loop Detetction Trivial</em>' attribute isn't clear,
+ * there really should be more of a description here...
+ * </p>
+ * <!-- end-user-doc -->
+ * @return the value of the '<em>Loop Detetction Trivial</em>' attribute.
+ * @see #setLoopDetetctionTrivial(boolean)
+ * @see org.eclipse.efm.execution.core.workflow.common.CommonPackage#getRedundancyDetection_LoopDetetctionTrivial()
+ * @model default="true"
+ * @generated
+ */
+ boolean isLoopDetetctionTrivial();
+
+ /**
+ * Sets the value of the '{@link org.eclipse.efm.execution.core.workflow.common.RedundancyDetection#isLoopDetetctionTrivial <em>Loop Detetction Trivial</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @param value the new value of the '<em>Loop Detetction Trivial</em>' attribute.
+ * @see #isLoopDetetctionTrivial()
+ * @generated
+ */
+ void setLoopDetetctionTrivial(boolean value);
+
} // RedundancyDetection
diff --git a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/CommonPackageImpl.java b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/CommonPackageImpl.java
index 1b81bca..6b54afb 100644
--- a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/CommonPackageImpl.java
+++ b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/CommonPackageImpl.java
@@ -1338,6 +1338,15 @@
* <!-- end-user-doc -->
* @generated
*/
+ public EAttribute getRedundancyDetection_LoopDetetctionTrivial() {
+ return (EAttribute)redundancyDetectionEClass.getEStructuralFeatures().get(4);
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
public EEnum getGraphExplorationStrategyKind() {
return graphExplorationStrategyKindEEnum;
}
@@ -1553,6 +1562,7 @@
createEAttribute(redundancyDetectionEClass, REDUNDANCY_DETECTION__SOLVER);
createEAttribute(redundancyDetectionEClass, REDUNDANCY_DETECTION__PATH_SCOPE);
createEAttribute(redundancyDetectionEClass, REDUNDANCY_DETECTION__DATA_SCOPE);
+ createEAttribute(redundancyDetectionEClass, REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL);
// Create enums
graphExplorationStrategyKindEEnum = createEEnum(GRAPH_EXPLORATION_STRATEGY_KIND);
@@ -1727,6 +1737,7 @@
initEAttribute(getRedundancyDetection_Solver(), ecorePackage.getEString(), "solver", "OMEGA", 0, 1, RedundancyDetection.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getRedundancyDetection_PathScope(), ecorePackage.getEString(), "pathScope", "CURRENT", 0, 1, RedundancyDetection.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getRedundancyDetection_DataScope(), ecorePackage.getEString(), "dataScope", "ALL", 0, 1, RedundancyDetection.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getRedundancyDetection_LoopDetetctionTrivial(), ecorePackage.getEBoolean(), "loopDetetctionTrivial", "true", 0, 1, RedundancyDetection.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
// Initialize enums and add enum literals
initEEnum(graphExplorationStrategyKindEEnum, GraphExplorationStrategyKind.class, "GraphExplorationStrategyKind");
diff --git a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/RedundancyDetectionImpl.java b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/RedundancyDetectionImpl.java
index b566d53..36e29e3 100644
--- a/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/RedundancyDetectionImpl.java
+++ b/execution/org.eclipse.efm.execution.core/src-gen/org/eclipse/efm/execution/core/workflow/common/impl/RedundancyDetectionImpl.java
@@ -34,6 +34,7 @@
* <li>{@link org.eclipse.efm.execution.core.workflow.common.impl.RedundancyDetectionImpl#getSolver <em>Solver</em>}</li>
* <li>{@link org.eclipse.efm.execution.core.workflow.common.impl.RedundancyDetectionImpl#getPathScope <em>Path Scope</em>}</li>
* <li>{@link org.eclipse.efm.execution.core.workflow.common.impl.RedundancyDetectionImpl#getDataScope <em>Data Scope</em>}</li>
+ * <li>{@link org.eclipse.efm.execution.core.workflow.common.impl.RedundancyDetectionImpl#isLoopDetetctionTrivial <em>Loop Detetction Trivial</em>}</li>
* </ul>
*
* @generated
@@ -120,6 +121,26 @@
protected String dataScope = DATA_SCOPE_EDEFAULT;
/**
+ * The default value of the '{@link #isLoopDetetctionTrivial() <em>Loop Detetction Trivial</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @see #isLoopDetetctionTrivial()
+ * @generated
+ * @ordered
+ */
+ protected static final boolean LOOP_DETETCTION_TRIVIAL_EDEFAULT = true;
+
+ /**
+ * The cached value of the '{@link #isLoopDetetctionTrivial() <em>Loop Detetction Trivial</em>}' attribute.
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @see #isLoopDetetctionTrivial()
+ * @generated
+ * @ordered
+ */
+ protected boolean loopDetetctionTrivial = LOOP_DETETCTION_TRIVIAL_EDEFAULT;
+
+ /**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
@@ -227,6 +248,27 @@
* <!-- end-user-doc -->
* @generated
*/
+ public boolean isLoopDetetctionTrivial() {
+ return loopDetetctionTrivial;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
+ public void setLoopDetetctionTrivial(boolean newLoopDetetctionTrivial) {
+ boolean oldLoopDetetctionTrivial = loopDetetctionTrivial;
+ loopDetetctionTrivial = newLoopDetetctionTrivial;
+ if (eNotificationRequired())
+ eNotify(new ENotificationImpl(this, Notification.SET, CommonPackage.REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL, oldLoopDetetctionTrivial, loopDetetctionTrivial));
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @generated
+ */
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
@@ -238,6 +280,8 @@
return getPathScope();
case CommonPackage.REDUNDANCY_DETECTION__DATA_SCOPE:
return getDataScope();
+ case CommonPackage.REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL:
+ return isLoopDetetctionTrivial();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -262,6 +306,9 @@
case CommonPackage.REDUNDANCY_DETECTION__DATA_SCOPE:
setDataScope((String)newValue);
return;
+ case CommonPackage.REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL:
+ setLoopDetetctionTrivial((Boolean)newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -286,6 +333,9 @@
case CommonPackage.REDUNDANCY_DETECTION__DATA_SCOPE:
setDataScope(DATA_SCOPE_EDEFAULT);
return;
+ case CommonPackage.REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL:
+ setLoopDetetctionTrivial(LOOP_DETETCTION_TRIVIAL_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
@@ -306,6 +356,8 @@
return PATH_SCOPE_EDEFAULT == null ? pathScope != null : !PATH_SCOPE_EDEFAULT.equals(pathScope);
case CommonPackage.REDUNDANCY_DETECTION__DATA_SCOPE:
return DATA_SCOPE_EDEFAULT == null ? dataScope != null : !DATA_SCOPE_EDEFAULT.equals(dataScope);
+ case CommonPackage.REDUNDANCY_DETECTION__LOOP_DETETCTION_TRIVIAL:
+ return loopDetetctionTrivial != LOOP_DETETCTION_TRIVIAL_EDEFAULT;
}
return super.eIsSet(featureID);
}
@@ -328,6 +380,8 @@
result.append(pathScope);
result.append(", dataScope: ");
result.append(dataScope);
+ result.append(", loopDetetctionTrivial: ");
+ result.append(loopDetetctionTrivial);
result.append(')');
return result.toString();
}
diff --git a/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/IWorkflowConfigurationConstants.java b/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/IWorkflowConfigurationConstants.java
index c05287d..9de1d55 100644
--- a/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/IWorkflowConfigurationConstants.java
+++ b/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/IWorkflowConfigurationConstants.java
@@ -168,8 +168,11 @@
// SUPERVISOR: REDUNDANCY DETECTOR a.k.a. INCLUSION CRITERION
////////////////////////////////////////////////////////////////////////////
- public static final String ATTR_ENABLED_INCLUSION_CRITERION =
- PLUGIN_LAUNCH_ID + ".ATTR_ENABLED_INCLUSION_CRITERION"; //$NON-NLS-1$
+ public static final String ATTR_ENABLED_REDUNDANCY_INCLUSION_CRITERION =
+ PLUGIN_LAUNCH_ID + ".ATTR_ENABLED_REDUNDANCY_INCLUSION_CRITERION"; //$NON-NLS-1$
+
+ public static final String ATTR_ENABLED_REDUNDANCY_LOOP_DETECTION_TRIVIAL =
+ PLUGIN_LAUNCH_ID + ".ATTR_ENABLED_REDUNDANCY_LOOP_DETECTION_TRIVIAL"; //$NON-NLS-1$
////////////////////////////////////////////////////////////////////////////
diff --git a/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/DirectorCustomImpl.java b/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/DirectorCustomImpl.java
index 35c64cb..d847c33 100644
--- a/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/DirectorCustomImpl.java
+++ b/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/DirectorCustomImpl.java
@@ -22,6 +22,7 @@
import org.eclipse.efm.execution.core.workflow.common.DeveloperTuningOptionCustomImpl;
import org.eclipse.efm.execution.core.workflow.common.ManifestCustomImpl;
import org.eclipse.efm.execution.core.workflow.common.Project;
+import org.eclipse.efm.execution.core.workflow.common.RedundancyDetection;
import org.eclipse.efm.execution.core.workflow.coverage.BehaviorCoverageWorkerCustomImpl;
import org.eclipse.efm.execution.core.workflow.coverage.TransitionCoverageWorkerCustomImpl;
import org.eclipse.efm.execution.core.workflow.impl.DirectorImpl;
@@ -189,10 +190,14 @@
}
if( isRedundancyDetectionPossible ) {
+ RedundancyDetection redundancy =
+ CommonFactory.eINSTANCE.createRedundancyDetection();
+ getSupervisor().setRedundancy(redundancy);
+
boolean enabledRedundancyDetection = false;
try {
enabledRedundancyDetection = configuration.getAttribute(
- ATTR_ENABLED_INCLUSION_CRITERION, false);
+ ATTR_ENABLED_REDUNDANCY_INCLUSION_CRITERION, false);
}
catch( CoreException e ) {
e.printStackTrace();
@@ -200,10 +205,21 @@
enabledRedundancyDetection = false;
}
- if( enabledRedundancyDetection ) {
- getSupervisor().setRedundancy(
- CommonFactory.eINSTANCE.createRedundancyDetection());
+ if( ! enabledRedundancyDetection ) {
+ redundancy.setComparer( null );;
}
+
+ try {
+ enabledRedundancyDetection = configuration.getAttribute(
+ ATTR_ENABLED_REDUNDANCY_LOOP_DETECTION_TRIVIAL, false);
+ }
+ catch( CoreException e ) {
+ e.printStackTrace();
+
+ enabledRedundancyDetection = false;
+ }
+
+ redundancy.setLoopDetetctionTrivial(enabledRedundancyDetection);
}
return( true );
diff --git a/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/SupervisorWorkerCustomImpl.java b/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/SupervisorWorkerCustomImpl.java
index 9539dc6..82c671a 100644
--- a/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/SupervisorWorkerCustomImpl.java
+++ b/execution/org.eclipse.efm.execution.core/src/org/eclipse/efm/execution/core/workflow/SupervisorWorkerCustomImpl.java
@@ -304,27 +304,31 @@
RedundancyDetection redundancy = getRedundancy();
if( redundancy != null ) {
- if( (str = redundancy.getComparer()) == null ) {
- str = "NONE";
- }
- writer.appendTab3( "comparer = '" ).append( str ).appendEol( "'" );
+ if( (str = redundancy.getComparer()) != null ) {
+ writer.appendTab3( "comparer = '" ).append( str ).appendEol( "'" );
- if( (str = redundancy.getSolver()) == null ) {
- str = "OMEGA";
- }
- writer.appendTab3( "solver = '" ).append( str ).appendEol( "'" );
+ if( (str = redundancy.getSolver()) == null ) {
+ str = "OMEGA";
+ }
+ writer.appendTab3( "solver = '" ).append( str ).appendEol( "'" );
- if( (str = redundancy.getPathScope()) == null ) {
- str = "CURRENT";
- }
- writer.appendTab3( "path_scope = '" ).append( str ).appendEol("'");
+ if( (str = redundancy.getPathScope()) == null ) {
+ str = "CURRENT";
+ }
+ writer.appendTab3( "path_scope = '" ).append( str ).appendEol("'");
- if( (str = redundancy.getDataScope()) == null ) {
- str = "ALL";
+ if( (str = redundancy.getDataScope()) == null ) {
+ str = "ALL";
+ }
+ writer.appendTab3( "data_scope = '" ).append( str ).appendEol("'");
}
- writer.appendTab3( "data_scope = '" ).append( str ).appendEol("'");
+ else {
+ writer.appendTab3( "loop#detection#trivial = " )
+ .appendEol( redundancy.isLoopDetetctionTrivial() );
+ }
}
else {
+ writer.appendTab3Eol( "loop#detection#trivial = true" );
}
writer.appendTab2Eol( "] // end redundancy" );