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 updateComponents(boolean)
|
Method name: void updateComponents(boolean)
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | if (it.hasNext()) {↵ | 1 | if (it.hasNext()) {↵ | |
2 | PhoneModel m = (PhoneModel) it.next();↵ | 2 | IEmailModel m = (IEmailModel) it.next();↵ | |
3 | fillPhoneView(m, telephoneComboBox1, telephoneTextField1);↵ | 3 | fillEmailView(m, emailComboBox3, emailTextField3);↵ | |
4 | }↵ | 4 | }↵ | |
5 | if (it.hasNext()) {↵ | 5 | if (it.hasNext()) {↵ | |
6 | PhoneModel m = (PhoneModel) it.next();↵ | 6 | IEmailModel m = (IEmailModel) it.next();↵ | |
7 | fillPhoneView(m, telephoneComboBox2, telephoneTextField2);↵ | 7 | fillEmailView(m, emailComboBox4, emailTextField4);↵ | |
8 | } | 8 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.3 |
Clones location | Clones are in the same method |
Number of node comparisons | 29 |
Number of mapped statements | 4 |
Number of unmapped statements in the first code fragment | 2 |
Number of unmapped statements in the second code fragment | 2 |
Time elapsed for statement mapping (ms) | 66.6 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
40 | if (it.hasNext()) | 36 | if (it.hasNext()) | |||||||||||||||||
|
| 37 | IEmailModel m = (IEmailModel)it.next(); | |||||||||||||||||
41 | PhoneModel m = (PhoneModel)it.next(); |
| | |||||||||||||||||
42 | fillPhoneView(m, telephoneComboBox1, telephoneTextField1); |
| 38 | fillEmailView(m, emailComboBox4, emailTextField4); | ||||||||||||||||
43 | if (it.hasNext()) | 33 | if (it.hasNext()) | |||||||||||||||||
|
| 34 | IEmailModel m = (IEmailModel)it.next(); | |||||||||||||||||
44 | PhoneModel m = (PhoneModel)it.next(); |
| | |||||||||||||||||
45 | fillPhoneView(m, telephoneComboBox2, telephoneTextField2); |
| 35 | fillEmailView(m, emailComboBox3, emailTextField3); |
Row | Violation |
---|---|
1 | Unmatched statement IEmailModel m=(IEmailModel)it.next(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
2 | Unmatched statement PhoneModel m=(PhoneModel)it.next(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
3 | Expression fillPhoneView(m,telephoneComboBox1,telephoneTextField1) is a void method call, and thus it cannot be parameterized |
4 | Expression fillEmailView(m,emailComboBox4,emailTextField4) is a void method call, and thus it cannot be parameterized |
5 | Type org.columba.addressbook.model.PhoneModel of variable m does not match with type org.columba.addressbook.model.IEmailModel of variable m |
6 | Unmatched statement IEmailModel m=(IEmailModel)it.next(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
7 | Unmatched statement PhoneModel m=(PhoneModel)it.next(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
8 | Expression fillPhoneView(m,telephoneComboBox2,telephoneTextField2) is a void method call, and thus it cannot be parameterized |
9 | Expression fillEmailView(m,emailComboBox3,emailTextField3) is a void method call, and thus it cannot be parameterized |
10 | Type org.columba.addressbook.model.PhoneModel of variable m does not match with type org.columba.addressbook.model.IEmailModel of variable m |