type = "java/lang/Integer";
meth = "intValue";
} else if (returnType.equals("Z") ) {
type = "java/lang/Boolean";
meth = "booleanValue";
type = "java/lang/Byte";
meth = "byteValue";
} else if (returnType.equals("I") ) {
type = "java/lang/Integer";
meth = "intValue";
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/bsh/ClassGeneratorUtil.java
|
|
File path: /jEdit-4.2/src/bsh/ClassGeneratorUtil.java
|
Method name: void generateReturnCode(String, CodeVisitor)
|
|
Method name: void generateReturnCode(String, CodeVisitor)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | type = "java/lang/Integer";↵ | | 1 | type = "java/lang/Byte";↵
|
2 | meth = "intValue";↵ | | 2 | meth = "byteValue";↵
|
3 | } else if (returnType.equals("Z") ) {↵ | | 3 | } else if (returnType.equals("I") ) {↵
|
4 | type = "java/lang/Boolean";↵ | | 4 | type = "java/lang/Integer";↵
|
5 | meth = "booleanValue"; | | 5 | meth = "intValue";
|
See real code fragment |
|
See real code fragment |
Summary
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.0 |
Clones location | Clones are in the same method |
Number of node comparisons | 4 |
-
{Non-refactorable}
Mapping Summary
Number of mapped statements | 2 |
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 |
12 | type = "java/lang/Integer"; | | 9 | type = "java/lang/Byte"; |
13 | meth = "intValue"; | | 10 | meth = "byteValue"; |
Precondition Violations (1)
Row |
Violation |
1 | Clone fragment #1 returns variables type, meth , while Clone fragment #2 returns variables type, meth |