JPanel jpanel1 = new JPanel(); FormLayout formlayout1 = new FormLayout( "FILL:DEFAULT:GROW(1.0),3dlu,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE"); CellConstraints cc = new CellConstraints(); jpanel1.setLayout(formlayout1); jpanel1.add(alarmComboBox, cc.xy(1, 1)); alarmButton.setActionCommand("Customize..."); alarmButton.setText("Customize..."); jpanel1.add(alarmButton, cc.xy(3, 1)); return jpanel1;
JPanel panel = new JPanel(); FormLayout formlayout1 = new FormLayout( "FILL:DEFAULT:NONE,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE"); CellConstraints cc = new CellConstraints(); panel.setLayout(formlayout1); rUntilDate.setText("Until "); rUntilDate.setActionCommand("until"); rUntilDate.addActionListener(this); panel.add(rUntilDate, cc.xy(1, 1)); panel.add(endDatePicker, cc.xy(2, 1)); return panel;
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/calendar/src/main/java/org/columba/calendar/ui/dialog/EditEventDialog.java File path: /columba-1.4-src/calendar/src/main/java/org/columba/calendar/ui/dialog/RecurrenceDialog.java
Method name: JPanel createPanel3() Method name: JPanel createUntilDatePanel()
Number of AST nodes: 9 Number of AST nodes: 10
1
JPanel jpanel1 = new JPanel();
1
JPanel panel = new JPanel();
2

2
		FormLayout formlayout1 = new FormLayout(
3
		FormLayout formlayout1 = new FormLayout(
3
				"FILL:DEFAULT:GROW(1.0),3dlu,FILL:DEFAULT:NONE",
4
				"FILL:DEFAULT:NONE,FILL:DEFAULT:NONE",
4
				"CENTER:DEFAULT:NONE");
5
				"CENTER:DEFAULT:NONE");
5
		CellConstraints cc = new CellConstraints();
6
		CellConstraints cc = new CellConstraints();
6
		jpanel1.setLayout(formlayout1);
7
		panel.setLayout(formlayout1);
7
		jpanel1.add(alarmComboBox, cc.xy(1, 1)
8
);
8
		rUntilDate.setText("Until ");
9

9
		alarmButton.setActionCommand("Customize...");
10
		rUntilDate.setActionCommand("until");
10
		alarmButton.setText("Customize..."
11
		rUntilDate.addActionListener(this);
11
);
12
		panel.add(rUntilDate, cc.xy(1, 1));
12
		jpanel1.add(alarmButton, cc.xy(3, 1));
13
		panel.add(endDatePicker, cc.xy(2, 1));
14
		
13
		return jpanel1;
15
		return panel;
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.0
Clones locationClones are in different classes having the same super class
Number of node comparisons39
  1. {Refactorable}
    Mapping Summary
    Number of mapped statements9
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment1
    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();
    1
    JPanel panel = new JPanel();
    Differences
    Expression1Expression2Difference
    jpanel1panelVARIABLE_NAME_MISMATCH
    1
    JPanel panel = new JPanel();
    2
    FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),3dlu,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE");
    2
    FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),3dlu,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE");
    2
    FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE");
    Differences
    Expression1Expression2Difference
    "FILL:DEFAULT:GROW(1.0),3dlu,FILL:DEFAULT:NONE""FILL:DEFAULT:NONE,FILL:DEFAULT:NONE"LITERAL_VALUE_MISMATCH
    2
    FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE", "CENTER:DEFAULT:NONE");
    3
    CellConstraints cc = new CellConstraints();
    3
    CellConstraints cc = new CellConstraints();
    4
    jpanel1.setLayout(formlayout1);
    4
    jpanel1.setLayout(formlayout1);
    4
    panel.setLayout(formlayout1);
    Differences
    Expression1Expression2Difference
    jpanel1panelVARIABLE_NAME_MISMATCH
    4
    panel.setLayout(formlayout1);
    5
    jpanel1.add(alarmComboBox, cc.xy(1, 1));
    5
    jpanel1.add(alarmComboBox, cc.xy(1, 1));
    8
    panel.add(rUntilDate, cc.xy(1, 1));
    Differences
    Expression1Expression2Difference
    alarmComboBoxrUntilDateVARIABLE_NAME_MISMATCH
    javax.swing.JComboBoxjavax.swing.JRadioButtonSUBCLASS_TYPE_MISMATCH
    jpanel1panelVARIABLE_NAME_MISMATCH
    8
    panel.add(rUntilDate, cc.xy(1, 1));
    6
    alarmButton.setActionCommand("Customize...");
    6
    alarmButton.setActionCommand("Customize...");
    6
    rUntilDate.setActionCommand("until");
    Differences
    Expression1Expression2Difference
    "Customize...""until"LITERAL_VALUE_MISMATCH
    alarmButtonrUntilDateVARIABLE_NAME_MISMATCH
    javax.swing.JButtonjavax.swing.JRadioButtonSUBCLASS_TYPE_MISMATCH
    6
    rUntilDate.setActionCommand("until");
    7
    alarmButton.setText("Customize...");
    7
    alarmButton.setText("Customize...");
    5
    rUntilDate.setText("Until ");
    Differences
    Expression1Expression2Difference
    "Customize...""Until "LITERAL_VALUE_MISMATCH
    alarmButtonrUntilDateVARIABLE_NAME_MISMATCH
    javax.swing.JButtonjavax.swing.JRadioButtonSUBCLASS_TYPE_MISMATCH
    5
    rUntilDate.setText("Until ");
                                                                                
    7
    rUntilDate.addActionListener(this);
    8
    jpanel1.add(alarmButton, cc.xy(3, 1));
    8
    jpanel1.add(alarmButton, cc.xy(3, 1));
    9
    panel.add(endDatePicker, cc.xy(2, 1));
    Differences
    Expression1Expression2Difference
    alarmButtonendDatePickerVARIABLE_NAME_MISMATCH
    javax.swing.JButtonorg.columba.calendar.ui.comp.DatePickerSUBCLASS_TYPE_MISMATCH
    32LITERAL_VALUE_MISMATCH
    jpanel1panelVARIABLE_NAME_MISMATCH
    9
    panel.add(endDatePicker, cc.xy(2, 1));
    9
    return jpanel1;
    9
    return jpanel1;
    10
    return panel;
    Differences
    Expression1Expression2Difference
    jpanel1panelVARIABLE_NAME_MISMATCH
    10
    return panel;
    Precondition Violations (0)
    Row Violation