File path: /apache-ant-1.7.0/src/org/apache/tools/ant/types/PatternSet.java | File path: /apache-ant-1.7.0/src/org/apache/tools/ant/types/PatternSet.java | |||
Method name: void setIncludes(String)
|
Method name: void setExcludes(String)
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | if (includes != null && includes.length() > 0) {↵ | 1 | if (excludes != null && excludes.length() > 0) {↵ | |
2 | StringTokenizer tok = new StringTokenizer(includes, ", ", false);↵ | 2 | StringTokenizer tok = new StringTokenizer(excludes, ", ", false);↵ | |
3 | while (tok.hasMoreTokens()) {↵ | 3 | while (tok.hasMoreTokens()) {↵ | |
4 | createInclude().setName(tok.nextToken());↵ | 4 | createExclude().setName(tok.nextToken());↵ | |
5 | }↵ | 5 | }↵ | |
6 | } | 6 |
| |
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.2 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 8 |
Number of mapped statements | 4 |
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) | 0.7 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
3 | if (includes != null && includes.length() > 0) |
| 3 | if (excludes != null && excludes.length() > 0) | |||||||||||||
4 | StringTokenizer tok = new StringTokenizer(includes, ", ", false); |
| 4 | StringTokenizer tok = new StringTokenizer(excludes, ", ", false); | |||||||||||||
5 | while (tok.hasMoreTokens()) | 5 | while (tok.hasMoreTokens()) | ||||||||||||||
6 | createInclude().setName(tok.nextToken()); |
| 6 | createExclude().setName(tok.nextToken()); |
Row | Violation |
---|