Interface RefactoringDelta
-
- All Known Implementing Classes:
DefaultRefactoringDelta
public interface RefactoringDeltaA refactoring delta contains an ordered collection ofTextEdit. The order is based on the offset of thoseTextEditobjects: from the biggest offset to the smallest offset. This will allow the invoker to perform the refactoring by replacing the old values by the new values by following that order.Provisional API: This interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.
- Version:
- 2.5
- See Also:
BasicRefactoringTool- Author:
- Pascal Filion
- Since:
- 2.4
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringapplyChanges()Applies the changes to the JPQL query and returns the refactoring operations.booleanhasTextEdits()Determines whether at least oneTextEditwas added.intsize()Returns the number ofTextEditobjects that have been added.java.lang.Iterable<TextEdit>textEdits()Returns the collection ofTextEditobjects that have been added during one or several refactoring operations.
-
-
-
Method Detail
-
applyChanges
java.lang.String applyChanges()
Applies the changes to the JPQL query and returns the refactoring operations. The list ofTextEditwill be cleared.
-
hasTextEdits
boolean hasTextEdits()
Determines whether at least oneTextEditwas added.- Returns:
trueif there is at least oneTextEdit;falseotherwise
-
size
int size()
Returns the number ofTextEditobjects that have been added.- Returns:
- The count of
TextEditobjects
-
textEdits
java.lang.Iterable<TextEdit> textEdits()
Returns the collection ofTextEditobjects that have been added during one or several refactoring operations. The collection has been ordered where theTextEdit's offset are in reverse order, i.e. from the biggest to the smallest values.- Returns:
- The ordered collection of
TextEditobjects
-
-