File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/stat/StatisticsImpl.java | File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/stat/StatisticsImpl.java | |||
Method name: EntityStatistics getEntityStatistics(String)
|
Method name: QueryStatistics getQueryStatistics(String)
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | EntityStatistics es = (EntityStatistics) entityStatistics.get(entityName);↵ | 1 | QueryStatistics qs = (QueryStatistics) queryStatistics.get(queryString);↵ | |
2 | if (es==null) {↵ | 2 | if (qs==null) {↵ | |
3 | es = new EntityStatistics(entityName);↵ | 3 | qs = new QueryStatistics(queryString);↵ | |
4 | entityStatistics.put(entityName, es);↵ | 4 | queryStatistics.put(queryString, qs);↵ | |
5 | }↵ | 5 | }↵ | |
6 | return es; | 6 | return qs; | |
See real code fragment | See real code fragment |
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 declared in the same class |
Number of node comparisons | 13 |
Number of mapped statements | 5 |
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) | 1.6 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | EntityStatistics es = (EntityStatistics)entityStatistics.get(entityName); |
| 1 | QueryStatistics qs = (QueryStatistics)queryStatistics.get(queryString); | |||||||||||||||||||||||||
2 | if (es == null) |
| 2 | if (qs == null) | |||||||||||||||||||||||||
3 | es = new EntityStatistics(entityName); |
| 3 | qs = new QueryStatistics(queryString); | |||||||||||||||||||||||||
4 | entityStatistics.put(entityName, es); |
| 4 | queryStatistics.put(queryString, qs); | |||||||||||||||||||||||||
5 | return es; |
| 5 | return qs; |
Row | Violation |
---|