Apply inspection fix based on class usages

I'm trying to implement custom inspection and according fix that will

* Change the class by implementing different interface
* Find usages of this class and change them too.

Is it possible to implement second point? I didn't find any examples in CE repository.

0

Hi Vit,

your fix looks like a refactoring, so you can first implement BaseRefactoringProcessor and then call it in your fix. BaseRefactoringProcessor would care about progress to show when you search for references, would clear read-only status for usages and would show conflicts e.g. when your new method has another set of arguments or something like that

Anna

1

Thank you, Anna.
Seems like what I need indeed.

0

请先登录再写评论。