if (imComboBox.getSelectedIndex() == 2) destModel .addInstantMessaging(new InstantMessagingModel( imTextField.getText(), InstantMessagingModel.TYPE_YAHOO)); else if (imComboBox.getSelectedIndex() == 3) destModel.addInstantMessaging(new InstantMessagingModel( imTextField.getText(), InstantMessagingModel.TYPE_MSN)); else if (imComboBox.getSelectedIndex() == 4) destModel.addInstantMessaging(new InstantMessagingModel( imTextField.getText(), InstantMessagingModel.TYPE_ICQ));
if (telephoneComboBox.getSelectedIndex() == 14) destModel.addPhone(new PhoneModel(telephoneTextField.getText(), PhoneModel.TYPE_RADIO)); else if (telephoneComboBox.getSelectedIndex() == 15) destModel.addPhone(new PhoneModel(telephoneTextField.getText(), PhoneModel.TYPE_TELEX)); else if (telephoneComboBox.getSelectedIndex() == 16) destModel.addPhone(new PhoneModel(telephoneTextField.getText(), PhoneModel.TYPE_TTY));
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/contact/src/main/java/org/columba/addressbook/gui/dialog/contact/ContactEditorDialog.java File path: /columba-1.4-src/contact/src/main/java/org/columba/addressbook/gui/dialog/contact/ContactEditorDialog.java
Method name: void fillIMModel(JTextField, JComboBox, ContactModel) Method name: void fillPhoneModel(JTextField, JComboBox, ContactModel)
Number of AST nodes: 6 Number of AST nodes: 6
1
if (imComboBox.getSelectedIndex() == 2)
1
if (telephoneComboBox.getSelectedIndex() == 14)
2
				destModel
2
				destModel
3
						.addInstantMessaging(new InstantMessagingModel(
4
								imTextField.getText(),
3
.addPhone(new PhoneModel(telephoneTextField.getText(),
5
								InstantMessagingModel.TYPE_YAHOO));
4
						PhoneModel.TYPE_RADIO));
6
			else if (imComboBox.getSelectedIndex() == 3)
5
			else if (telephoneComboBox.getSelectedIndex() == 15)
7
				destModel.addInstantMessaging(new InstantMessagingModel(
6
				destModel.add
8
						imTextField.getText(), InstantMessaging
7
Phone(new PhoneModel(telephoneTextField.getText(),
9
Model.TYPE_MSN));
8
						PhoneModel.TYPE_TELEX));
10
			else if (imComboBox.getSelectedIndex() == 4)
9
			else if (telephoneComboBox.getSelectedIndex() == 16)
11
				destModel.addInstantMessaging(new InstantMessagingModel(
10
				destModel.add
12
						imTextField.getText(), InstantMessaging
11
Phone(new PhoneModel(telephoneTextField.getText(),
13
Model.TYPE_ICQ));
12
						PhoneModel.TYPE_TTY));
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
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 comparisons0