case Project.MSG_WARN:
msg.insert(0, warnColor);
msg.append(END_COLOR);
break;
case Project.MSG_INFO:
msg.insert(0, infoColor);
msg.append(END_COLOR);
break;
case Project.MSG_VERBOSE:
msg.insert(0, verboseColor);
msg.append(END_COLOR);
break;
case Project.MSG_DEBUG:
case Project.MSG_ERR:
msg.insert(0, errColor);
msg.append(END_COLOR);
break;
case Project.MSG_WARN:
msg.insert(0, warnColor);
msg.append(END_COLOR);
break;
case Project.MSG_INFO:
msg.insert(0, infoColor);
msg.append(END_COLOR);
break;
case Project.MSG_VERBOSE:
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/listener/AnsiColorLogger.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/listener/AnsiColorLogger.java
|
Method name: void printMessage(String, PrintStream, int)
|
|
Method name: void printMessage(String, PrintStream, int)
|
Number of AST nodes: 13
|
|
Number of AST nodes: 13
|
|
| | | 1 | case Project.MSG_ERR:↵
|
| | | 2 | msg.insert(0, errColor);↵
|
| | | 3 | msg.append(END_COLOR);↵
|
| | | 4 | break;↵
|
1 | case Project.MSG_WARN:↵ | | 5 | case Project.MSG_WARN:↵
|
2 | msg.insert(0, warnColor);↵ | | 6 | msg.insert(0, warnColor);↵
|
3 | msg.append(END_COLOR);↵ | | 7 | msg.append(END_COLOR);↵
|
4 | break;↵ | | 8 | break;↵
|
5 | case Project.MSG_INFO:↵ | | 9 | case Project.MSG_INFO:↵
|
6 | msg.insert(0, infoColor);↵ | | 10 | msg.insert(0, infoColor);↵
|
7 | msg.append(END_COLOR);↵ | | 11 | msg.append(END_COLOR);↵
|
8 | break;↵ | | 12 | break;↵
|
9 | case Project.MSG_VERBOSE:↵ | | 13 | case Project.MSG_VERBOSE:
|
10 | msg.insert(0, verboseColor);↵ | | | |
11 | msg.append(END_COLOR);↵ | | | |
12 | break;↵ | | | |
13 | case Project.MSG_DEBUG: | | | |
See real code fragment |
|
See real code fragment |
Summary
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.0 |
Clones location | Clones are in the same method |
Number of node comparisons | 109 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 13 |
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.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
11 | case Project.MSG_WARN: | | 11 | case Project.MSG_WARN: |
12 | msg.insert(0, warnColor); | | 12 | msg.insert(0, warnColor); |
13 | msg.append(END_COLOR); | | 13 | msg.append(END_COLOR); |
14 | break; | | 14 | break; |
15 | case Project.MSG_INFO: | | 15 | case Project.MSG_INFO: |
16 | msg.insert(0, infoColor); | | 16 | msg.insert(0, infoColor); |
17 | msg.append(END_COLOR); | | 17 | msg.append(END_COLOR); |
18 | break; | | 18 | break; |
19 | case Project.MSG_VERBOSE: | | 7 | case Project.MSG_ERR: |
20 | msg.insert(0, verboseColor); | | 8 | msg.insert(0, errColor); |
21 | msg.append(END_COLOR); | | 9 | msg.append(END_COLOR); |
22 | break; | | 10 | break; |
23 | case Project.MSG_DEBUG: | | 19 | case Project.MSG_VERBOSE: |
Precondition Violations (0)
Row |
Violation |