File path: /sql12/plugins/dbcopy/src/net/sourceforge/squirrel_sql/plugins/dbcopy/CopyProgressMonitor.java | File path: /sql12/plugins/dbcopy/src/net/sourceforge/squirrel_sql/plugins/dbcopy/CopyProgressMonitor.java | |||
Method name: void handleError(ErrorEvent)
|
Method name: void handleError(ErrorEvent)
|
|||
Number of AST nodes: 8 | Number of AST nodes: 8 | |||
1 | if (e.getType() == ErrorEvent.SETUP_AUTO_COMMIT_TYPE) {↵ | 1 | if (e.getType() == ErrorEvent.RESTORE_AUTO_COMMIT_TYPE) {↵ | |
2 | String exMsg = "";↵ | 2 | String exMsg = "";↵ | |
3 | if (e.getException() != null) {↵ | 3 | if (e.getException() != null) {↵ | |
4 | exMsg = e.getException().getMessage();↵ | 4 | exMsg = e.getException().getMessage();↵ | |
5 | } ↵ | 5 | }↵ | |
6 | String message = ↵ | 6 | String message = ↵ | |
7 | getMessage("CopyProgressMonitor.setupAutoCommitException",↵ | 7 | getMessage("CopyProgressMonitor.restoreAutoCommitException", ↵ | |
8 | exMsg);↵ | 8 | exMsg);↵ | |
9 | String title = ↵ | 9 | String title =↵ | |
10 | getMessage("CopyProgressMonitor.setupAutoCommitExceptionTitle");↵ | 10 | getMessage("CopyProgressMonitor.restoreAutoCommitExceptionTitle");↵ | |
11 | int messageType = JOptionPane.ERROR_MESSAGE;↵ | 11 | int messageType = JOptionPane.ERROR_MESSAGE;↵ | |
12 | showMessageDialog(message, title, messageType);↵ | 12 | showMessageDialog(message, title, messageType); ↵ | |
13 | } | 13 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are in the same method |
Number of node comparisons | 40 |
Number of mapped statements | 8 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 5.5 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
3 | if (e.getType() == ErrorEvent.SETUP_AUTO_COMMIT_TYPE) |
| 11 | if (e.getType() == ErrorEvent.RESTORE_AUTO_COMMIT_TYPE) | ||||||||||
4 | String exMsg = ""; | 12 | String exMsg = ""; | |||||||||||
5 | if (e.getException() != null) | 13 | if (e.getException() != null) | |||||||||||
6 | exMsg = e.getException().getMessage(); | 14 | exMsg = e.getException().getMessage(); | |||||||||||
7 | String message = getMessage("CopyProgressMonitor.setupAutoCommitException", exMsg); |
| 15 | String message = getMessage("CopyProgressMonitor.restoreAutoCommitException", exMsg); | ||||||||||
8 | String title = getMessage("CopyProgressMonitor.setupAutoCommitExceptionTitle"); |
| 16 | String title = getMessage("CopyProgressMonitor.restoreAutoCommitExceptionTitle"); | ||||||||||
9 | int messageType = JOptionPane.ERROR_MESSAGE; | 17 | int messageType = JOptionPane.ERROR_MESSAGE; | |||||||||||
10 | showMessageDialog(message, title, messageType); | 18 | showMessageDialog(message, title, messageType); |
Row | Violation |
---|