if (s_log.isDebugEnabled())
{
s_log.debug("Table " + doi.getSimpleName() + " appears to be a regular table");
}
if (result != columnType) {
if (s_log.isDebugEnabled()) {
s_log.debug("Converting type code for column "+columnName+
". Original column type code and name were Types.NULL and "+columnTypeName+
"; New type code is "+JDBCTypeMapper.getJdbcTypeName(result));
}
}
Clone fragments detected by clone detection tool
File path: /sql12/plugins/db2/src/net/sourceforge/squirrel_sql/plugins/db2/tab/TableSourceTab.java
|
|
File path: /sql12/fw/src/net/sourceforge/squirrel_sql/fw/datasetviewer/ResultSetDataSet.java
|
Method name: boolean isMQT()
|
|
Method name: int fixColumnType(String, int, String)
|
Number of AST nodes: 2
|
|
Number of AST nodes: 3
|
|
| | | 1 | if (result != columnType) {↵
|
1 | if (s_log.isDebugEnabled())↵ | | 2 | if (s_log.isDebugEnabled())↵
|
2 | {↵ | | 3 | {↵
|
3 | s_log.debug("Table " + doi.getSimpleName() + " appears to be a ↵ | | 4 | s_log.debug("Converting type code for column "+columnName+↵
|
| | | 5 | ". Original column type code and name were Types.NULL and "+columnTypeName+↵
|
4 | regular table");↵ | | 6 | "; New type code is "+JDBCTypeMapper.getJdbcTypeName(resul↵
|
5 | ↵ | | 7 | t));↵
|
| | | 8 | } ↵
|
6 | } | | 9 | }
|
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 |
Number of node comparisons | 4 |
-
{Non-refactorable}
Mapping Summary
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) | 74.2 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
9 | if (s_log.isDebugEnabled()) | | 7 | if (s_log.isDebugEnabled()) |
10 | s_log.debug("Table " + doi.getSimpleName() + " appears to be a regular table"); | | 8 | s_log.debug("Converting type code for column " + columnName + ". Original column type code and name were Types.NULL and " + columnTypeName + "; New type code is " + JDBCTypeMapper.getJdbcTypeName(result)); |
Precondition Violations (1)
Row |
Violation |
1 | The refactoring of the clones is infeasible, because classes net.sourceforge.squirrel_sql.plugins.db2.tab.TableSourceTab and net.sourceforge.squirrel_sql.fw.datasetviewer.ResultSetDataSet do not have a common superclass |