if (toType == Byte.TYPE)
return new Byte(number.byteValue());
if (toType == Short.TYPE)
return new Short(number.shortValue());
if (toType == Integer.TYPE)
return new Integer(number.intValue());
if (toType == Long.TYPE)
return new Long(number.longValue());
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/bsh/Primitive.java
|
|
File path: /jEdit-4.2/src/bsh/Primitive.java
|
Method name: Object castWrapper(Class, Object)
|
|
Method name: Object castWrapper(Class, Object)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | if (toType == Byte.TYPE)↵ | | 1 | if (toType == Integer.TYPE)↵
|
2 | return new Byte(number.byteValue());↵ | | 2 | return new Integer(number.intValue());↵
|
3 | if (toType == Short.TYPE)↵ | | 3 | if (toType == Long.TYPE)↵
|
4 | return new Short(number.shortValue()); | | 4 | return new Long(number.longValue());
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 1.0 |
Clones location | Clones are in the same method |
Number of node comparisons | 4 |