File path: /apache-ant-1.7.0/src/org/apache/tools/ant/Main.java | File path: /apache-ant-1.7.0/src/org/apache/tools/ant/filters/ReplaceTokens.java | |||
Method name: void startAnt(String[], Properties, ClassLoader)
|
Method name: void initialize()
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | for (Enumeration e = additionalUserProperties.keys();↵ | 1 | for (Enumeration e = ↵ | |
2 | e.hasMoreElements();) {↵ | 2 | props.keys(); e.hasMoreElements();) {↵ | |
3 | String key = (String) e.nextElement();↵ | 3 | String key = (String) e.nextElement();↵ | |
4 | String property = additionalUserProperties.getProperty(key);↵ | 4 | String value = props.getProperty(key);↵ | |
5 | definedProps.put(key, property);↵ | 5 | ↵ | |
6 | hash.put(key, value);↵ | |||
6 | } | 7 | } | |
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 |
Number of node comparisons | 18 |
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) | 2.4 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
5 | for (Enumeration e = additionalUserProperties.keys(); e.hasMoreElements(); ) |
| 23 | for (Enumeration e = props.keys(); e.hasMoreElements(); ) | |||||||||||||||||
6 | String key = (String)e.nextElement(); | 24 | String key = (String)e.nextElement(); | ||||||||||||||||||
7 | String property = additionalUserProperties.getProperty(key); |
| 25 | String value = props.getProperty(key); | |||||||||||||||||
8 | definedProps.put(key, property); |
| 26 | hash.put(key, value); |
Row | Violation |
---|---|
1 | Type java.util.Properties of variable definedProps does not match with type java.util.Hashtable of variable hash |