|
Eclipse Platform Release 3.4 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.ltk.core.refactoring.RefactoringDescriptor
org.eclipse.ltk.core.refactoring.resource.DeleteResourcesDescriptor
Refactoring descriptor for the delete resource refactoring.
An instance of this refactoring descriptor may be obtained by calling
RefactoringContribution.createDescriptor()
on a refactoring
contribution requested by invoking
RefactoringCore.getRefactoringContribution(String)
with the
refactoring id (ID
).
Note: this class is not intended to be subclassed or instantiated by clients.
Field Summary | |
static String |
ID
Refactoring id of the 'Delete Resources' refactoring (value: org.eclipse.ltk.core.refactoring.delete.resources ).
|
Fields inherited from class org.eclipse.ltk.core.refactoring.RefactoringDescriptor |
BREAKING_CHANGE, ID_UNKNOWN, MULTI_CHANGE, NONE, STRUCTURAL_CHANGE, USER_CHANGE |
Constructor Summary | |
DeleteResourcesDescriptor()
Creates a new refactoring descriptor. |
Method Summary | |
Refactoring |
createRefactoring(RefactoringStatus status)
Creates the a new refactoring instance for this refactoring descriptor. |
IPath[] |
getResourcePaths()
The resource paths to delete. |
boolean |
isDeleteContents()
true is returned if projects contents are also deleted. |
void |
setDeleteContents(boolean deleteContents)
If set to true , delete will also delete project contents. |
void |
setResourcePaths(IPath[] resourcePath)
The paths to the resources to be deleted. |
void |
setResources(IResource[] resources)
The resources to be deleted. |
Methods inherited from class org.eclipse.ltk.core.refactoring.RefactoringDescriptor |
compareTo, equals, getComment, getDescription, getFlags, getID, getProject, getTimeStamp, hashCode, setComment, setDescription, setFlags, setProject, setTimeStamp, toString |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final String ID
org.eclipse.ltk.core.refactoring.delete.resources
).
Clients may safely cast the obtained refactoring descriptor to
DeleteResourcesDescriptor
.
Constructor Detail |
public DeleteResourcesDescriptor()
Clients should not instantiated this class but use RefactoringCore.getRefactoringContribution(String)
with ID
to get the contribution that can create the descriptor.
Method Detail |
public IPath[] getResourcePaths()
public void setResourcePaths(IPath[] resourcePath)
IProject
or
a mixture of IFile
and IFolder
.
resourcePath
- paths of the resources to be deletedpublic void setResources(IResource[] resources)
IProject
or a mixture of IFile
and IFolder
.
resources
- IResources to be deletedpublic boolean isDeleteContents()
true
is returned if projects contents are also deleted.
true
if this will delete the project contents. The content delete is not undoable.public void setDeleteContents(boolean deleteContents)
true
, delete will also delete project contents.
deleteContents
- true
if this will delete the project contents. The content delete is not undoable.public Refactoring createRefactoring(RefactoringStatus status) throws CoreException
RefactoringDescriptor
This method is used by the refactoring framework to instantiate a refactoring from a refactoring descriptor, in order to apply it later on a local or remote workspace.
The returned refactoring must be in an initialized state, i.e. ready to
be executed via PerformRefactoringOperation
.
createRefactoring
in class RefactoringDescriptor
status
- a refactoring status used to describe the outcome of the
initialization
null
if this refactoring
descriptor represents the unknown refactoring, or if no
refactoring contribution is available for this refactoring
descriptor which is capable to create a refactoring
CoreException
- if an error occurs while creating the refactoring instance
|
Eclipse Platform Release 3.4 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.