File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Expand.java | File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Expand.java | |||
Method name: void extractFile(FileUtils, File, File, InputStream, String, Date, boolean, FileNameMapper)
|
Method name: void extractFile(FileUtils, File, File, InputStream, String, Date, boolean, FileNameMapper)
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | for (int w = 0; w < incls.length; w++) {↵ | 1 | for (int w = 0; w < excls.length; w++) {↵ | |
2 | String pattern = incls[w]↵ | 2 | String pattern = excls[w]↵ | |
3 | .replace('/', File.separatorChar)↵ | 3 | .replace('/', File.separatorChar)↵ | |
4 | .replace('\\', File.separatorChar);↵ | 4 | .replace('\\', File.separatorChar);↵ | |
5 | if (pattern.endsWith(File.separator)) {↵ | 5 | if (pattern.endsWith(File.separator)) {↵ | |
6 | pattern += "**";↵ | 6 | pattern += "**";↵ | |
7 | }↵ | 7 | ↵ | |
8 | }↵ | |||
8 | includePatterns.add(pattern);↵ | 9 | excludePatterns.add(pattern);↵ | |
9 | } | 10 | } | |
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.3 |
Clones location | Clones are in the same method |
Number of node comparisons | 16 |
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.4 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
11 | for (int w = 0; w < incls.length; w++) |
| 18 | for (int w = 0; w < excls.length; w++) | ||||||||||
12 | String pattern = incls[w].replace('/', File.separatorChar).replace('\\', File.separatorChar); |
| 19 | String pattern = excls[w].replace('/', File.separatorChar).replace('\\', File.separatorChar); | ||||||||||
13 | if (pattern.endsWith(File.separator)) | 20 | if (pattern.endsWith(File.separator)) | |||||||||||
14 | pattern += "**"; | 21 | pattern += "**"; | |||||||||||
15 | includePatterns.add(pattern); |
| 22 | excludePatterns.add(pattern); |
Row | Violation |
---|