public class DefaultRefactoringTool extends RefactoringTool
Provided functionality:
Class
name (e.g.: in constructor expression);Enum
constant.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.
EclipseLinkRefactoringTool
RefactoringTool.ClassNameRenamer, RefactoringTool.EntityNameRenamer, RefactoringTool.EnumConstantRenamer, RefactoringTool.FieldNameRenamer, RefactoringTool.ResultVariableNameRenamer, RefactoringTool.StateObjectUpdater<T extends StateObject>, RefactoringTool.VariableNameRenamer
Constructor and Description |
---|
DefaultRefactoringTool(IManagedTypeProvider managedTypeProvider,
IJPQLQueryBuilder jpqlQueryBuilder,
java.lang.CharSequence jpqlQuery)
Creates a new
RefactoringTool . |
DefaultRefactoringTool(IManagedTypeProvider managedTypeProvider,
IJPQLQueryBuilder jpqlQueryBuilder,
java.lang.CharSequence jpqlFragment,
java.lang.String jpqlQueryBNFId)
Creates a new
RefactoringTool . |
Modifier and Type | Method and Description |
---|---|
protected IJPQLQueryFormatter |
buildFormatter()
Creates a new formatter that will convert the
StateObject representation of the JPQL
query, once the refactoring occurred into a string. |
protected JPQLQueryContext |
buildJPQLQueryContext()
Creates a new
JPQLQueryContext that can retrieve information from the declaration
portion of the JPQL query. |
buildClassNameRenamer, buildEntityNameRenamer, buildEnumConstantRenamer, buildFieldNameRenamer, buildResultVariableNameRenamer, buildStateObject, buildVariableNameRenamer, getFormatter, getGrammar, getJPQLQueryBuilder, getStateObject, renameClassName, renameEntityName, renameEnumConstant, renameField, renameField, renameField, renameResultVariable, renameVariable, setFormatter, toActualText
getJPQLFragment, getJPQLQueryBNFId, getManagedTypeProvider, isTolerant, setTolerant
public DefaultRefactoringTool(IManagedTypeProvider managedTypeProvider, IJPQLQueryBuilder jpqlQueryBuilder, java.lang.CharSequence jpqlQuery)
RefactoringTool
.managedTypeProvider
- The external form of a provider that gives access to the JPA metadatajpqlQueryBuilder
- The builder that creates the model.query.StateObject StateObject
representation of the JPQL queryjpqlQuery
- The JPQL query to manipulatepublic DefaultRefactoringTool(IManagedTypeProvider managedTypeProvider, IJPQLQueryBuilder jpqlQueryBuilder, java.lang.CharSequence jpqlFragment, java.lang.String jpqlQueryBNFId)
RefactoringTool
.managedTypeProvider
- The external form of a provider that gives access to the JPA metadatajpqlQueryBuilder
- The builder that creates the model.query.StateObject
representation of the JPQL queryjpqlFragment
- The JPQL query to manipulate or a single JPQL fragment, which is parsed
using the JPQL query BNF identifier by the given IDjpqlQueryBNFId
- The unique identifier of the parser.JPQLQueryBNF JPQLQueryBNF
that determines how to parse the JPQL fragmentprotected IJPQLQueryFormatter buildFormatter()
StateObject
representation of the JPQL
query, once the refactoring occurred into a string.buildFormatter
in class RefactoringTool
IJPQLQueryFormatter
protected JPQLQueryContext buildJPQLQueryContext()
JPQLQueryContext
that can retrieve information from the declaration
portion of the JPQL query.
NOTE: This is temporary because the StateObject
API does not have that
knowledge yet.
buildJPQLQueryContext
in class RefactoringTool
JPQLQueryContext