JPanel jpanel1 = new JPanel(); FormLayout formlayout1 = new FormLayout( "FILL:DEFAULT:GROW(1.0),3DLU,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE,1DLU,FILL:DEFAULT:GROW(1.0),3DLU,CENTER:DEFAULT:NONE"); CellConstraints cc = new CellConstraints(); jpanel1.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12)); jpanel1.setLayout(formlayout1); JLabel jlabel1 = new JLabel(); jlabel1.setText("Profiles:"); jpanel1.add(jlabel1, cc.xy(1, 1)); JScrollPane scrollPane = new JScrollPane(list); scrollPane.setPreferredSize(new Dimension(250, 150)); jpanel1.add(scrollPane, cc.xy(1, 3)); jpanel1.add(checkBox, cc.xy(1, 5)); jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1, CellConstraints.DEFAULT, CellConstraints.TOP)); return jpanel1;
JPanel jpanel1 = new JPanel(); FormLayout formlayout1 = new FormLayout( "FILL:DEFAULT:GROW(1.0),3DLU,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE,1DLU,FILL:DEFAULT:GROW(1.0),3DLU,CENTER:DEFAULT:NONE"); CellConstraints cc = new CellConstraints(); jpanel1.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12)); jpanel1.setLayout(formlayout1); JLabel jlabel1 = new JLabel(); jlabel1.setText("Select Folders:"); jpanel1.add(jlabel1, cc.xy(1, 1)); JScrollPane scrollPane = new JScrollPane(tree); scrollPane.setPreferredSize(new Dimension(350, 250)); jpanel1.add(scrollPane, cc.xy(1, 3)); jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1, CellConstraints.DEFAULT, CellConstraints.TOP)); return jpanel1;
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/core/src/main/java/org/columba/core/gui/profiles/ProfileManagerDialog.java File path: /columba-1.4-src/mail/src/main/java/org/columba/mail/gui/config/export/ExportDialog.java
Method name: JPanel createPanel() Method name: JPanel createPanel()
Number of AST nodes: 14 Number of AST nodes: 13
1
JPanel jpanel1 = new JPanel();
1
JPanel jpanel1 = new JPanel();
2
		FormLayout formlayout1 = new FormLayout(
2
		FormLayout formlayout1 = new FormLayout(
3
				"FILL:DEFAULT:GROW(1.0),3DLU,FILL:DEFAULT:NONE",
3
				"FILL:DEFAULT:GROW(1.0),3DLU,FILL:DEFAULT:NONE",
4
				"CENTER:DEFAULT:NONE,1DLU,FILL:DEFAULT:GROW(1.0),3DLU,CENTER:DEFAULT:NONE");
4
				"CENTER:DEFAULT:NONE,1DLU,FILL:DEFAULT:GROW(1.0),3DLU,CENTER:DEFAULT:NONE");
5
		CellConstraints cc = new CellConstraints();
5
		CellConstraints cc = new CellConstraints();
6
		jpanel1.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12));
6
		jpanel1.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12));
7
		jpanel1.setLayout(formlayout1);
7
		jpanel1.setLayout(formlayout1);
8
		JLabel jlabel1 = new JLabel();
8
		JLabel jlabel1 = new JLabel();
9
		jlabel1.setText("Profiles:");
9
		jlabel1.setText("Select Folders:");
10
		jpanel1.add(jlabel1, cc.xy(1, 1));
10
		jpanel1.add(jlabel1, cc.xy(1, 1));
11
		JScrollPane scrollPane = new JScrollPane(list);
11
		JScrollPane scrollPane = new JScrollPane(tree);
12
		scrollPane.setPreferredSize(new Dimension(250, 150));
12
		scrollPane.setPreferredSize(new Dimension(350, 250));
13
		jpanel1.add(scrollPane, cc.xy(1, 3));
13
		jpanel1.add(scrollPane, cc.xy(1, 3));
14
		jpanel1.add(checkBox, cc.xy(1, 5));
