File path: /sql12/app/src/net/sourceforge/squirrel_sql/client/gui/db/SQLAliasSchemaProperties.java | File path: /sql12/test/src/net/sourceforge/squirrel_sql/client/update/gui/AbstractTableModelTest.java | |||
Method name: boolean getExpectsSomeCachedData()
|
Method name: boolean isEditableColumn(int)
|
|||
Number of AST nodes: 2 | Number of AST nodes: 3 | |||
1 | if(SQLAliasSchemaDetailProperties.SCHEMA_LOADING_ID_LOAD_AND_CACHE ==_schemaDetails[i].getTable() ||↵ | |||
2 | SQLAliasSchemaDetailProperties.SCHEMA_LOADING_ID_LOAD_AND_CACHE ==_schemaDetails[i].getView() ||↵ | |||
3 | SQLAliasSchemaDetailProperties.SCHEMA_LOADING_ID_LOAD_AND_CACHE ==_schemaDetails[i].getProcedure())↵ | |||
4 | {↵ | |||
5 | ↵ | 1 | for (int i = 0; i < editableColumns.length; i++) {↵ | |
2 | if (colIdx == editableColumns[i]) {↵ | |||
6 | return true;↵ | 3 | return true;↵ | |
7 | ↵ | 4 | }↵ | |
8 | } | 5 | } | |
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 | 5 |
Number of mapped statements | 2 |
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.6 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
5 | if (SQLAliasSchemaDetailProperties.SCHEMA_LOADING_ID_LOAD_AND_CACHE == _schemaDetails[i].getTable() || SQLAliasSchemaDetailProperties.SCHEMA_LOADING_ID_LOAD_AND_CACHE == _schemaDetails[i].getView() || SQLAliasSchemaDetailProperties.SCHEMA_LOADING_ID_LOAD_AND_CACHE == _schemaDetails[i].getProcedure()) |
| 2 | if (colIdx == editableColumns[i]) | ||||||||||||||||
6 | return true; | 3 | return true; |
Row | Violation |
---|---|
1 | Not all possible execution flows end in a return statement |
2 | The refactoring of the clones is infeasible, because classes net.sourceforge.squirrel_sql.client.gui.db.SQLAliasSchemaProperties and net.sourceforge.squirrel_sql.client.update.gui.AbstractTableModelTest do not have a common superclass |