VerticalPanel modPanel = new VerticalPanel(); JPanel renamePanel = new JPanel(new BorderLayout(5, 0)); JLabel labelmod = new JLabel(JMeterUtils.getResString("modddn")); // $NON-NLS-1$ labelmod.setLabelFor(modddn); renamePanel.add(labelmod, BorderLayout.WEST); renamePanel.add(modddn, BorderLayout.CENTER); JPanel rename2Panel = new JPanel(new BorderLayout(5, 0)); JLabel labelmod2 = new JLabel(JMeterUtils.getResString("newdn")); // $NON-NLS-1$ labelmod2.setLabelFor(newdn); rename2Panel.add(labelmod2, BorderLayout.WEST); rename2Panel.add(newdn, BorderLayout.CENTER); modPanel.add(renamePanel); modPanel.add(rename2Panel); return modPanel;
VerticalPanel cbindPanel = new VerticalPanel(); JPanel cBPanel = new JPanel(new BorderLayout(5, 0)); JLabel cBlabel0 = new JLabel(JMeterUtils.getResString("entrydn")); // $NON-NLS-1$ cBlabel0.setLabelFor(comparedn); cBPanel.add(cBlabel0, BorderLayout.WEST); cBPanel.add(comparedn, BorderLayout.CENTER); cbindPanel.add(cBPanel); JPanel cBPanel1 = new JPanel(new BorderLayout(5, 0)); JLabel cBlabel1 = new JLabel(JMeterUtils.getResString("comparefilt")); // $NON-NLS-1$ cBlabel1.setLabelFor(comparefilt); cBPanel1.add(cBlabel1, BorderLayout.WEST); cBPanel1.add(comparefilt, BorderLayout.CENTER); cbindPanel.add(cBPanel1); return cbindPanel;
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/ldap/config/gui/LdapExtConfigGui.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/ldap/config/gui/LdapExtConfigGui.java
Method name: JPanel createModdnPanel() Method name: JPanel createComparePanel()
Number of AST nodes: 14 Number of AST nodes: 14
1
VerticalPanel modPanel = new VerticalPanel();
1
VerticalPanel cbindPanel = new VerticalPanel();
2
		JPanel renamePanel = new JPanel(new BorderLayout(5, 0));
2
		JPanel cBPanel = new JPanel(new BorderLayout(5, 0));
3
		JLabel labelmod = new JLabel(JMeterUtils.getResString("modddn")); // $NON-NLS-1$
3
		JLabel cBlabel0 = new JLabel(JMeterUtils.getResString("entrydn")); // $NON-NLS-1$
4
		labelmod.setLabelFor(modddn);
4
		cBlabel0.setLabelFor(comparedn);
5
		renamePanel.add(labelmod, BorderLayout.WEST);
5
		cBPanel.add(cBlabel0, BorderLayout.WEST);
6
		renamePanel.add(modddn, BorderLayout.CENTER);
6
		cBPanel.add(comparedn, BorderLayout.CENTER);
7
		cbindPanel.add(cBPanel);
7
		JPanel rename2Panel = new JPanel(new BorderLayout(5, 0));
8
		JPanel cBPanel1 = new JPanel(new BorderLayout(5, 0));
8
		JLabel labelmod2 = new JLabel(JMeterUtils.getResString("newdn")); // $NON-NLS-1$
9
		JLabel cBlabel1 = new JLabel(JMeterUtils.getResString("comparefilt")); // $NON-NLS-1$
9
		labelmod2.setLabelFor(newdn);
10
		cBlabel1.setLabelFor(
10
		rename2
11
comparefilt);
11
Panel.add(labelmod2, BorderLayout.WEST);
12
		cBPanel1.add(cBlabel1, BorderLayout.WEST);
12
		rename2Panel.add(newdn, BorderLayout.CENTER);
13
		cBPanel1.add(comparefilt, BorderLayout.CENTER);
13
		modPanel.add(renamePanel);
14
		cbindPanel.add(cBPanel1);
14
		modPanel.add(rename2Panel);
15
		return modPanel;
