saveFile(); super.removeNotify(); EditBus.removeFromBus(this);
updatePluginList(); installer.updateModel(); updater.updateModel();
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/jars/QuickNotepad/QuickNotepad.java File path: /jEdit-4.2/src/org/gjt/sp/jedit/pluginmgr/PluginManager.java
Method name: void removeNotify() Method name: void stateChanged(ChangeEvent)
Number of AST nodes: 3 Number of AST nodes: 3
1
saveFile();
2
		super.removeNotify();
3
		EditBus.removeFromBus(this
1
updatePluginList();
2
				installer.updateModel();
4
);
3
				updater.updateModel();
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
Number of node comparisons9
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements2
    Number of unmapped statements in the first code fragment1
    Number of unmapped statements in the second code fragment1
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    saveFile();
    1
    saveFile();
    4
    installer.updateModel();
    Differences
    Expression1Expression2Difference
    saveFileupdateModelMETHOD_INVOCATION_NAME_MISMATCH
    installerMISSING_METHOD_INVOCATION_EXPRESSION
    Preondition Violations
    Expression installer.updateModel() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression saveFile() is a void method call, and thus it cannot be parameterized
    Expression installer.updateModel() is a void method call, and thus it cannot be parameterized
    Expression installer.updateModel() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression saveFile() is a void method call, and thus it cannot be parameterized
    Expression installer.updateModel() is a void method call, and thus it cannot be parameterized
    4
    installer.updateModel();
    2
    super.removeNotify();
    2
    super.removeNotify();
    3
    updatePluginList();
    Differences
    Expression1Expression2Difference
    super.removeNotify()updatePluginList()TYPE_COMPATIBLE_REPLACEMENT
    Preondition Violations
    Expression updatePluginList() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method updatePluginList
    Expression super.removeNotify() is a void method call, and thus it cannot be parameterized
    Expression updatePluginList() is a void method call, and thus it cannot be parameterized
    Super method call super.removeNotify(); cannot be extracted from method
    3
    updatePluginList();
    3
    EditBus.removeFromBus(this);
    3
    EditBus.removeFromBus(this);
    Preondition Violations
    Unmatched statement EditBus.removeFromBus(this); cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted
                                                                  
                                                      
    5
    updater.updateModel();
    Preondition Violations
    Unmatched statement updater.updateModel(); cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted
    5
    updater.updateModel();
    Precondition Violations (13)
    Row Violation
    1Expression installer.updateModel() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Expression saveFile() is a void method call, and thus it cannot be parameterized
    3Expression installer.updateModel() is a void method call, and thus it cannot be parameterized
    4Expression installer.updateModel() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    5Expression saveFile() is a void method call, and thus it cannot be parameterized
    6Expression installer.updateModel() is a void method call, and thus it cannot be parameterized
    7Expression updatePluginList() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    8Expression super.removeNotify() is a void method call, and thus it cannot be parameterized
    9Expression updatePluginList() is a void method call, and thus it cannot be parameterized
    10Super method call super.removeNotify(); cannot be extracted from method
    11Unmatched statement EditBus.removeFromBus(this); cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted
    12Unmatched statement updater.updateModel(); cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted
    13The refactoring of the clones is infeasible, because classes QuickNotepad and org.gjt.sp.jedit.pluginmgr.PluginManager.ListUpdater do not have a common superclass