Top Description Methods
org.eclipse.persistence.jpa.jpql.tools

public Interface RefactoringDelta

Known Direct Implementers
org.eclipse.persistence.jpa.jpql.tools.DefaultRefactoringDelta

A refactoring delta contains an ordered collection of TextEdit. The order is based on the offset of those TextEdit objects: 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.

Author
Pascal Filion
Since
2.4
Version
2.5
See Also
BasicRefactoringTool

Method Summary

Modifier and TypeMethod and Description
public String
applyChanges()

Applies the changes to the JPQL query and returns the refactoring operations.

public boolean

Returns:

true if there is at least one TextEdit; false otherwise
hasTextEdits
()

Determines whether at least one TextEdit was added.

public int

Returns:

The count of TextEdit objects
size
()

Returns the number of TextEdit objects that have been added.

public Iterable<TextEdit>

Returns:

The ordered collection of TextEdit objects
textEdits
()

Returns the collection of TextEdit objects that have been added during one or several refactoring operations.

Method Detail

applyChangesback to summary
public String applyChanges()

Applies the changes to the JPQL query and returns the refactoring operations. The list of TextEdit will be cleared.

hasTextEditsback to summary
public boolean hasTextEdits()

Determines whether at least one TextEdit was added.

Returns:boolean

true if there is at least one TextEdit; false otherwise

sizeback to summary
public int size()

Returns the number of TextEdit objects that have been added.

Returns:int

The count of TextEdit objects

textEditsback to summary
public Iterable<TextEdit> textEdits()

Returns the collection of TextEdit objects that have been added during one or several refactoring operations. The collection has been ordered where the TextEdit's offset are in reverse order, i.e. from the biggest to the smallest values.

Returns:Iterable<TextEdit>

The ordered collection of TextEdit objects