15
		return cbindPanel;
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 declared in the same class
Number of node comparisons79
  1. {Refactorable}
    Mapping Summary
    Number of mapped statements14
    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.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    VerticalPanel modPanel = new VerticalPanel();
    1
    VerticalPanel modPanel = new VerticalPanel();
    1
    VerticalPanel cbindPanel = new VerticalPanel();
    Differences
    Expression1Expression2Difference
    modPanelcbindPanelVARIABLE_NAME_MISMATCH
    1
    VerticalPanel cbindPanel = new VerticalPanel();
    2
    JPanel renamePanel = new JPanel(new BorderLayout(5, 0));
    2
    JPanel renamePanel = new JPanel(new BorderLayout(5, 0));
    2
    JPanel cBPanel = new JPanel(new BorderLayout(5, 0));
    Differences
    Expression1Expression2Difference
    renamePanelcBPanelVARIABLE_NAME_MISMATCH
    2
    JPanel cBPanel = new JPanel(new BorderLayout(5, 0));
    3
    JLabel labelmod = new JLabel(JMeterUtils.getResString("modddn"));
    3
    JLabel labelmod = new JLabel(JMeterUtils.getResString("modddn"));
    3
    JLabel cBlabel0 = new JLabel(JMeterUtils.getResString("entrydn"));
    Differences
    Expression1Expression2Difference
    labelmodcBlabel0VARIABLE_NAME_MISMATCH
    "modddn""entrydn"LITERAL_VALUE_MISMATCH
    3
    JLabel cBlabel0 = new JLabel(JMeterUtils.getResString("entrydn"));
    4
    labelmod.setLabelFor(modddn);
    4
    labelmod.setLabelFor(modddn);
    4
    cBlabel0.setLabelFor(comparedn);
    Differences
    Expression1Expression2Difference
    modddncomparednVARIABLE_NAME_MISMATCH
    labelmodcBlabel0VARIABLE_NAME_MISMATCH
    4
    cBlabel0.setLabelFor(comparedn);
    5
    renamePanel.add(labelmod, BorderLayout.WEST);
    5
    renamePanel.add(labelmod, BorderLayout.WEST);
    5
    cBPanel.add(cBlabel0, BorderLayout.WEST);
    Differences
    Expression1Expression2Difference
    labelmodcBlabel0VARIABLE_NAME_MISMATCH
    renamePanelcBPanelVARIABLE_NAME_MISMATCH
    5
    cBPanel.add(cBlabel0, BorderLayout.WEST);
    6
    renamePanel.add(modddn, BorderLayout.CENTER);
    6
    renamePanel.add(modddn, BorderLayout.CENTER);
    6
    cBPanel.add(comparedn, BorderLayout.CENTER);
    Differences
    Expression1Expression2Difference
    modddncomparednVARIABLE_NAME_MISMATCH
    renamePanelcBPanelVARIABLE_NAME_MISMATCH
    6
    cBPanel.add(comparedn, BorderLayout.CENTER);
    7
    JPanel rename2Panel = new JPanel(new BorderLayout(5, 0));
    7
    JPanel rename2Panel = new JPanel(new BorderLayout(5, 0));
    8
    JPanel cBPanel1 = new JPanel(new BorderLayout(5, 0));
    Differences
    Expression1Expression2Difference
    rename2PanelcBPanel1VARIABLE_NAME_MISMATCH
    8
    JPanel cBPanel1 = new JPanel(new BorderLayout(5, 0));
    8
    JLabel labelmod2 = new JLabel(JMeterUtils.getResString("newdn"));
    8
    JLabel labelmod2 = new JLabel(JMeterUtils.getResString("newdn"));
    9
    JLabel cBlabel1 = new JLabel(JMeterUtils.getResString("comparefilt"));
    Differences
    Expression1Expression2Difference
    labelmod2cBlabel1VARIABLE_NAME_MISMATCH
    "newdn""comparefilt"LITERAL_VALUE_MISMATCH
    9
    JLabel cBlabel1 = new JLabel(JMeterUtils.getResString("comparefilt"));
    9
    labelmod2.setLabelFor(newdn);
    9
    labelmod2.setLabelFor(newdn);
    10
    cBlabel1.setLabelFor(comparefilt);
    Differences
    Expression1Expression2Difference
    newdncomparefiltVARIABLE_NAME_MISMATCH
    labelmod2cBlabel1VARIABLE_NAME_MISMATCH
    10
    cBlabel1.setLabelFor(comparefilt);
    10
    rename2Panel.add(labelmod2, BorderLayout.WEST);
    10
    rename2Panel.add(labelmod2, BorderLayout.WEST);
    11
    cBPanel1.add(cBlabel1, BorderLayout.WEST);
    Differences
    Expression1Expression2Difference
    labelmod2cBlabel1VARIABLE_NAME_MISMATCH
    rename2PanelcBPanel1VARIABLE_NAME_MISMATCH
    11
    cBPanel1.add(cBlabel1, BorderLayout.WEST);
    11
    rename2Panel.add(newdn, BorderLayout.CENTER);
    11
    rename2Panel.add(newdn, BorderLayout.CENTER);
    12
    cBPanel1.add(comparefilt, BorderLayout.CENTER);
    Differences
    Expression1Expression2Difference
    newdncomparefiltVARIABLE_NAME_MISMATCH
    rename2PanelcBPanel1VARIABLE_NAME_MISMATCH
    12
    cBPanel1.add(comparefilt, BorderLayout.CENTER);
    12
    modPanel.add(renamePanel);
    12
    modPanel.add(renamePanel);
    7
    cbindPanel.add(cBPanel);
    Differences
    Expression1Expression2Difference
    renamePanelcBPanelVARIABLE_NAME_MISMATCH
    modPanelcbindPanelVARIABLE_NAME_MISMATCH
    7
    cbindPanel.add(cBPanel);
    13
    modPanel.add(rename2Panel);
    13
    modPanel.add(rename2Panel);
    13
    cbindPanel.add(cBPanel1);
    Differences
    Expression1Expression2Difference
    rename2PanelcBPanel1VARIABLE_NAME_MISMATCH
    modPanelcbindPanelVARIABLE_NAME_MISMATCH
    13
    cbindPanel.add(cBPanel1);
    14
    return modPanel;
    14
    return modPanel;
    14
    return cbindPanel;
    Differences
    Expression1Expression2Difference
    modPanelcbindPanelVARIABLE_NAME_MISMATCH
    14
    return cbindPanel;
    Precondition Violations (0)
    Row Violation