saveClass(el,writer,TestElement.GUI_CLASS); saveClass(el,writer,TestElement.TEST_CLASS); saveItem(el,writer,TestElement.NAME,true); saveItem(el,writer,TestElement.ENABLED,false);
restoreClass(el,reader,TestElement.GUI_CLASS); restoreClass(el,reader,TestElement.TEST_CLASS); restoreItem(el,reader,TestElement.NAME,true); restoreItem(el,reader,TestElement.ENABLED,false);
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/save/converters/ConversionHelp.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/save/converters/ConversionHelp.java
Method name: void saveSpecialProperties(TestElement, HierarchicalStreamWriter) Method name: void restoreSpecialProperties(TestElement, HierarchicalStreamReader)
Number of AST nodes: 4 Number of AST nodes: 4
1
saveClass(el,writer,TestElement.GUI_CLASS);
1
restoreClass(el,reader,TestElement.GUI_CLASS);
2
        saveClass(el,writer,TestElement.TEST_CLASS);
2
        restoreClass(el,reader,TestElement.TEST_CLASS);
3
        saveItem(el,writer,TestElement.NAME,true);
3
        restoreItem(el,reader,TestElement.NAME,true);
4
        saveItem(el,writer,TestElement.ENABLED,false);
4
        restoreItem(el,reader,TestElement.ENABLED,false);
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 declared in the same class
Number of node comparisons16
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements4
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    saveClass(el, writer, TestElement.GUI_CLASS);
    1
    saveClass(el, writer, TestElement.GUI_CLASS);
    3
    restoreItem(el, reader, TestElement.NAME, true);
    Differences
    Expression1Expression2Difference
    saveClassrestoreItemMETHOD_INVOCATION_NAME_MISMATCH
    saveClass(el,writer,TestElement.GUI_CLASS)restoreItem(el,reader,TestElement.NAME,true)ARGUMENT_NUMBER_MISMATCH
    Preondition Violations
    Expression restoreItem(el,reader,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method restoreItem
    Expression saveClass(el,writer,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    Expression restoreItem(el,reader,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    Expression restoreItem(el,reader,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method restoreItem
    Expression saveClass(el,writer,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    Expression restoreItem(el,reader,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    3
    restoreItem(el, reader, TestElement.NAME, true);
    2
    saveClass(el, writer, TestElement.TEST_CLASS);
    2
    saveClass(el, writer, TestElement.TEST_CLASS);
    4
    restoreItem(el, reader, TestElement.ENABLED, false);
    Differences
    Expression1Expression2Difference
    saveClassrestoreItemMETHOD_INVOCATION_NAME_MISMATCH
    saveClass(el,writer,TestElement.TEST_CLASS)restoreItem(el,reader,TestElement.ENABLED,false)ARGUMENT_NUMBER_MISMATCH
    Preondition Violations
    Expression saveClass(el,writer,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method saveClass
    Expression restoreItem(el,reader,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method restoreItem
    Expression saveClass(el,writer,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    Expression restoreItem(el,reader,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    Expression saveClass(el,writer,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method saveClass
    Expression restoreItem(el,reader,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method restoreItem
    Expression saveClass(el,writer,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    Expression restoreItem(el,reader,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    4
    restoreItem(el, reader, TestElement.ENABLED, false);
    3
    saveItem(el, writer, TestElement.NAME, true);
    3
    saveItem(el, writer, TestElement.NAME, true);
    1
    restoreClass(el, reader, TestElement.GUI_CLASS);
    Differences
    Expression1Expression2Difference
    saveItemrestoreClassMETHOD_INVOCATION_NAME_MISMATCH
    saveItem(el,writer,TestElement.NAME,true)restoreClass(el,reader,TestElement.GUI_CLASS)ARGUMENT_NUMBER_MISMATCH
    Preondition Violations
    Expression saveItem(el,writer,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method saveItem
    Expression saveItem(el,writer,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    Expression restoreClass(el,reader,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    Expression saveItem(el,writer,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method saveItem
    Expression saveItem(el,writer,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    Expression restoreClass(el,reader,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    1
    restoreClass(el, reader, TestElement.GUI_CLASS);
    4
    saveItem(el, writer, TestElement.ENABLED, false);
    4
    saveItem(el, writer, TestElement.ENABLED, false);
    2
    restoreClass(el, reader, TestElement.TEST_CLASS);
    Differences
    Expression1Expression2Difference
    saveItemrestoreClassMETHOD_INVOCATION_NAME_MISMATCH
    saveItem(el,writer,TestElement.ENABLED,false)restoreClass(el,reader,TestElement.TEST_CLASS)ARGUMENT_NUMBER_MISMATCH
    Preondition Violations
    Expression saveItem(el,writer,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method saveItem
    Expression restoreClass(el,reader,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method restoreClass
    Expression saveItem(el,writer,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    Expression restoreClass(el,reader,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    Expression saveItem(el,writer,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method saveItem
    Expression restoreClass(el,reader,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method restoreClass
    Expression saveItem(el,writer,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    Expression restoreClass(el,reader,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    2
    restoreClass(el, reader, TestElement.TEST_CLASS);
    Precondition Violations (28)
    Row Violation
    1Expression restoreItem(el,reader,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Expression saveClass(el,writer,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    3Expression restoreItem(el,reader,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    4Expression restoreItem(el,reader,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    5Expression saveClass(el,writer,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    6Expression restoreItem(el,reader,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    7Expression saveClass(el,writer,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    8Expression restoreItem(el,reader,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    9Expression saveClass(el,writer,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    10Expression restoreItem(el,reader,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    11Expression saveClass(el,writer,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    12Expression restoreItem(el,reader,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    13Expression saveClass(el,writer,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    14Expression restoreItem(el,reader,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    15Expression saveItem(el,writer,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    16Expression saveItem(el,writer,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    17Expression restoreClass(el,reader,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    18Expression saveItem(el,writer,TestElement.NAME,true) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    19Expression saveItem(el,writer,TestElement.NAME,true) is a void method call, and thus it cannot be parameterized
    20Expression restoreClass(el,reader,TestElement.GUI_CLASS) is a void method call, and thus it cannot be parameterized
    21Expression saveItem(el,writer,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    22Expression restoreClass(el,reader,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    23Expression saveItem(el,writer,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    24Expression restoreClass(el,reader,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized
    25Expression saveItem(el,writer,TestElement.ENABLED,false) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    26Expression restoreClass(el,reader,TestElement.TEST_CLASS) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    27Expression saveItem(el,writer,TestElement.ENABLED,false) is a void method call, and thus it cannot be parameterized
    28Expression restoreClass(el,reader,TestElement.TEST_CLASS) is a void method call, and thus it cannot be parameterized