CloneSet841


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
26220.984class_body_declaration
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
126376
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/LazyJavaCompletionProposal.java
226335
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/text/java/CompletionProposalCollector.java
Clone Instance
1
Line Count
26
Source Line
376
Source File
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/LazyJavaCompletionProposal.java

        protected int computeRelevance() {
                final int baseRelevance = fProposal.getRelevance() * 16;
                switch (fProposal.getKind()) {
                        case CompletionProposal.PACKAGE_REF:
                                return baseRelevance + 0;
                        case CompletionProposal.LABEL_REF:
                                return baseRelevance + 1;
                        case CompletionProposal.KEYWORD:
                                return baseRelevance + 2;
                        case CompletionProposal.TYPE_REF:
                        case CompletionProposal.ANONYMOUS_CLASS_DECLARATION:
                                return baseRelevance + 3;
                        case CompletionProposal.METHOD_REF:
                        case CompletionProposal.METHOD_NAME_REFERENCE:
                        case CompletionProposal.METHOD_DECLARATION:
                        case CompletionProposal.ANNOTATION_ATTRIBUTE_REF:
                                return baseRelevance + 4;
                        case CompletionProposal.POTENTIAL_METHOD_DECLARATION:
                                return baseRelevance + 4
                                                         /* + 99 */
                                                        ;
                        case CompletionProposal.FIELD_REF:
                                return baseRelevance + 5;
                        case CompletionProposal.LOCAL_VARIABLE_REF:
                        case CompletionProposal.VARIABLE_DECLARATION:
                                return baseRelevance + 6;
                        default:
                                return baseRelevance;
                      }
        }


Clone Instance
2
Line Count
26
Source Line
335
Source File
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/text/java/CompletionProposalCollector.java

        /**
         * Computes the relevance for a given <code>CompletionProposal</code>.
         * <p>
         * Subclasses may replace, but usually should not need to.
         * </p>
         * @param proposal the proposal to compute the relevance for
         * @return the relevance for <code>proposal</code>
         */
        protected int computeRelevance(CompletionProposal proposal) {
                final int baseRelevance = proposal.getRelevance() * 16;
                switch (proposal.getKind()) {
                        case CompletionProposal.PACKAGE_REF:
                                return baseRelevance + 0;
                        case CompletionProposal.LABEL_REF:
                                return baseRelevance + 1;
                        case CompletionProposal.KEYWORD:
                                return baseRelevance + 2;
                        case CompletionProposal.TYPE_REF:
                        case CompletionProposal.ANONYMOUS_CLASS_DECLARATION:
                                return baseRelevance + 3;
                        case CompletionProposal.METHOD_REF:
                        case CompletionProposal.METHOD_NAME_REFERENCE:
                        case CompletionProposal.METHOD_DECLARATION:
                        case CompletionProposal.ANNOTATION_ATTRIBUTE_REF:
                                return baseRelevance + 4;
                        case CompletionProposal.POTENTIAL_METHOD_DECLARATION:
                                return baseRelevance + 4
                                                         /* + 99 */
                                                        ;
                        case CompletionProposal.FIELD_REF:
                                return baseRelevance + 5;
                        case CompletionProposal.LOCAL_VARIABLE_REF:
                        case CompletionProposal.VARIABLE_DECLARATION:
                                return baseRelevance + 6;
                        default:
                                return baseRelevance;
                      }
        }


Clone AbstractionParameter Count: 2Parameter Bindings

/**
         * Computes the relevance for a given <code>CompletionProposal</code>.
         * <p>
         * Subclasses may replace, but usually should not need to.
         * </p>
         * @param proposal the proposal to compute the relevance for
         * @return the relevance for <code>proposal</code>
         */
protected int computeRelevance [[#variable642ef720]]{
  final int baseRelevance = [[#variable642ef3a0]].getRelevance() * 16;
  switch ( [[#variable642ef3a0]].getKind()) {
    case CompletionProposal.PACKAGE_REF:
      return baseRelevance + 0;
    case CompletionProposal.LABEL_REF:
      return baseRelevance + 1;
    case CompletionProposal.KEYWORD:
      return baseRelevance + 2;
    case CompletionProposal.TYPE_REF:
    case CompletionProposal.ANONYMOUS_CLASS_DECLARATION:
      return baseRelevance + 3;
    case CompletionProposal.METHOD_REF:
    case CompletionProposal.METHOD_NAME_REFERENCE:
    case CompletionProposal.METHOD_DECLARATION:
    case CompletionProposal.ANNOTATION_ATTRIBUTE_REF:
      return baseRelevance + 4;
    case CompletionProposal.POTENTIAL_METHOD_DECLARATION:
      return baseRelevance + 4
                              /* + 99 */
                              ;
    case CompletionProposal.FIELD_REF:
      return baseRelevance + 5;
    case CompletionProposal.LOCAL_VARIABLE_REF:
    case CompletionProposal.VARIABLE_DECLARATION:
      return baseRelevance + 6;
    default:
      return baseRelevance;
  }
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#642ef720]]
(CompletionProposal proposal) 
12[[#642ef720]]
() 
21[[#642ef3a0]]
proposal 
22[[#642ef3a0]]
fProposal