super.configure(el); XPathExtractor xpe = (XPathExtractor) el; xpathQueryField.setText(xpe.getXPathQuery()); defaultField.setText(xpe.getDefaultValue()); refNameField.setText(xpe.getRefName()); tolerant.setSelected(xpe.isTolerant()); quiet.setSelected(xpe.isQuiet()); showWarnings.setSelected(xpe.showWarnings()); reportErrors.setSelected(xpe.reportErrors()); nameSpace.setSelected(xpe.useNameSpace()); setTidyOptions(tolerant.isSelected());
super.configure(element); Table tb = (Table)element; meanCheck.setSelected(tb.getMean()); medianCheck.setSelected(tb.getMedian()); maxCheck.setSelected(tb.getMax()); minCheck.setSelected(tb.getMin()); fiftypercentCheck.setSelected(tb.get50Percent()); nintypercentCheck.setSelected(tb.get90Percent()); errorRateCheck.setSelected(tb.getErrorRate()); responseRateCheck.setSelected(tb.getResponseRate()); transferRateCheck.setSelected(tb.getTransferRate());
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/extractor/gui/XPathExtractorGui.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/report/gui/TableGui.java
Method name: void configure(TestElement) Method name: void configure(TestElement)
Number of AST nodes: 11 Number of AST nodes: 11
1
super.configure(el);
1
super.configure(el
2
		XPathExtractor xpe = (XPathExtractor) el;
3
		xpathQueryField.setText(xpe.getXPathQuery());
4
		defaultField.setText(xpe.getDefaultValue());
5
		refNameField.setText(xpe.getRefName());
6
		tolerant.setSelected(xpe.isTolerant());
7
		quiet.setSelected(xpe.isQuiet());
8
		showWarnings.setSelected(xpe.showWarnings());
9
		reportErrors
2
ement);
3
        Table tb = (Table)element;
4
        meanCheck.setSelected(tb.getMean());
5
        medianCheck.setSelected(tb.getMedian());
6
        maxCheck.setSelected(tb.getMax());
7
        minCheck.setSelected(tb.getMin());
8
        fiftypercentCheck.setSelected(tb.get50Percent());
9
        nintypercentCheck.setSelected(tb.get90Percent());
10
.setSelected(xpe.reportErrors());
10
        errorRateCheck.setSelected(tb.getErrorRate());
11
		nameSpace.setSelected(xpe.useNameSpace());
12
        setTidyOptions(tolerant.isSelected
11
        responseRateCheck.setSelected(tb.getResponseRate());
13
());
12
        transferRateCheck.setSelected(tb.getTransferRate());
Summary
Number of common nesting structure subtrees1
Number of refactorable cases0
Number of non-refactorable cases1
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones locationClones are in different classes having the same super class
Number of node comparisons121
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements7
    Number of unmapped statements in the first code fragment4
    Number of unmapped statements in the second code fragment4
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    super.configure(el);
    1
    super.configure(el);
    1
    super.configure(element);
    Differences
    Expression1Expression2Difference
    elelementVARIABLE_NAME_MISMATCH
    1
    super.configure(element);
    2
    XPathExtractor xpe = (XPathExtractor)el;
    2
    XPathExtractor xpe = (XPathExtractor)el;
    2
    Table tb = (Table)element;
    Differences
    Expression1Expression2Difference
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    xpetbVARIABLE_NAME_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    elelementVARIABLE_NAME_MISMATCH
    2
    Table tb = (Table)element;
                                                                                  
    3
    meanCheck.setSelected(tb.getMean());
    3
    xpathQueryField.setText(xpe.getXPathQuery());
                                                                                                    
                                                                                          
    4
    medianCheck.setSelected(tb.getMedian());
    4
    defaultField.setText(xpe.getDefaultValue());
                                                                                                  
                                                                              
    5
    maxCheck.setSelected(tb.getMax());
    5
    refNameField.setText(xpe.getRefName());
                                                                                        
    6
    tolerant.setSelected(xpe.isTolerant());
    6
    tolerant.setSelected(xpe.isTolerant());
    6
    minCheck.setSelected(tb.getMin());
    Differences
    Expression1Expression2Difference
    isTolerantgetMinMETHOD_INVOCATION_NAME_MISMATCH
    xpetbVARIABLE_NAME_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    tolerantminCheckVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression xpe.isTolerant() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression tb.getMin() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    6
    minCheck.setSelected(tb.getMin());
    7
    quiet.setSelected(xpe.isQuiet());
    7
    quiet.setSelected(xpe.isQuiet());
    7
    fiftypercentCheck.setSelected(tb.get50Percent());
    Differences
    Expression1Expression2Difference
    isQuietget50PercentMETHOD_INVOCATION_NAME_MISMATCH
    xpetbVARIABLE_NAME_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    quietfiftypercentCheckVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression xpe.isQuiet() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression tb.get50Percent() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    7
    fiftypercentCheck.setSelected(tb.get50Percent());
    8
    showWarnings.setSelected(xpe.showWarnings());
    8
    showWarnings.setSelected(xpe.showWarnings());
    8
    nintypercentCheck.setSelected(tb.get90Percent());
    Differences
    Expression1Expression2Difference
    showWarningsget90PercentMETHOD_INVOCATION_NAME_MISMATCH
    xpetbVARIABLE_NAME_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    showWarningsnintypercentCheckVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression xpe.showWarnings() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression tb.get90Percent() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    8
    nintypercentCheck.setSelected(tb.get90Percent());
    9
    reportErrors.setSelected(xpe.reportErrors());
    9
    reportErrors.setSelected(xpe.reportErrors());
    9
    errorRateCheck.setSelected(tb.getErrorRate());
    Differences
    Expression1Expression2Difference
    reportErrorsgetErrorRateMETHOD_INVOCATION_NAME_MISMATCH
    xpetbVARIABLE_NAME_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    reportErrorserrorRateCheckVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression xpe.reportErrors() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression tb.getErrorRate() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    9
    errorRateCheck.setSelected(tb.getErrorRate());
    10
    nameSpace.setSelected(xpe.useNameSpace());
    10
    nameSpace.setSelected(xpe.useNameSpace());
    10
    responseRateCheck.setSelected(tb.getResponseRate());
    Differences
    Expression1Expression2Difference
    useNameSpacegetResponseRateMETHOD_INVOCATION_NAME_MISMATCH
    xpetbVARIABLE_NAME_MISMATCH
    org.apache.jmeter.extractor.XPathExtractororg.apache.jmeter.testelement.TableSUBCLASS_TYPE_MISMATCH
    nameSpaceresponseRateCheckVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression xpe.useNameSpace() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression tb.getResponseRate() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    10
    responseRateCheck.setSelected(tb.getResponseRate());
                                                                                                                    
    11
    transferRateCheck.setSelected(tb.getTransferRate());
    11
    setTidyOptions(tolerant.isSelected());
                                                                                        
    Precondition Violations (11)
    Row Violation
    1Expression xpe.isTolerant() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Expression tb.getMin() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    3Expression xpe.isQuiet() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    4Expression tb.get50Percent() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    5Expression xpe.showWarnings() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    6Expression tb.get90Percent() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    7Expression xpe.reportErrors() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    8Expression tb.getErrorRate() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    9Expression xpe.useNameSpace() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    10Expression tb.getResponseRate() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    11Clone fragment #1 returns variable xpe with type org.apache.jmeter.extractor.XPathExtractor , while Clone fragment #2 returns variable tb with type org.apache.jmeter.testelement.Table