File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/NetRexxC.java | File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/NetRexxC.java | |||
Method name: void init()
|
Method name: void init()
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | if ((p = getProject().getProperty("ant.netrexxc.utf8")) != null) {↵ | 1 | if ((p = getProject().getProperty("ant.netrexxc.time")) != null) {↵ | |
2 | this.utf8 = Project.toBoolean(p);↵ | 2 | this.time = Project.toBoolean(p);↵ | |
3 | }↵ | 3 | }↵ | |
4 | if ((p = getProject().getProperty("ant.netrexxc.verbose")) != null) {↵ | 4 | if ((p = getProject().getProperty("ant.netrexxc.trace")) != null) {↵ | |
5 | setVerbose(p);↵ | 5 | setTrace(p);↵ | |
6 | }↵ | 6 | }↵ | |
7 | if ((p = getProject().getProperty("ant.netrexxc.suppressMethodArgumentNotUsed")) != null) {↵ | 7 | if ((p = getProject().getProperty("ant.netrexxc.utf8")) != null) {↵ | |
8 | this.suppressMethodArgumentNotUsed = Project.toBoolean(p);↵ | 8 | this.utf8 = Project.toBoolean(p);↵ | |
9 | } | 9 |
| |
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) | 1.2 |
Clones location | Clones are in the same method |
Number of node comparisons | 27 |
Number of mapped statements | 6 |
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.8 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
50 | if ((p = getProject().getProperty("ant.netrexxc.utf8")) != null) | 50 | if ((p = getProject().getProperty("ant.netrexxc.utf8")) != null) | |||||||||||||||
51 | this.utf8 = Project.toBoolean(p); | 51 | this.utf8 = Project.toBoolean(p); | |||||||||||||||
52 | if ((p = getProject().getProperty("ant.netrexxc.verbose")) != null) |
| 48 | if ((p = getProject().getProperty("ant.netrexxc.trace")) != null) | ||||||||||||||
53 | setVerbose(p); |
| 49 | setTrace(p); | ||||||||||||||
54 | if ((p = getProject().getProperty("ant.netrexxc.suppressMethodArgumentNotUsed")) != null) |
| 46 | if ((p = getProject().getProperty("ant.netrexxc.time")) != null) | ||||||||||||||
55 | this.suppressMethodArgumentNotUsed = Project.toBoolean(p); |
| 47 | this.time = Project.toBoolean(p); |
Row | Violation |
---|---|
1 | Expression setVerbose(p) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression setTrace(p) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression setVerbose(p) is a void method call, and thus it cannot be parameterized |
4 | Expression setTrace(p) is a void method call, and thus it cannot be parameterized |
5 | Expression this.suppressMethodArgumentNotUsed is a field being modified, and thus it cannot be parameterized |
6 | Expression this.time is a field being modified, and thus it cannot be parameterized |