org.eclipse.jdt.internal.core
Class DeleteElementsOperation
java.lang.Object
org.eclipse.jdt.internal.core.JavaModelOperation
org.eclipse.jdt.internal.core.MultiOperation
org.eclipse.jdt.internal.core.DeleteElementsOperation
- All Implemented Interfaces:
- IWorkspaceRunnable, org.eclipse.core.runtime.IProgressMonitor
public class DeleteElementsOperation
- extends MultiOperation
This operation deletes a collection of elements (and
all of their children).
If an element does not exist, it is ignored.
NOTE: This operation only deletes elements contained within leaf resources -
that is, elements within compilation units. To delete a compilation unit or
a package, etc (which have an actual resource), a DeleteResourcesOperation
should be used.
Fields inherited from interface org.eclipse.core.runtime.IProgressMonitor |
UNKNOWN |
Methods inherited from class org.eclipse.jdt.internal.core.JavaModelOperation |
beginTask, done, executeNestedOperation, getJavaModel, getResultElements, hasModifiedResource, internalWorked, isCanceled, isReadOnly, newJavaElementDelta, run, runOperation, setCanceled, setTaskName, subTask, worked |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DeleteElementsOperation
public DeleteElementsOperation(IJavaElement[] elementsToDelete,
boolean force)
- When executed, this operation will delete the given elements. The elements
to delete cannot be
null
or empty, and must be contained within a
compilation unit.