CloneSet3552


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
37230.979compilation_unit
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
13711
plugins/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/MoveElementsOperation.java
23611
plugins/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/MoveResourceElementsOperation.java
Clone Instance
1
Line Count
37
Source Line
11
Source File
plugins/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/MoveElementsOperation.java

/*******************************************************************************
 * Copyright (c) 2000, 2006 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.jdt.internal.core;

import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.internal.core.util.Messages;

/**
 * This operation moves elements from their current
 * container to a specified destination container, optionally renaming the
 * elements.
 * A move operation is equivalent to a copy operation, where
 * the source elements are deleted after the copy.
 * <p>This operation can be used for reorganizing elements within the same container.
 *
 * @see CopyElementsOperation
 */
public class MoveElementsOperation extends CopyElementsOperation {
/**
 * When executed, this operation will move the given elements to the given containers.
 */
public MoveElementsOperation(IJavaElement[] elementsToMove, IJavaElement[] destContainers, boolean force) {
        super(elementsToMove, destContainers, force);
}

/**
 * Returns the <code>String</code> to use as the main task name
 * for progress monitoring.
 */
protected String getMainTaskName() {
        return Messages.operation_moveElementProgress;
}

/**
 * @see CopyElementsOperation#isMove()
 */
protected boolean isMove() {
        return true;
}
}




Clone Instance
2
Line Count
36
Source Line
11
Source File
plugins/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/MoveResourceElementsOperation.java

/*******************************************************************************
 * Copyright (c) 2000, 2006 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.jdt.internal.core;

import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.internal.core.util.Messages;

/**
 * This operation moves resources (package fragments and compilation units) from their current
 * container to a specified destination container, optionally renaming the
 * elements.
 * A move resource operation is equivalent to a copy resource operation, where
 * the source resources are deleted after the copy.
 * <p>This operation can be used for reorganizing resources within the same container.
 *
 * @see CopyResourceElementsOperation
 */
public class MoveResourceElementsOperation extends CopyResourceElementsOperation {
/**
 * When executed, this operation will move the given elements to the given containers.
 */
public MoveResourceElementsOperation(IJavaElement[] elementsToMove, IJavaElement[] destContainers, boolean force) {
        super(elementsToMove, destContainers, force);
}

/**
 * @see MultiOperation
 */
protected String getMainTaskName() {
        return Messages.operation_moveResourceProgress;
}

/**
 * @see CopyResourceElementsOperation#isMove()
 */
protected boolean isMove() {
        return true;
}
}




Clone AbstractionParameter Count: 3Parameter Bindings

/*******************************************************************************
 * Copyright (c) 2000, 2006 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.jdt.internal.core;

import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.internal.core.util.Messages;

/**
 * This operation moves elements from their current
 * container to a specified destination container, optionally renaming the
 * elements.
 * A move operation is equivalent to a copy operation, where
 * the source elements are deleted after the copy.
 * <p>This operation can be used for reorganizing elements within the same container.
 *
 * @see CopyElementsOperation
 */
/**
 * This operation moves resources (package fragments and compilation units) from their current
 * container to a specified destination container, optionally renaming the
 * elements.
 * A move resource operation is equivalent to a copy resource operation, where
 * the source resources are deleted after the copy.
 * <p>This operation can be used for reorganizing resources within the same container.
 *
 * @see CopyResourceElementsOperation
 */
public class [[#variableb14e9fa0]]extends [[#variableb14e9f60]]{
  /**
   * When executed, this operation will move the given elements to the given containers.
   */
  public [[#variableb14e9fa0]](IJavaElement[] elementsToMove, IJavaElement[] destContainers, boolean force) {
    super(elementsToMove, destContainers, force);
  }

  /**
   * Returns the <code>String</code> to use as the main task name
   * for progress monitoring.
   */
  /**
   * @see MultiOperation
   */
  protected String getMainTaskName() {
    return Messages. [[#variableb14e9e80]];
  }

  /**
   * @see CopyElementsOperation#isMove()
   */
  /**
   * @see CopyResourceElementsOperation#isMove()
   */
  protected boolean isMove() {
    return true;
  }
}


 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#b14e9fa0]]
MoveElementsOperation 
12[[#b14e9fa0]]
MoveResourceElementsOperation 
21[[#b14e9f60]]
CopyElementsOperation 
22[[#b14e9f60]]
CopyResourceElementsOperation 
31[[#b14e9e80]]
operation_moveElementProgress 
32[[#b14e9e80]]
operation_moveResourceProgress