java - IntelliJ plugin invoke rename refactoring -


i'm writing plugin intellij couple of things. 1 of things performs rename of references if don't meet specific style guideline (think of style police officer checks code styles before saving). i'd following (from within existing anaction):

  1. find usages of given identifier.
  2. for each usage, rename identifier different identifier.

clearly, exact workflow rename refactoring uses. so, question is: how invoke rename refactoring, given psielement (or string representation of identifier), within existing anaction (i.e. want multiple things in succession, 1 of them, don't want user have go through refactoring menu each thing want perform).

try this:

refactoringfactory.getinstance(project).createrename() 

Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -