CloneSet2344


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
11230.976class_body_declaration
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
111722
plugins/org.eclipse.jdt.ui/core extension/org/eclipse/jdt/internal/corext/template/java/CompilationUnitCompletion.java
211741
plugins/org.eclipse.jdt.ui/core extension/org/eclipse/jdt/internal/corext/template/java/CompilationUnitCompletion.java
Clone Instance
1
Line Count
11
Source Line
722
Source File
plugins/org.eclipse.jdt.ui/core extension/org/eclipse/jdt/internal/corext/template/java/CompilationUnitCompletion.java

        /**
         * Returns all local arrays in the order that they appear.
         * 
         * @return all local arrays
         */
        public LocalVariable[] findLocalArrays() {
                List arrays = new ArrayList();

                for (ListIterator iterator = fLocalVariables.listIterator(fLocalVariables.size()); iterator.hasPrevious();) {
                        LocalVariable localVariable = (LocalVariable) iterator.previous();

                        if (localVariable.isArray())
                                arrays.add(localVariable);
                }

                return (LocalVariable[]) arrays.toArray(new LocalVariable[arrays.size()]);
        }


Clone Instance
2
Line Count
11
Source Line
741
Source File
plugins/org.eclipse.jdt.ui/core extension/org/eclipse/jdt/internal/corext/template/java/CompilationUnitCompletion.java

        /**
         * Returns all local variables implementing
         * <code>java.util.Collection</code> in the order that they appear.
         * 
         * @return all local <code>Collection</code>s
         */
        public LocalVariable[] findLocalCollections() {
                List collections = new ArrayList();

                for (ListIterator iterator = fLocalVariables.listIterator(fLocalVariables.size()); iterator.hasPrevious();) {
                        LocalVariable localVariable = (LocalVariable) iterator.previous();

                        if (localVariable.isCollection())
                                collections.add(localVariable);
                }

                return (LocalVariable[]) collections.toArray(new LocalVariable[collections.size()]);
        }


Clone AbstractionParameter Count: 3Parameter Bindings

/**
         * Returns all local arrays in the order that they appear.
         * 
         * @return all local arrays
         */
/**
         * Returns all local variables implementing
         * <code>java.util.Collection</code> in the order that they appear.
         * 
         * @return all local <code>Collection</code>s
         */
public LocalVariable[]  [[#variablea70a3a40]]() {
  List  [[#variablea70a32e0]]= new ArrayList();
  for (ListIterator iterator = fLocalVariables.listIterator(fLocalVariables.size()); iterator.hasPrevious();) {
    LocalVariable localVariable = (LocalVariable) iterator.previous();
    if (localVariable. [[#variablea70a39c0]]())
       [[#variablea70a32e0]].add(localVariable);
  }
  return (LocalVariable[])  [[#variablea70a32e0]].toArray(new LocalVariable[ [[#variablea70a32e0]].size()]);
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#a70a3a40]]
findLocalArrays 
12[[#a70a3a40]]
findLocalCollections 
21[[#a70a32e0]]
arrays 
22[[#a70a32e0]]
collections 
31[[#a70a39c0]]
isArray 
32[[#a70a39c0]]
isCollection