super(app, rsrc);
if (prefs == null)
{
throw new IllegalArgumentException("WebServicePreferences == null");
}
_prefs = prefs;
_plugin = plugin;
super(app, rsrc);
if (prefs == null)
{
throw new IllegalArgumentException("WebServicePreferences == null");
}
_prefs = prefs;
_plugin = plugin;
Clone fragments detected by clone detection tool
File path: /sql12/plugins/sqlval/src/net/sourceforge/squirrel_sql/plugins/sqlval/action/ConnectAction.java
|
|
File path: /sql12/plugins/sqlval/src/net/sourceforge/squirrel_sql/plugins/sqlval/action/DisconnectAction.java
|
Method name: void ConnectAction(IApplication, Resources, WebServicePreferences, SQLValidatorPlugin)
|
|
Method name: void DisconnectAction(IApplication, Resources, WebServicePreferences, SQLValidatorPlugin)
|
Number of AST nodes: 5
|
|
Number of AST nodes: 5
|
|
1 | super(app, rsrc);↵ | | 1 | super(app, rsrc);↵
|
2 | if (prefs == null)↵ | | 2 | if (prefs == null)↵
|
3 | {↵ | | 3 | {↵
|
4 | throw new IllegalArgumentException("WebServicePreferences == null");↵ | | 4 | throw new IllegalArgumentException("WebServicePreferences == null");↵
|
5 | }↵ | | 5 | }↵
|
6 | _prefs = prefs;↵ | | 6 | _prefs = prefs;↵
|
7 | _plugin = plugin; | | 7 | _plugin = plugin;
|
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.1 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 8 |
-
{Non-refactorable}
Mapping Summary
Number of mapped statements | 5 |
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) | 1.1 |
Clone type | Type 1 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
1 | super(app, rsrc); | | 1 | super(app, rsrc); |
2 | if (prefs == null) | | 2 | if (prefs == null) |
3 | throw new IllegalArgumentException("WebServicePreferences == null"); | | 3 | throw new IllegalArgumentException("WebServicePreferences == null"); |
4 | _prefs = prefs; | | 4 | _prefs = prefs; |
5 | _plugin = plugin; | | 5 | _plugin = plugin; |
Precondition Violations (2)
Row |
Violation |
1 | Super constructor call super(app,rsrc); cannot be extracted from constructor |
2 | Super constructor call super(app,rsrc); cannot be extracted from constructor |