try { InputStream is = DiskIO .getResourceStream("org/columba/mail/action/messageframe_menu.xml"); container.extendMenu(this, is); } catch (IOException e) { e.printStackTrace(); }
try { InputStream is = DiskIO .getResourceStream("org/columba/mail/config/messageframe_toolbar.xml"); container.extendToolbar(this, is); } catch (IOException e) { e.printStackTrace(); }
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/mail/src/main/java/org/columba/mail/gui/messageframe/MessageFrameController.java File path: /columba-1.4-src/mail/src/main/java/org/columba/mail/gui/messageframe/MessageFrameController.java
Method name: void extendMenu(IContainer) Method name: void extendToolBar(IContainer)
Number of AST nodes: 3 Number of AST nodes: 3
1
try {
1
try {
2
			InputStream is = DiskIO
2
			InputStream is = DiskIO
3
					.getResourceStream("org/columba/mail/action/messageframe_menu.xml");
3
					.getResourceStream("org/columba/mail/config/messageframe_toolbar.xml");
4
			container.extendMenu(this, is);
4
			container.extendToolbar(this, is);
5
		} catch (IOException e) {
5
		} catch (IOException e) {
6
			e.printStackTrace();
6
			e.printStackTrace();
7
		}
7
		}
Summary
Number of common nesting structure subtrees1
Number of refactorable cases1
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.1
Clones locationClones are declared in the same class
Number of node comparisons9
  1. {Refactorable}
    Mapping Summary
    Number of mapped statements3
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)3.2
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    try
    1
    try
    2
    InputStream is = DiskIO.getResourceStream("org/columba/mail/action/messageframe_menu.xml");
    2
    InputStream is = DiskIO.getResourceStream("org/columba/mail/action/messageframe_menu.xml");
    2
    InputStream is = DiskIO.getResourceStream("org/columba/mail/config/messageframe_toolbar.xml");
    Differences
    Expression1Expression2Difference
    "org/columba/mail/action/messageframe_menu.xml""org/columba/mail/config/messageframe_toolbar.xml"LITERAL_VALUE_MISMATCH
    2
    InputStream is = DiskIO.getResourceStream("org/columba/mail/config/messageframe_toolbar.xml");
    3
    container.extendMenu(this, is);
    3
    container.extendMenu(this, is);
    3
    container.extendToolbar(this, is);
    Differences
    Expression1Expression2Difference
    extendMenuextendToolbarMETHOD_INVOCATION_NAME_MISMATCH
    Preondition Violations
    Expression container.extendMenu(this,is) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression container.extendToolbar(this,is) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression container.extendMenu(this,is) is a void method call, and thus it cannot be parameterized
    Expression container.extendToolbar(this,is) is a void method call, and thus it cannot be parameterized
    3
    container.extendToolbar(this, is);
    Precondition Violations (4)
    Row Violation
    1Expression container.extendMenu(this,is) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Expression container.extendToolbar(this,is) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    3Expression container.extendMenu(this,is) is a void method call, and thus it cannot be parameterized
    4Expression container.extendToolbar(this,is) is a void method call, and thus it cannot be parameterized