File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/timers/ConstantThroughputTimer.java | File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/reporters/Summariser.java | |||
Method name: long calculateDelay()
|
Method name: void threadStarted()
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | synchronized (threadGroupsInfoMap) {↵ | 1 | synchronized (accumulators) {↵ | |
2 | groupInfo = (ThroughputInfo)threadGroupsInfoMap.get(group);↵ | 2 | ↵ | |
3 | ↵ | 3 | myTotals = (Totals) accumulators.get(myName);↵ | |
4 | if (groupInfo == null) {↵ | 4 | if (myTotals == null){↵ | |
5 | groupInfo = new ThroughputInfo();↵ | 5 | ↵ | |
6 | threadGroupsInfoMap.put(group, groupInfo↵ | 6 | myTotals = new Totals();↵ | |
7 | );↵ | 7 | accumulators.put(myName, myTotals);↵ | |
8 | }↵ | 8 | ↵ | |
9 | ↵ | 9 | }↵ | |
10 | } | 10 |
| |
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.2 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 11 |
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 2 |
Number of unmapped statements in the second code fragment | 2 |
Time elapsed for statement mapping (ms) | 0.8 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
18 | if (groupInfo == null) |
| 4 | if (myTotals == null) | |||||||||||||||||||||
|
| 5 | myTotals = new Totals(); | ||||||||||||||||||||||
19 | groupInfo = new ThroughputInfo(); |
| | ||||||||||||||||||||||
20 | threadGroupsInfoMap.put(group, groupInfo); |
| 6 | accumulators.put(myName, myTotals); |
Row | Violation |
---|---|
1 | Type org.apache.jmeter.timers.ConstantThroughputTimer.ThroughputInfo of variable groupInfo does not match with type org.apache.jmeter.reporters.Summariser.Totals of variable myTotals |
2 | Unmatched statement myTotals=new Totals(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
3 | Unmatched statement groupInfo=new ThroughputInfo(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
4 | Type org.apache.jmeter.threads.ThreadGroup of variable group does not match with type java.lang.String of variable myName |
5 | Type java.util.Map of variable threadGroupsInfoMap does not match with type java.util.Hashtable of variable accumulators |