String msg =
s_stringMgr.getString("SQLResultExecuterPanel.nonStickyPanel");
JOptionPane.showMessageDialog(_session.getApplication().getMainFrame(),
msg);
return;
String msg =
//i18n[syntax.findNetbeansOnly=Find is only available when the Netbeans editor is used.\nSee menu File --> New Session Properties --> Tab Syntax]
s_stringMgr.getString("syntax.findNetbeansOnly");
JOptionPane.showMessageDialog(_session.getApplication().getMainFrame(), msg);
return;
Clone fragments detected by clone detection tool
File path: /sql12/app/src/net/sourceforge/squirrel_sql/client/session/mainpanel/SQLResultExecuterPanel.java
|
|
File path: /sql12/plugins/syntax/src/net/sourceforge/squirrel_sql/plugins/syntax/netbeans/FindAction.java
|
Method name: void toggleCurrentSQLResultTabSticky()
|
|
Method name: void doActionPerformed(ISQLEntryPanel, ActionEvent)
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | String msg = ↵ | | 1 | String msg =↵
|
2 | s_stringMgr.getString("SQLResultExecuterPanel.nonStickyPanel↵ | | |
|
| | | 2 | //i18n[syntax.findNetbeansOnly=Find is only available when the Netbeans editor is used.\nSee menu File --> New Session Properties --> Tab Syntax]↵
|
3 | ");↵ | | 3 | s_stringMgr.getString("syntax.findNetbeansOnly");↵
|
4 | JOptionPane.showMessageDialog(_session.getApplication().getMainFrame(), ↵ | | 4 | JOptionPane.showMessageDialog(_session.getApplication().getMainFrame(), ↵
|
5 | msg);↵ | | 5 | msg);↵
|
6 | return; | | 6 | return;
|
See real code fragment |
|
See real code fragment |
Summary
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.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 9 |
-
{Non-refactorable}
Mapping Summary
Number of mapped statements | 3 |
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) | 0.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
11 | String msg = s_stringMgr.getString("SQLResultExecuterPanel.nonStickyPanel"); | | 2 | String msg = s_stringMgr.getString("syntax.findNetbeansOnly"); |
12 | JOptionPane.showMessageDialog(_session.getApplication().getMainFrame(), msg); | | 3 | JOptionPane.showMessageDialog(_session.getApplication().getMainFrame(), msg); |
13 | return; | | 4 | return; |
Precondition Violations (3)
Row |
Violation |
1 | Conditional return; |
2 | Conditional return; |
3 | The refactoring of the clones is infeasible, because classes net.sourceforge.squirrel_sql.client.session.mainpanel.SQLResultExecuterPanel and net.sourceforge.squirrel_sql.plugins.syntax.netbeans.FindAction do not have a common superclass |