CloneSet839


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
20210.971class_body_declaration
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
120162
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingContentProvider.java
220245
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/StandardJavaElementContentProvider.java
Clone Instance
1
Line Count
20
Source Line
162
Source File
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingContentProvider.java

        protected Object[] getPackageFragmentRoots(IJavaProject project) throws JavaModelException {
                if ( !project.getProject().isOpen())
                        return NO_CHILDREN;

                IPackageFragmentRoot[] roots = project.getPackageFragmentRoots();
                List list = new ArrayList(roots.length);
                // filter out package fragments that correspond to projects and
                // replace them with the package fragments directly
                for (int i = 0; i < roots.length; i++) {
                        IPackageFragmentRoot root = roots[i];
                        if ( !root.isExternal()) {
                                Object[] children = root.getChildren();
                                for (int k = 0; k < children.length; k++)
                                        list.add(children[k]);
                        }
                        else if (hasChildren(root)) {
                                list.add(root);
                             }
                }
                return concatenate(list.toArray(), project.getNonJavaResources());
        }


Clone Instance
2
Line Count
20
Source Line
245
Source File
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/StandardJavaElementContentProvider.java

        /**
         * Note: This method is for internal use only. Clients should not call this method.
         */
        protected Object[] getPackageFragmentRoots(IJavaProject project) throws JavaModelException {
                if ( !project.getProject().isOpen())
                        return NO_CHILDREN;

                IPackageFragmentRoot[] roots = project.getPackageFragmentRoots();
                List list = new ArrayList(roots.length);
                // filter out package fragments that correspond to projects and
                // replace them with the package fragments directly
                for (int i = 0; i < roots.length; i++) {
                        IPackageFragmentRoot root = roots[i];
                        if (isProjectPackageFragmentRoot(root)) {
                                Object[] children = root.getChildren();
                                for (int k = 0; k < children.length; k++)
                                        list.add(children[k]);
                        }
                        else if (hasChildren(root)) {
                                list.add(root);
                             }
                }
                return concatenate(list.toArray(), project.getNonJavaResources());
        }


Clone AbstractionParameter Count: 1Parameter Bindings

/**
         * Note: This method is for internal use only. Clients should not call this method.
         */
protected Object[] getPackageFragmentRoots(IJavaProject project) throws JavaModelException {
  if ( !project.getProject().isOpen())
    return NO_CHILDREN;
  IPackageFragmentRoot[] roots = project.getPackageFragmentRoots();
  List list = new ArrayList(roots.length);
  // filter out package fragments that correspond to projects and
  // replace them with the package fragments directly
  for (int i = 0; i < roots.length; i++) {
    IPackageFragmentRoot root = roots[i];
    if ( [[#variablec1bc28e0]]) {
      Object[] children = root.getChildren();
      for (int k = 0; k < children.length; k++)
        list.add(children[k]);
    }
    else
      if (hasChildren(root)) {
        list.add(root);
      }
  }
  return concatenate(list.toArray(), project.getNonJavaResources());
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#c1bc28e0]]
isProjectPackageFragmentRoot(root) 
12[[#c1bc28e0]]
!root.isExternal()