Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
17 | 2 | 4 | 0.969 | class_body_declaration |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 17 | 87 | plugins/org.eclipse.jdt.apt.core/src/org/eclipse/jdt/apt/core/internal/declaration/ASTBasedAnnotationElementDeclarationImpl.java |
2 | 17 | 40 | plugins/org.eclipse.jdt.apt.core/src/org/eclipse/jdt/apt/core/internal/declaration/ASTBasedMethodDeclarationImpl.java |
| ||||
public TypeMirror getReturnType() { final AnnotationTypeMemberDeclaration memberAstNode = getMemberAstNode(); final Type retType = memberAstNode.getType(); // some funny error case where the return type is missing but it's not a constructor. if (retType == null) return Factory.createErrorClassType(EMPTY_STRING); final ITypeBinding typeBinding = retType.resolveBinding(); // This is most likely the reason that we end up with an ast based implementation. if (typeBinding == null) { return Factory.createErrorClassType(retType.toString()); } else { final TypeMirror type = Factory.createTypeMirror(typeBinding, _env); if (retType == null) return Factory.createErrorClassType(retType.toString()); return type; } } |
| ||||
public TypeMirror getReturnType() { final org.eclipse.jdt.core.dom.MethodDeclaration methodAstNode = getMethodAstNode(); final Type retType = methodAstNode.getReturnType2(); // some funny error case where the return type is missing but it's not a constructor. if (retType == null) return Factory.createErrorClassType(EMPTY_STRING); final ITypeBinding typeBinding = retType.resolveBinding(); // This is most likely the reason that we end up with an ast based implementation. if (typeBinding == null) { return Factory.createErrorClassType(retType.toString()); } else { final TypeMirror type = Factory.createTypeMirror(typeBinding, _env); if (retType == null) return Factory.createErrorClassType(retType.toString()); return type; } } |
| |||
public TypeMirror getReturnType() { final [[#variable99169d80]] [[#variable99169d40]]= [[#variable99168e60]](); final Type retType = [[#variable99169d40]]. [[#variable99169ce0]](); // some funny error case where the return type is missing but it's not a constructor. if (retType == null) return Factory.createErrorClassType(EMPTY_STRING); final ITypeBinding typeBinding = retType.resolveBinding(); // This is most likely the reason that we end up with an ast based implementation. if (typeBinding == null) { return Factory.createErrorClassType(retType.toString()); } else { final TypeMirror type = Factory.createTypeMirror(typeBinding, _env); if (retType == null) return Factory.createErrorClassType(retType.toString()); return type; } } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#99169d80]] | org.eclipse.jdt.core.dom.MethodDeclaration |
1 | 2 | [[#99169d80]] | AnnotationTypeMemberDeclaration |
2 | 1 | [[#99169d40]] | methodAstNode |
2 | 2 | [[#99169d40]] | memberAstNode |
3 | 1 | [[#99168e60]] | getMethodAstNode |
3 | 2 | [[#99168e60]] | getMemberAstNode |
4 | 1 | [[#99169ce0]] | getReturnType2 |
4 | 2 | [[#99169ce0]] | getType |