CloneSet1393


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
33230.969class_body_declarations[3]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
133177
plugins/org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/base/JavaStatusContext.java
233235
plugins/org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/base/JavaStatusContext.java
Clone Instance
1
Line Count
33
Source Line
177
Source File
plugins/org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/base/JavaStatusContext.java

        /**
         * Creates an status entry context for the given compilation unit.
         * 
         * @param cunit the compilation unit containing the error
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *      context cannot be created
         */
        public static RefactoringStatusContext create(ICompilationUnit cunit) {
                return create(cunit, (ISourceRange) null);
        }

        /**
         * Creates an status entry context for the given compilation unit and source range.
         * 
         * @param cunit the compilation unit containing the error
         * @param range the source range that has caused the error or 
         *  <code>null</code> if the source range is unknown
         * @return the status entry context or <code>null</code> if the
         *      context cannot be created
         */
        public static RefactoringStatusContext create(ICompilationUnit cunit, ISourceRange range) {
                if (cunit == null)
                        return null;
                return new CompilationUnitSourceContext(cunit, range);
        }

        /**
         * Creates an status entry context for the given compilation unit and AST node.
         * 
         * @param cunit the compilation unit containing the error
         * @param node an astNode denoting the source range that has caused the error
         * 
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *      context cannot be created
         */
        public static RefactoringStatusContext create(ICompilationUnit cunit, ASTNode node) {
                ISourceRange range = null;
                if (node != null)
                        range = new SourceRange(node.getStartPosition(), node.getLength());
                return create(cunit, range);
        }


Clone Instance
2
Line Count
33
Source Line
235
Source File
plugins/org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/base/JavaStatusContext.java

        /**
         * Creates an status entry context for the given class file.
         * 
         * @param classFile the class file containing the error
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *  context cannot be created
         */
        public static RefactoringStatusContext create(IClassFile classFile) {
                return create(classFile, (ISourceRange) null);
        }

        /**
         * Creates an status entry context for the given class file and source range.
         * 
         * @param classFile the class file containing the error
         * @param range the source range that has caused the error or 
         *  <code>null</code> if the source range is unknown
         * @return the status entry context or <code>null</code> if the
         *  context cannot be created
         */
        public static RefactoringStatusContext create(IClassFile classFile, ISourceRange range) {
                if (classFile == null)
                        return null;
                return new ClassFileSourceContext(classFile, range);
        }

        /**
         * Creates an status entry context for the given class file and AST node.
         * 
         * @param classFile the class file containing the error
         * @param node an astNode denoting the source range that has caused the error
         * 
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *  context cannot be created
         */
        public static RefactoringStatusContext create(IClassFile classFile, ASTNode node) {
                ISourceRange range = null;
                if (node != null)
                        range = new SourceRange(node.getStartPosition(), node.getLength());
                return create(classFile, range);
        }


Clone AbstractionParameter Count: 3Parameter Bindings

/**
         * Creates an status entry context for the given class file.
         * 
         * @param classFile the class file containing the error
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *  context cannot be created
         */
/**
         * Creates an status entry context for the given compilation unit.
         * 
         * @param cunit the compilation unit containing the error
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *      context cannot be created
         */
public static RefactoringStatusContext create( [[#variableb314d260]]  [[#variableb314d1c0]]) {
  return create( [[#variableb314d1c0]], (ISourceRange) null);
}

/**
         * Creates an status entry context for the given class file and source range.
         * 
         * @param classFile the class file containing the error
         * @param range the source range that has caused the error or 
         *  <code>null</code> if the source range is unknown
         * @return the status entry context or <code>null</code> if the
         *  context cannot be created
         */
/**
         * Creates an status entry context for the given compilation unit and source range.
         * 
         * @param cunit the compilation unit containing the error
         * @param range the source range that has caused the error or 
         *  <code>null</code> if the source range is unknown
         * @return the status entry context or <code>null</code> if the
         *      context cannot be created
         */
public static RefactoringStatusContext create( [[#variableb314d260]]  [[#variableb314d1c0]], ISourceRange range) {
  if ( [[#variableb314d1c0]]== null)
    return null;
  return new [[#variablec128a780]]( [[#variableb314d1c0]], range);
}

/**
         * Creates an status entry context for the given class file and AST node.
         * 
         * @param classFile the class file containing the error
         * @param node an astNode denoting the source range that has caused the error
         * 
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *  context cannot be created
         */
/**
         * Creates an status entry context for the given compilation unit and AST node.
         * 
         * @param cunit the compilation unit containing the error
         * @param node an astNode denoting the source range that has caused the error
         * 
         * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the
         *      context cannot be created
         */
public static RefactoringStatusContext create( [[#variableb314d260]]  [[#variableb314d1c0]], ASTNode node) {
  ISourceRange range = null;
  if (node != null)
    range = new SourceRange(node.getStartPosition(), node.getLength());
  return create( [[#variableb314d1c0]], range);
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#b314d260]]
IClassFile 
12[[#b314d260]]
ICompilationUnit 
21[[#b314d1c0]]
classFile 
22[[#b314d1c0]]
cunit 
31[[#c128a780]]
ClassFileSourceContext 
32[[#c128a780]]
CompilationUnitSourceContext