boolean result = true;
// This refactoring depends on the following dialect API methods:
// getUpdateSQL
result = result && dialect.supportsUpdate();
result = result && dialect.supportsAddColumn();
return result;
boolean result = true;
// This refactoring depends on the following dialect API methods:
// getUpdateSQL
result = result && dialect.supportsUpdate();
// getColumnAddSQL
result = result && dialect.supportsAddColumn();
return result;
Clone fragments detected by clone detection tool
File path: /sql12/plugins/refactoring/src/net/sourceforge/squirrel_sql/plugins/refactoring/commands/MergeTableCommand.java
|
|
File path: /sql12/plugins/refactoring/src/net/sourceforge/squirrel_sql/plugins/refactoring/commands/MergeColumnCommand.java
|
Method name: boolean isRefactoringSupportedForDialect(HibernateDialect)
|
|
Method name: boolean isRefactoringSupportedForDialect(HibernateDialect)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | boolean result = true;↵ | | 1 | boolean result = true;↵
|
2 | // This refactoring depends on the following dialect API methods:↵ | | 2 | // This refactoring depends on the following dialect API methods:↵
|
3 | // getUpdateSQL↵ | | 3 | // getUpdateSQL↵
|
4 | result = result && dialect.supportsUpdate();↵ | | 4 | result = result && dialect.supportsUpdate();↵
|
5 | ↵ | | 5 | // getColumnAddSQL↵
|
6 | result = result && dialect.supportsAddColumn();↵ | | 6 | result = result && dialect.supportsAddColumn();↵
|
|
7 | return result; | | 7 | return result;
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 16 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 4 |
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 1 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
1 | boolean result = true; | | 1 | boolean result = true; |
2 | result = result && dialect.supportsUpdate(); | | 2 | result = result && dialect.supportsUpdate(); |
3 | result = result && dialect.supportsAddColumn(); | | 3 | result = result && dialect.supportsAddColumn(); |
4 | return result; | | 4 | return result; |
Precondition Violations (0)
Row |
Violation |