if (s_log.isDebugEnabled()) {
s_log.debug("View source before formatting: "+
buf.toString());
}
source = formatter.reformat(buf.toString());
if (s_log.isDebugEnabled())
{
s_log.debug("View source before formatting: " + buf.toString());
}
_ta.setText(formatter.reformat(buf.toString()));
Clone fragments detected by clone detection tool
File path: /sql12/plugins/oracle/src/net/sourceforge/squirrel_sql/plugins/oracle/tab/OracleSourceTab.java
|
|
File path: /sql12/plugins/postgres/src/net/sourceforge/squirrel_sql/plugins/postgres/tab/PostgresSourceTab.java
|
Method name: void load(ISession, PreparedStatement)
|
|
Method name: void load(ISession, PreparedStatement)
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | if (s_log.isDebugEnabled()) {↵ | | 1 | if (s_log.isDebugEnabled())↵
|
2 | ↵ | | |
|
| | | 2 | {↵
|
3 | s_log.debug("View source before formatting: "+↵ | | 3 | s_log.debug("View source before formatting: "↵
|
4 | buf.toString());↵ | | |
|
5 | }↵ | | |
|
6 | source = ↵ | | 4 | + buf.toString());↵
|
| | | 5 | }↵
|
7 | formatter.reformat(buf.toString()); | | 6 | _ta.setText(formatter.reformat(buf.toString()));
|
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.1 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 5 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 1.8 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
26 | if (s_log.isDebugEnabled()) | | 18 | if (s_log.isDebugEnabled()) |
27 | s_log.debug("View source before formatting: " + buf.toString()); | | 19 | s_log.debug("View source before formatting: " + buf.toString()); |
| | | 20 | _ta.setText(formatter.reformat(buf.toString())); |
28 | source = formatter.reformat(buf.toString()); | | | |
Precondition Violations (0)
Row |
Violation |