File path: /sql12/app/src/net/sourceforge/squirrel_sql/client/session/properties/GeneralSessionPropertiesPanel.java | File path: /sql12/plugins/syntax/src/net/sourceforge/squirrel_sql/plugins/syntax/SyntaxPreferencesPanel.java | |||
Method name: void initialize(IApplication, ISession)
|
Method name: void initialize(IApplication, ISession)
|
|||
Number of AST nodes: 6 | Number of AST nodes: 5 | |||
1 | if (app == null)↵ | 1 | if (app == null)↵ | |
2 | {↵ | 2 | {↵ | |
3 | throw new IllegalArgumentException("Null IApplication passed");↵ | 3 | throw new IllegalArgumentException("Null IApplication passed");↵ | |
4 | }↵ | 4 | }↵ | |
5 | if (session == null)↵ | 5 | if (session == null)↵ | |
6 | {↵ | 6 | {↵ | |
7 | throw new IllegalArgumentException("Null ISession passed");↵ | 7 | throw new IllegalArgumentException("Null ISession passed");↵ | |
8 | }↵ | 8 | }↵ | |
9 | _props = session.getProperties();↵ | |||
10 | _myPanel.loadData(_props); | 9 | _myPanel.loadData(_prefs); | |
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 different classes |
Number of node comparisons | 15 |
Number of mapped statements | 5 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 15.7 |
Clone type | Type 3 |
ID | Statement | ID | Statement | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | if (app == null) | 1 | if (app == null) | |||||||||||||||||||
2 | throw new IllegalArgumentException("Null IApplication passed"); | 2 | throw new IllegalArgumentException("Null IApplication passed"); | |||||||||||||||||||
3 | if (session == null) | 3 | if (session == null) | |||||||||||||||||||
4 | throw new IllegalArgumentException("Null ISession passed"); | 4 | throw new IllegalArgumentException("Null ISession passed"); | |||||||||||||||||||
5 | _props = session.getProperties(); |
| | |||||||||||||||||||
6 | _myPanel.loadData(_props); |
| 5 | _myPanel.loadData(_prefs); |
Row | Violation |
---|---|
1 | Unmatched statement _props=session.getProperties(); cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted |
2 | Type net.sourceforge.squirrel_sql.client.session.properties.SessionProperties of variable _props does not match with type net.sourceforge.squirrel_sql.plugins.syntax.SyntaxPreferences of variable _prefs |
3 | Expression _myPanel cannot be unified with expression _myPanel , because common superclass javax.swing.JPanel does not declare member(s) void loadData(net.sourceforge.squirrel_sql.client.session.properties.SessionProperties) , void loadData(net.sourceforge.squirrel_sql.plugins.syntax.SyntaxPreferences) |