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: void queryCacheMiss(String, String)
|
Method name: void queryCachePut(String, String)
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | queryCacheMissCount++;↵ | 1 | queryCachePutCount++;↵ | |
2 | if (hql!=null) {↵ | 2 | if (hql!=null) {↵ | |
3 | QueryStatistics qs = getQueryStatistics(hql);↵ | 3 | QueryStatistics qs = getQueryStatistics(hql);↵ | |
4 | qs.cacheMissCount++;↵ | 4 | qs.cachePutCount++;↵ | |
5 | }↵ | 5 | }↵ | |
6 | SecondLevelCacheStatistics slcs = getSecondLevelCacheStatistics(regionName);↵ | 6 | SecondLevelCacheStatistics slcs = getSecondLevelCacheStatistics(regionName);↵ | |
7 | slcs.missCount++; | 7 | slcs.putCount++; | |
See real code fragment | See real code fragment |
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 declared in the same class |
Number of node comparisons | 16 |
Number of mapped statements | 6 |
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.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | queryCacheMissCount++; |
| 1 | queryCachePutCount++; | ||||||||||||
2 | if (hql != null) | 2 | if (hql != null) | |||||||||||||
3 | QueryStatistics qs = getQueryStatistics(hql); | 3 | QueryStatistics qs = getQueryStatistics(hql); | |||||||||||||
4 | qs.cacheMissCount++; |
| 4 | qs.cachePutCount++; | ||||||||||||
5 | SecondLevelCacheStatistics slcs = getSecondLevelCacheStatistics(regionName); | 5 | SecondLevelCacheStatistics slcs = getSecondLevelCacheStatistics(regionName); | |||||||||||||
6 | slcs.missCount++; |
| 6 | slcs.putCount++; |
Row | Violation |
---|---|
1 | Expression queryCacheMissCount is a field being modified, and thus it cannot be parameterized |
2 | Expression queryCachePutCount is a field being modified, and thus it cannot be parameterized |
3 | Expression qs.cacheMissCount cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression qs.cachePutCount cannot be parameterized, because it has dependencies to/from statements that will be extracted |
5 | Expression slcs.missCount cannot be parameterized, because it has dependencies to/from statements that will be extracted |
6 | Expression slcs.putCount cannot be parameterized, because it has dependencies to/from statements that will be extracted |