String result = null;
try {
result = con.getSQLMetaData().getDatabaseProductName();
} catch (SQLException e) {
e.printStackTrace();
}
return result;
Date d = null;
try {
d = format.parse(value);
} catch (ParseException pe) {
/* Do nothing */
}
return d;
Clone fragments detected by clone detection tool
File path: /sql12/test/mockobjects/net/sourceforge/squirrel_sql/client/session/MockSession.java
|
|
File path: /sql12/plugins/dataimport/src/net/sourceforge/squirrel_sql/plugins/dataimport/util/DateUtils.java
|
Method name: String getDatabaseProductName()
|
|
Method name: Date parse(DateFormat, String)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | String result = null;↵ | | |
|
2 | try {↵ | | |
|
3 | result = con.getSQLMetaData().getDatabaseProductName();↵ | | |
|
4 | ↵ | | 1 | Date d = null;↵
|
| | | 2 | try {↵
|
| | | 3 | d = format.parse(value);↵
|
5 | } catch (SQLException e) {↵ | | 4 | } catch (ParseException pe) {↵
|
6 | e.printStackTrace();↵ | | |
|
7 | }↵ | | |
|
8 | ↵ | | 5 | /* Do nothing */↵
|
| | | 6 | }↵
|
9 | return result; | | 7 | return d;
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are in different classes |
Number of node comparisons | 5 |