15
		jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1,
14
		jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1,
16
				CellConstraints.DEFAULT, CellConstraints.TOP));
15
				CellConstraints.DEFAULT, CellConstraints.TOP));
17
		return jpanel1;
16
		return jpanel1;
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 having the same super class
Number of node comparisons109
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements13
    Number of unmapped statements in the first code fragment1
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 3
    Mapped Statements
    ID Statement ID Statement
    1
    JPanel jpanel1 = new JPanel();
    1
    JPanel jpanel1 = new JPanel();
    2
    FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),3DLU,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE,1DLU,FILL:DEFAULT:GROW(1.0),3DLU,CENTER:DEFAULT:NONE");
    2
    FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),3DLU,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE,1DLU,FILL:DEFAULT:GROW(1.0),3DLU,CENTER:DEFAULT:NONE");
    3
    CellConstraints cc = new CellConstraints();
    3
    CellConstraints cc = new CellConstraints();
    4
    jpanel1.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12));
    4
    jpanel1.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12));
    5
    jpanel1.setLayout(formlayout1);
    5
    jpanel1.setLayout(formlayout1);
    6
    JLabel jlabel1 = new JLabel();
    6
    JLabel jlabel1 = new JLabel();
    7
    jlabel1.setText("Profiles:");
    7
    jlabel1.setText("Profiles:");
    7
    jlabel1.setText("Select Folders:");
    Differences
    Expression1Expression2Difference
    "Profiles:""Select Folders:"LITERAL_VALUE_MISMATCH
    7
    jlabel1.setText("Select Folders:");
    8
    jpanel1.add(jlabel1, cc.xy(1, 1));
    8
    jpanel1.add(jlabel1, cc.xy(1, 1));
    9
    JScrollPane scrollPane = new JScrollPane(list);
    9
    JScrollPane scrollPane = new JScrollPane(list);
    9
    JScrollPane scrollPane = new JScrollPane(tree);
    Differences
    Expression1Expression2Difference
    listtreeVARIABLE_NAME_MISMATCH
    javax.swing.JListjavax.swing.JTreeSUBCLASS_TYPE_MISMATCH
    9
    JScrollPane scrollPane = new JScrollPane(tree);
    10
    scrollPane.setPreferredSize(new Dimension(250, 150));
    10
    scrollPane.setPreferredSize(new Dimension(250, 150));
    10
    scrollPane.setPreferredSize(new Dimension(350, 250));
    Differences
    Expression1Expression2Difference
    250350LITERAL_VALUE_MISMATCH
    150250LITERAL_VALUE_MISMATCH
    10
    scrollPane.setPreferredSize(new Dimension(350, 250));
    11
    jpanel1.add(scrollPane, cc.xy(1, 3));
    11
    jpanel1.add(scrollPane, cc.xy(1, 3));
    12
    jpanel1.add(checkBox, cc.xy(1, 5));
    12
    jpanel1.add(checkBox, cc.xy(1, 5));
    12
    jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1, CellConstraints.DEFAULT, CellConstraints.TOP));
    Differences
    Expression1Expression2Difference
    checkBoxcreatePanel1()TYPE_COMPATIBLE_REPLACEMENT
    cc.xy(1,5)new CellConstraints(3,3,1,1,CellConstraints.DEFAULT,CellConstraints.TOP)TYPE_COMPATIBLE_REPLACEMENT
    Preondition Violations
    Expression cc.xy(1,5) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    12
    jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1, CellConstraints.DEFAULT, CellConstraints.TOP));
    13
    jpanel1.add(createPanel1(), new CellConstraints(3, 3, 1, 1, CellConstraints.DEFAULT, CellConstraints.TOP));
                                                                                                                                                                                                                      
    14
    return jpanel1;
    13
    return jpanel1;
    Precondition Violations (2)
    Row Violation
    1Expression cc.xy(1,5) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Clone fragment #1 returns variables jpanel1 , while Clone fragment #2 returns variables