try { // get config plugin-handler configHandler = PluginManager.getInstance().getExtensionHandler( IExtensionHandlerKeys.ORG_COLUMBA_CORE_CONFIG); } catch (PluginHandlerNotFoundException ex) { ex.printStackTrace(); } initComponents();
try { handler = PluginManager .getInstance().getExtensionHandler( IExtensionHandlerKeys.ORG_COLUMBA_MAIL_TABLERENDERER); } catch (PluginHandlerNotFoundException ex) { ex.printStackTrace(); } getTree().setCellRenderer(new SubjectTreeRenderer(this));
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/core/src/main/java/org/columba/core/gui/config/GeneralOptionsDialog.java File path: /columba-1.4-src/mail/src/main/java/org/columba/mail/gui/table/TableView.java
Method name: void GeneralOptionsDialog(JFrame) Method name: void TableView(HeaderTableModel, TableModelSorter)
Number of AST nodes: 3 Number of AST nodes: 3
1
try {
1
try {
2
			// get config plugin-handler
2
			
3
			configHandler = PluginManager
3
handler =  PluginManager
4
.getInstance().getExtensionHandler(
4
					.getInstance().getExtensionHandler(
5
					IExtensionHandlerKeys.ORG_COLUMBA_CORE_CONFIG);
5
							IExtensionHandlerKeys.ORG_COLUMBA_MAIL_TABLERENDERER);
6
		} catch (PluginHandlerNotFoundException ex) {
6
		} catch (PluginHandlerNotFoundException ex) {
7
			ex.printStackTrace();
7
			ex.printStackTrace();
8
		}
8
		}
9
		initComponents();
9
		getTree().setCellRenderer(new SubjectTreeRenderer(this));
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.1
Clones locationClones are in different classes having the same super class
Number of node comparisons5
  1. {Non-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)0.9
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    5
    try
    6
    try
    6
    configHandler = PluginManager.getInstance().getExtensionHandler(IExtensionHandlerKeys.ORG_COLUMBA_CORE_CONFIG);
    6
    configHandler = PluginManager.getInstance().getExtensionHandler(IExtensionHandlerKeys.ORG_COLUMBA_CORE_CONFIG);
    7
    handler = PluginManager.getInstance().getExtensionHandler(IExtensionHandlerKeys.ORG_COLUMBA_MAIL_TABLERENDERER);
    Differences
    Expression1Expression2Difference
    configHandlerhandlerVARIABLE_NAME_MISMATCH
    org.columba.api.plugin.IExtensionHandlerKeysorg.columba.mail.plugin.IExtensionHandlerKeysVARIABLE_TYPE_MISMATCH
    ORG_COLUMBA_CORE_CONFIGORG_COLUMBA_MAIL_TABLERENDERERVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression configHandler is a field being modified, and thus it cannot be parameterized
    Expression handler is a field being modified, and thus it cannot be parameterized
    Type org.columba.api.plugin.IExtensionHandlerKeys of variable IExtensionHandlerKeys does not match with type org.columba.mail.plugin.IExtensionHandlerKeys of variable IExtensionHandlerKeys
    • Make classes org.columba.api.plugin.IExtensionHandlerKeys and org.columba.mail.plugin.IExtensionHandlerKeys extend a common superclass
    7
    handler = PluginManager.getInstance().getExtensionHandler(IExtensionHandlerKeys.ORG_COLUMBA_MAIL_TABLERENDERER);
    7
    initComponents();
    7
    initComponents();
    8
    getTree().setCellRenderer(new SubjectTreeRenderer(this));
    Differences
    Expression1Expression2Difference
    initComponentssetCellRendererMETHOD_INVOCATION_NAME_MISMATCH
    initComponents()getTree().setCellRenderer(new SubjectTreeRenderer(this))ARGUMENT_NUMBER_MISMATCH
    getTree()MISSING_METHOD_INVOCATION_EXPRESSION
    Preondition Violations
    Expression initComponents() is a void method call, and thus it cannot be parameterized
    Expression getTree().setCellRenderer(new SubjectTreeRenderer(this)) is a void method call, and thus it cannot be parameterized
    Expression initComponents() is a void method call, and thus it cannot be parameterized
    Expression getTree().setCellRenderer(new SubjectTreeRenderer(this)) is a void method call, and thus it cannot be parameterized
    8
    getTree().setCellRenderer(new SubjectTreeRenderer(this));
    Precondition Violations (7)
    Row Violation
    1Expression configHandler is a field being modified, and thus it cannot be parameterized
    2Expression handler is a field being modified, and thus it cannot be parameterized
    3Type org.columba.api.plugin.IExtensionHandlerKeys of variable IExtensionHandlerKeys does not match with type org.columba.mail.plugin.IExtensionHandlerKeys of variable IExtensionHandlerKeys
    4Expression initComponents() is a void method call, and thus it cannot be parameterized
    5Expression getTree().setCellRenderer(new SubjectTreeRenderer(this)) is a void method call, and thus it cannot be parameterized
    6Expression initComponents() is a void method call, and thus it cannot be parameterized
    7Expression getTree().setCellRenderer(new SubjectTreeRenderer(this)) is a void method call, and thus it cannot be parameterized