super(); addListSelectionListener(this); dropTarget = new DropTarget(this, this); dragSource = DragSource.getDefaultDragSource(); if (acceptDrop == true) { dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY_OR_MOVE, this); } else { dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY, this); }
super(); addListSelectionListener(this); dropTarget = new DropTarget(this, this); dragSource = DragSource.getDefaultDragSource(); if (acceptDrop == true) { dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY_OR_MOVE, this); } else { dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY, this); }
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/contact/src/main/java/org/columba/addressbook/gui/list/AddressbookDNDListView.java File path: /columba-1.4-src/mail/src/main/java/org/columba/mail/gui/contact/list/ContactDNDListView.java
Method name: void AddressbookDNDListView() Method name: void ContactDNDListView()
Number of AST nodes: 7 Number of AST nodes: 7
1
super();
1
super();
2
		addListSelectionListener(this);
2
		addListSelectionListener(this);
3
		dropTarget = new DropTarget(this, this);
3
		dropTarget = new DropTarget(this, this);
4
		dragSource = DragSource.getDefaultDragSource();
4
		dragSource = DragSource.getDefaultDragSource();
5
		if (acceptDrop == true) {
5
		if (acceptDrop == true) {
6
			dragSource.createDefaultDragGestureRecognizer(this,
6
			dragSource.createDefaultDragGestureRecognizer(this,
7
					DnDConstants.ACTION_COPY_OR_MOVE, this);
7
					DnDConstants.ACTION_COPY_OR_MOVE, this);
8
		} else {
8
		} else {
9
			dragSource.createDefaultDragGestureRecognizer(this,
9
			dragSource.createDefaultDragGestureRecognizer(this,
10
					DnDConstants.ACTION_COPY, this);
10
					DnDConstants.ACTION_COPY, this);
11
		}
11
		}
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.2
Clones locationClones are in different classes having the same super class
Number of node comparisons16
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements7
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)5.9
    Clone typeType 1
    Mapped Statements
    ID Statement ID Statement
    1
    super();
    1
    super();
    1
    super();
    Preondition Violations
    Super constructor call super(); cannot be extracted from constructor
    Super constructor call super(); cannot be extracted from constructor
    1
    super();
    2
    addListSelectionListener(this);
    2
    addListSelectionListener(this);
    3
    dropTarget = new DropTarget(this, this);
    3
    dropTarget = new DropTarget(this, this);
    4
    dragSource = DragSource.getDefaultDragSource();
    4
    dragSource = DragSource.getDefaultDragSource();
    5
    if (acceptDrop == true)
    5
    if (acceptDrop == true)
    6
    dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY_OR_MOVE, this);
    6
    dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY_OR_MOVE, this);
    else
    else
    7
    dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY, this);
    7
    dragSource.createDefaultDragGestureRecognizer(this, DnDConstants.ACTION_COPY, this);
    Precondition Violations (3)
    Row Violation
    1Super constructor call super(); cannot be extracted from constructor
    2Super constructor call super(); cannot be extracted from constructor
    3The refactoring of the clones is infeasible, because classes org.columba.addressbook.gui.list.AddressbookDNDListView and org.columba.mail.gui.contact.list.ContactDNDListView do not have a common superclass