File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/modifier/AnchorModifier.java | File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/modifier/AnchorModifier.java | |||
Method name: void addFormUrls(Document, HTTPSampleResult, HTTPSamplerBase, List)
|
Method name: void addFramesetUrls(Document, HTTPSampleResult, HTTPSamplerBase, List)
|
|||
Number of AST nodes: 8 | Number of AST nodes: 7 | |||
1 | while (iter.hasNext()) {↵ | |||
2 | HTTPSamplerBase newUrl = (HTTPSamplerBase) iter.next();↵ | |||
3 | ↵ | 1 | HTTPSamplerBase newUrl = HtmlParsingUtils.createUrlFromAnchor(↵ | |
2 | hrefStr, new URL(result.getURL(), base));↵ | |||
4 | newUrl.setMethod(HTTPConstants.POST);↵ | 3 | newUrl.setMethod(HTTPConstants.GET);↵ | |
5 | if (log.isDebugEnabled()) {↵ | 4 | if (log.isDebugEnabled()) {↵ | |
6 | log.debug("Potential Form match: " + newUrl.toString());↵ | 5 | log.debug("Potential <frame src> match: " + newUrl↵ | |
7 | }↵ | |||
8 | ↵ | 6 | );↵ | |
7 | }↵ | |||
9 | if (HtmlParsingUtils.isAnchorMatched(newUrl, config)) {↵ | 8 | if (HtmlParsingUtils.isAnchorMatched(newUrl, config)) {↵ | |
10 | log.debug("Matched!");↵ | 9 | log.debug("Matched!");↵ | |
11 | potentialLinks.add(newUrl);↵ | 10 | potentialLinks.add(newUrl);↵ | |
12 | }↵ | |||
13 | } | 11 | } | |
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.3 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 26 |
Number of mapped statements | 6 |
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) | 5.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7 | HTTPSamplerBase newUrl = (HTTPSamplerBase)iter.next(); |
| 14 | HTTPSamplerBase newUrl = HtmlParsingUtils.createUrlFromAnchor(hrefStr, new URL(result.getURL(), base)); | ||||||||||
8 | newUrl.setMethod(HTTPConstants.POST); |
| 15 | newUrl.setMethod(HTTPConstants.GET); | ||||||||||
9 | if (log.isDebugEnabled()) | 16 | if (log.isDebugEnabled()) | |||||||||||
10 | log.debug("Potential Form match: " + newUrl.toString()); |
| | |||||||||||
|
| 17 | log.debug("Potential <frame src> match: " + newUrl); | |||||||||||
11 | if (HtmlParsingUtils.isAnchorMatched(newUrl, config)) | 18 | if (HtmlParsingUtils.isAnchorMatched(newUrl, config)) | |||||||||||
12 | log.debug("Matched!"); | 19 | log.debug("Matched!"); | |||||||||||
13 | potentialLinks.add(newUrl); | 20 | potentialLinks.add(newUrl); |
Row | Violation |
---|---|
1 | Unmatched statement log.debug("Potential Form match: " + newUrl.toString()); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
2 | Unmatched statement log.debug("Potential <frame src> match: " + newUrl); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |